I am trying to make a batch model to convert band 2 and band 1 MODIS 8 day composites into NDVI. The input files are in tif format, but I want the output to be saved in Idrisi .rst format.
I am using QGIS 2.2 64 bit on a Windows 8.1 machine. I installed via the OSgeo4W, and installed everything, so I am using the Orfeo-toolbox for the raster calculator. I am new to QGIS and not very experienced in python either.
The simple model is presented below. Ultimately, I want to batch this, but for the time being I’m just testing to see if I can get a simple model to work. I have tested the data, using the raster calculator directly in QGIS to make an NDVI and this worked without any problems. I just have a lot of images I need do this for....
![screen capture of mode in QGIS]
Below I have copied the OTB execution command and the execution console output from QGIS.
My questions are:
What does it mean that I am missing mandatory parameter “il 0”?
Is there a better way to make NDVI images than using the model I have made?
Any help or advice on this matter is greatly appreciated!
OTB execution command
C:/OSGEO4~1\bin\otbcli_BandMath -ram 128 -exp (NIR - RED) / (NIR + RED) -out "C:/8day_NDVI/NDVI_1.rst"
OTB execution console output
ERROR: Missing mandatory parameter: il 0
ERROR: Troubles loading parameter, please check your line argument...
This is the BandMath application, version 4.0.0
Perform a mathematical operation on monoband images
Complete documentation: http://www.orfeo-toolbox.org/Applications/BandMath.html
-progress Report progress
MISSING -il Input image list (mandatory)
-out [pixel] Output Image [pixel=uint8/uint16/int16/uint32/int32/float/double](default value is float) (mandatory)
-ram Available RAM (Mb) (optional, off by default, default value is 128)
-exp Expression (mandatory)
-inxml Load otb application from xml file (optional, off by default)