This task exports multiple rasters to a specified directory on disk. It can be used, for example, as part of a sequence for dicing rasters:
Consider using one of the following to perform these steps in one task:
Example
e = ENVI()
File = Filepath('qb_boulder_msi', Subdir=['data'], $
Root_Dir=e.Root_Dir)
Raster = e.OpenRaster(File)
SubrectTask = ENVITask('CreateSubrectsFromTileCount')
SubrectTask.NUMBER_OF_X_TILES = 3
SubrectTask.NUMBER_OF_Y_TILES = 4
SubrectTask.NCOLUMNS = Raster.NCOLUMNS
SubrectTask.NROWS = Raster.NROWS
SubrectTask.Execute
Subrects = SubrectTask.SUBRECTS
SubNames = SubrectTask.SUBRECT_NAMES
DiceTask = ENVITask('DiceRasterBySubrects')
DiceTask.INPUT_RASTER = Raster
DiceTask.SUBRECT_ARRAY = Subrects
DiceTask.SUBRECT_NAMES = SubNames
DiceTask.Execute
Task = ENVITask('ExportRastersToDirectory')
Task.INPUT_RASTERS = DiceTask.OUTPUT_RASTER
Task.OUTPUT_DIRECTORY = Filepath('', /TMP)
Task.Execute
Syntax
Result = ENVITask('ExportRastersToDirectory')
Input properties (Set, Get): DATA_IGNORE_VALUE, INPUT_RASTERS, INTERLEAVE, OUTPUT_DIRECTORY
Output properties (Get only): OUTPUT_RASTERS
Properties marked as "Set" are those that you can set to specific values. You can also retrieve their current values any time. Properties marked as "Get" are those whose values you can retrieve but not set.
Methods
This task inherits the following methods from ENVITask:
AddParameter
Execute
Parameter
ParameterNames
RemoveParameter
Properties
This task inherits the following properties from ENVITask:
COMMUTE_ON_DOWNSAMPLE
COMMUTE_ON_SUBSET
DESCRIPTION
DISPLAY_NAME
NAME
REVISION
TAGS
This task also contains the following properties:
DATA_IGNORE_VALUE (optional)
Specify a unique data value for pixels in the output raster that have a non-zero pixel state value. See Raster Pixel State for more information.
INPUT_RASTERS (required)
Specify the rasters to export.
INTERLEAVE (optional)
Specify a string indicating the data interleave of the output raster. If this parameter is not set, the interleave of the input raster will be used. The choices are:
BSQ
BIL
BIP
OUTPUT_DIRECTORY
Specify the output directory. If you do not set this property, the directory will set to the ENVI output directory.
OUTPUT_RASTERS
This is a reference to the output rasters of filetype ENVI.
API Version
4.3
See Also
ENVITask, ENVISubsetRaster, CreateSubrectsFromDistance Task, CreateSubrectsFromPixels Task, CreateSubrectsFromTileCount Task, CreateSubrectsFromVector Task, DiceRasterByDistance Task, DiceRasterByPixel Task, DiceRasterBySubrects Task, DiceRasterByTileCount Task, DiceRasterByVector Task