SATMODEL

Generate Satellite Model


EnvironmentsPYTHON :: EASI :: MODELER
Quick linksDescription :: Parameters :: Parameter descriptions :: Return Value :: Details :: Example :: Related

Back to top

Description


SATMODEL computes the math model of one or more satellite images using Toutin's model and stores the result in a segment in the image file.
Back to top

Parameters


satmodel(mfile, dbgc, orbit, mmseg, mapunits)

Name Type Caption Length Value range
MFILE * str Input file name, directory, or text file 1 -    
DBGC List[int] Input GCP segment 0 - 1  
ORBIT List[int] Input orbit segment 0 - 1  
MMSEG List[int] Math model segment or layer 0 - 1  
MAPUNITS str Map units 0 - 16 PIXEL, UTM, LONG/LAT, and others

* Required parameter
Back to top

Parameter descriptions

MFILE

Specifies the name of a folder, image file, or text file that contains the input raw images to be processed. Wildcards (*) can be used.

MFILE can be set using any of the following options:

If a directory name is specified or if multiple file names are entered, all images in MFILE should be processed using the parameters set for SATMODEL.

If a directory is specified, then the DBGC, MMSEG, and ORBIT parameters are set to a single value for all input images. If a text file is specified, the files listed in the text file are processed with the listed parameters. In this case, the DBGC, MMSEG, and ORBIT parameters are read from the text file for each image, and those parameters can be left blank.

If one file is specified for MFILE, then the model computed will be an independent model (one image).

If the text file option is used, the following general rules apply:

DBGC

Specifies the ground control point (GCP) segment or layer in the input raw image to use to compute the model.

If a directory is specified for MFILE, this segment number will be applied to all images. If a text file is specified, DBGC is read from the text file, and this parameter can be left blank. If no value is specified, the default four-corner coordinates in the orbit segment will be used as GCPs to compute an approximate model for non-RADARSAT-2 images. For RADARSAT-2 images, the orbit and RFModel segments associated with the data will be used to compute Toutin's hybrid model.

ORBIT

Specifies the orbit segment or layer in the input image to use to compute the model.

If a directory is specified for MFILE, this segment number will be applied to all images. If a text file is specified, ORBIT is read from the text file, and this parameter can be left blank. If no value is specified, the last orbit segment will be used automatically.

MMSEG

Specifies the math model segment or layer to store the model.

If a directory is specified for MFILE, this segment number will be applied to all images. If a text file is specified, MMSEG is read from the text file, and this parameter can be left blank. If no value is specified, a new segment is created.

MAPUNITS

Specifies the projection string for the output model.

The standard definitions are as follows:

For a complete list of supported projections and Earth models, see Understanding map projections. The format of the map units string is described in Output units.

If this parameter is not specified, the map units of the specified GCP segment are used. If no GCP segment is specified, the UTM unit stored in the orbit segment is used.

Back to top

Return Value

Returns: A list of statistical values.

Type:  PCI_DOUBLE

Parameter: IMSTAT

A list containing the doubles: [GCP RMS, GCP maximum RMS, GCP minimum RMS, abs(GCP maximum residual), abs(GCP minimum residual), math model segment number]. The last value in the returned list is the segment number to which the computed math model was written. The remaining values are in pixels. If more than one file is processed, the list is extended with the same set of statistical values for each file. This function returns only if it executes successfully; otherwise, it throws an exception instead of returning.

Back to top

Details

SATMODEL computes the math model of one or more satellite images using Toutin's model. This includes bundle adjustment of multiple scenes, using ground control points (GCPs) or tie points, or both.

The input is either:

The output is a refined math model for each image, saved either to a math model segment in the image file or to the OrthoEngine project file, depending on the input.

If MFILE is a text file, the files and parameters listed in the text file are used. For SATMODEL, the parameters in the text file must be delimited by semi-colons and must appear in the following order, where DBGC, ORBIT, and MMSEG are optional:
[FILE][DBGC][ORBIT][MMSEG]

If the DBGC (InputGCP) parameter is not specified, SATMODEL uses the four corner points and scene center point stored in the ORBIT (InputORB) segment as GCPs; however, these points are not available for every format.

If DBGC (InputGCP) is not specified and these points are not available, SATMODEL exits with an error. The corners points are only an estimate and are not accurate. Use them only when accurate GCPs cannot be obtained.

Back to top

Example

Generate a satellite model for a SPOT image.

from pci.satmodel import satmodel

mfile = "17029_pan.pix"
dbgc = [3]
orbit = [2]
mmseg = []
mapunits = ""

satmodel(mfile, dbgc, orbit, mmseg, mapunits)
        

© PCI Geomatics Enterprises, Inc.®, 2026. All rights reserved.