BuildTimeSeries Task
This task sorts a series of ENVIRasters by acquisition time and builds an ENVI raster series file. Each input raster must have an acquisition time
field defined in its header.
Example
; Start the application
e = ENVI()
TimeSeriesDir = Filepath('', Subdir=['data','time_series'], $
Root_Dir = e.Root_Dir)
files = File_Search(TimeSeriesDir, 'AirTemp*.dat')
numRasters = N_Elements(files)
rasters = ObjArr(numRasters)
FOR i=0, (numRasters-1) DO $
rasters[i] = e.OpenRaster(files[i])
; Get the task from the catalog of ENVITasks
Task = ENVITask('BuildTimeSeries')
; Define inputs
Task.INPUT_RASTERS = rasters
; Run the task
Task.Execute
; Print the contents of the series file
SeriesFile = Task.OUTPUT_RASTERSERIES
SeriesFile
IDL prints:
Description: Raster Series 2014-04-10T16-45-53Z
Data Type: 5
Version: 5.1.1
Total Number of files: 12
Regular Grid: true
0: 2012-12-29T00:00:00Z: ...\AirTemp_2012122900.dat
1: 2012-12-29T06:00:00Z: ...\AirTemp_2012122906.dat
2: 2012-12-29T12:00:00Z: ...\AirTemp_2012122912.dat
3: 2012-12-29T18:00:00Z: ...\AirTemp_2012122918.dat
4: 2012-12-30T00:00:00Z: ...\AirTemp_2012123000.dat
5: 2012-12-30T06:00:00Z: ...\AirTemp_2012123006.dat
6: 2012-12-30T12:00:00Z: ...\AirTemp_2012123012.dat
7: 2012-12-30T18:00:00Z: ...\AirTemp_2012123018.dat
8: 2012-12-31T00:00:00Z: ...\AirTemp_2012123100.dat
9: 2012-12-31T06:00:00Z: ...\AirTemp_2012123106.dat
10: 2012-12-31T12:00:00Z: ...\AirTemp_2012123112.dat
11: 2012-12-31T18:00:00Z: ...\AirTemp_2012123118.dat
Syntax
Result = ENVITask('BuildTimeSeries')
Input properties (Set, Get): INPUT_RASTERS, OUTPUT_RASTERSERIES_URI
Output properties (Get only): OUTPUT_RASTERSERIES
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:
Properties
This task inherits the following properties from ENVITask:
This task also contains the following properties:
INPUT_RASTERS (required)
Specify an array of rasters from which to build the time series.
OUTPUT_RASTERSERIES
This is a reference to the output time-series file (.series
) in JSON format.
OUTPUT_RASTERSERIES_URI (optional)
Specify a string with the fully qualified filename and path of the output time-series file.
Version History
ENVI 5.2 |
Introduced |
ENVI 5.5 | Replaced INPUT_RASTER_URI with INPUT_RASTERS |
API Version
4.2