This Docker image uses the Java-based VicarIO library for VICAR image format conversion. The Java version provides better image quality with proper dynamic range rescaling compared to the Python implementation.
Once the public VicarIO repository becomes available:
-
Clone the VicarIO repository:
git clone https://github.com/NASA-AMMOS/vicario.git cd vicario -
Build the FAT JAR (includes all dependencies):
mvn -U -Pshade clean install
-
Copy the JAR to the Docker build context:
cp target/vicario-*-FAT.jar /path/to/tig/terrain-intelligence-generator/docker/vicario.jar
Note: The repository is currently being prepared for public release. Check NASA-AMMOS/vicario for availability.
Once vicario.jar is in place:
cd terrain-intelligence-generator/docker
docker build -t terrain-intelligence-generator:latest .The Java implementation provides:
- Correct dynamic range handling: Automatically rescales 16-bit VICAR images to 8-bit with
oform=byte rescale=true - Better image quality: Preserves full dynamic range during conversion
- Native VICAR support: Direct parsing of VICAR labels and binary data
- Format flexibility: Supports PNG, JPEG, TIFF output formats
The wrapper script automatically applies the correct rescaling parameters for standard 2-argument usage:
vicario input.vic output.pngFor advanced usage, pass parameters directly:
vicario inp=input.vic out=output.png format=png oform=byte rescale=true