I am trying to convert ASTER level 2 HDF files (AST_08 Surface Kinetic Temperature) to GeoTiff using the HEG swtif tool and a parameter file from the command line in Ubuntu. When I run the program I get the following error:
(swtif)
Start Time: Sat May 13 01:15:56 2017
Listing Command Line Options:
./swtif -p param_fileError: Failed to get environment variable PWD. Not setting it may cause >some problems later.
Error: Check_envs_for_space : Environmental Variable Not Found
: One of the environment vaiables PWD, MRTDATADIR, PGSHOME, or >MRTBINDIR has not been set or has an illegal space in it. This causes >problem later.
Fatal Error, Terminating...
Fatal Error, Terminating...
The contents of the parameter file are:
NUM_RUNS = 1
BEGIN
INPUT_FILENAME = /home/me/Documents/data/AST_08_00301012002193924_20170512065710_28288.hdf
OBJECT_NAME = SurfaceKineticTemperature
FIELD_NAME = KineticTemperature|
BAND_NUMBER = 1
OUTPUT_PIXEL_SIZE_X = 90.0
OUTPUT_PIXEL_SIZE_Y = 90.0
SPATIAL_SUBSET_UL_CORNER = ( 14.635767 39.845845 )
SPATIAL_SUBSET_LR_CORNER = ( 13.970527 40.618836 )
RESAMPLING_TYPE = NN
OUTPUT_PROJECTION_TYPE = UTM
ELLIPSOID_CODE = WGS84
UTM_ZONE = 0
OUTPUT_PROJECTION_PARAMETERS = ( 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 )
OUTPUT_FILENAME = /home/me/Documents/data/processed/AST_08_00301012002193924_20170512065710_28288_SurfaceKineticTemperature.tif
OUTPUT_TYPE = GEO
END
Which I run at the command line with:
export MRTDATADIR=/opt/heg/data
export PGSHOME=/opt/heg/TOOLKIT_MTD
sudo ./swtif -p param_file
I've tried setting the environment variable PWD manually, but I get the same error.