The second option for generating the training sample file can be done non-interactively. This is done by specifying a GRASS sites file. This file should represent the locations of training samples and ought to have been previously generated either by digitising (v.digit) or else by v.in.ascii. Features will be extracted for these locations in a similar fashion as previously described. The class will be assigned to the examples based on the information stored in the sites file.
The output of this module will be an ascii file of type xy.z. The number of columns will relate to the number of rasters specified on the command line. If the output file already exists, the new data values will be appended to it.
Flags:
- --v Verbose module output. Print information pertaining to module progress and completion.
- --p Run Quietly. Suppress program output that would include program percent complete messages and time elapsed.
Parameters:
- input=name,name[,name,name,...]
- Name of raster maps (maximum 25) for extracting the training examples. The first will be used for graphical output. The extent of all raster maps should be the same. CELL, DCELL and FCELL raster maps can be used.
- vis_mapname
- This parameter is optional. If used, the raster that is specified will be displayed in the GRASS monitor and used as a background raster file. It should be used to identify the location of training samples.
- training=name
- This parameter is required. It creates the training file, which is an ascii file containing all of the x,y locations of the traning samples and their associated class labels and values from the explanatory variables (GRASS raster maps). If the name specified on the command line refers to a training file that already exists in the working directory, the new data are appended to it.
- site_file=name
- This parameter is required if the non-interactive mode is required. It should relate to a GRASS Vector map (Version 6 vector data) and there should be a class label (numeric value) for each site. This file should be created prior to running i.pr.training either using v.digit or v.in.ascii. The latter is more straightforward provided the input ascii file contains data in the following format: x,y,z(class label).
- rows=value
- The number of rows in the training samples, this must be odd.
- cols=value
- The number of colums in the training samples, this must be odd.
- class=value
- The numerical label to be attached to the training examples. This is only required when the interactive mode of i.pr.training is used.
NOTES
SEE ALSO
i.cca
AUTHORS
Stefano Merler, FBK, Trento, Italy
Documentation: Daniel McInerney (daniel.mcinerney ucd.ie)
Last changed: $Date$
Main index - imagery index - Full index
© 2003-2016 GRASS Development Team