lautenberger / elmfire

Eulerian Level set Model of FIRE spread
https://elmfire.io
Eclipse Public License 2.0
23 stars 11 forks source link

Error running tutorial case 1 #3

Closed yqin123 closed 1 year ago

yqin123 commented 1 year ago

An error occurs when running tutorial case 1. Here is the log information.

ELMFIRE 2023.03 Reading &MISCELLANEOUS namelist group Reading &INPUTS namelist group Reading &OUTPUTS namelist group Reading &COMPUTATIONAL_DOMAIN namelist group Reading &TIME_CONTROL namelist group Reading &SIMULATOR namelist group Reading &CALIBRATION namelist group Reading &SUPPRESSION namelist group Reading &SPOTTING namelist group Reading &SMOKE namelist group Reading &MONTE_CARLO namelist group Reading headers for fuels/topography and weather rasters /cvmfs/hpcsw.umd.edu/spack-software/2022.06.15/linux-rhel8-zen2/gcc-9.4.0/gdal-3.4.0-2lfwxvv4yfehlamhc5zraivmeu4hbxdi/bin/gdal_translate -of ENVI -co "INTERLEAVE=BSQ" ./inputs/asp.tif ./scratch/asp.bsq Input file size is 400, 400 0...10...20...30...40...50...60...70...80...90...100 - done. Problem opening bsq xml header ./scratch/asp.bsq.aux.xml IOS: 2

Looks like there is some issue with opening the weather/topography inputs or preprocessing them. I changed the PATH_TO_GDAL in the file "elmfire.data.in". And here is how I configured the installation:

export ELMFIRE_FCOMPL_SERIAL_GNU=gfortran export ELMFIRE_FCOMPL_MPI_GNU=mpifort export ELMFIRE_INSTALL_DIRECTORY=/home/yqin123/software/bin/elmfire export ELMFIRE_SCRATCH_BASE=/home/yqin123/scratch/elmfire_scratch export ELMFIRE_BASE_DIR=/home/yqin123/software/elmfire_public/elmfire_public/ export ELMFIRE_INSTALL_DIR=/home/yqin123/software/bin/elmfire_public/ export CLOUDFIRE_SERVER=172.92.17.198 export PATH=$PATH:$ELMFIRE_INSTALL_DIR:$ELMFIRE_BASE_DIR/cloudfire

All other processes follow the instruction in the documentation.

lautenberger commented 1 year ago

Thanks Yiren, let's try this: Stop the 01-run.sh script before ELMFIRE is called, i.e. add the line exit 0 immediately before elmfire_$ELMFIRE_VER ./inputs/elmfire.data.

Then execute 01-run.sh, which will create the requisite inputs and exit before calling ELMFIRE. After that, make the same gdal_translate call from the command line that ELMFIRE is doing internally, i.e.:

/cvmfs/hpcsw.umd.edu/spack-software/2022.06.15/linux-rhel8-zen2/gcc-9.4.0/gdal-3.4.0-2lfwxvv4yfehlamhc5zraivmeu4hbxdi/bin/gdal_translate -of ENVI -co "INTERLEAVE=BSQ" ./inputs/asp.tif ./scratch/asp.bsq

What is the directory listing of ./scratch/? If the file asp.bsq.aux.xml exists there, can you past its contents here? Thanks.

yqin123 commented 1 year ago

Thank you, Chris! I run the commands but asp.bsq.aux.xml does not show up. The files inside the directory scratch includes:

login-2:scratch$ ls asp.bsq asp.hdr dummy.tif dummy.xyz float.tif int.tif

By running gdal_translate, I got:

login-2:01-constant-wind$ /cvmfs/hpcsw.umd.edu/spack-software/2022.06.15/linux-rhel8-zen2/gcc-9.4.0/gdal-3.4.0-2lfwxvv4yfehlamhc5zraivmeu4hbxdi/bin/gdal_translate -of ENVI -co "INTERLEAVE=BSQ" ./inputs/asp.tif ./scratch/asp.bsq Input file size is 400, 400 0...10...20...30...40...50...60...70...80...90...100 - done.

lautenberger commented 1 year ago

Interesting. What is the output of gdal_translate --version?

lautenberger commented 1 year ago

Actually, I think I know what the problem is. Try setting the environment variable GDAL_PAM_ENABLED to YES. If you're shell is bash, that would be export GDAL_PAM_ENABLED=YES. Then try the gdal_translate command above to see if the asp.bsq.aux.xml file gets generated. If it does then you should be in business.

yqin123 commented 1 year ago

It works! Thank you, Chris!