GCPCAND

Candidate generation for automatic GCP collection


EnvironmentsPYTHON :: EASI
Quick linksDescription :: Parameters :: Parameter descriptions :: Details :: Example :: Related

Back to top

Description


GCPCAND processes reference images to generate candidates for automatic collection of ground control points (GCP).
Back to top

Parameters


Name Type Caption Length Value range
MFILE * String Input file name, folder, or text file 1 - 192  
DBIC Integer Reference image channel(s) 0 -    
SRCBGD String Source background value 0 - 192 Default: FILE
LOCLMASK String Local exclusion mask 0 - 192 Default: NONE
SMPLSRC String Candidate samples source 0 - 192 SUSAN | GRID
Default: GRID
DISTRIB String Distribution unit 0 - 192 MAPSPACING | PIXELSPACING | ENTIRE
Default: MAPSPACING
DISTNUM String Distribution number 0 - 192  
TRIALS Integer Number of trials per candidate 0 - 1 1 - 8
Default: 1
PROC String Processing algorithm 0 - 192
FILO String Output file or folder 0 - 192  
REPORT String Report mode 0 - 192 Quick links

* Required parameter
Back to top

Parameter descriptions

MFILE

The name of a folder, image file, or text file that contains the reference images from which to produce candidates. If necessary, you can use a wildcard (*) in the string.

You can specify the value of the MFILE parameter by using any of the following:
If the text file option is used, the following general rules apply:

If the MFILE you specify does not have a list of channels to process, the value of the DBIC (Input Channels) parameter is used.

When specifying file channels, you can specify individual channels or channel sequences. An individual channel index is a single positive integer (for example, "1"). A channel sequence is a positive integer followed by a comma and a negative number (for example, "1,-3"). In this example, "1,-3" means to process channels 1 through 3 inclusive; it is expanded internally to "1,2,3". The second channel number in the sequence must be greater than the first channel number.

If the MFILE you specify does not have the source background specification, the value of the SRCBGD parameter is used.

DBIC

The channel or channels in the reference-image file from which to extract the SUSAN corner features when using the SUSAN detector. When there are multiple channels, they are averaged together.

If the value of the DBIC parameter is in a text file (MFILE), this parameter is ignored.

If no value is specified for this parameter, the first channel is processed by default.

This parameter is ignored when the value of the SMPLSRC (Candidate samples source method) parameter is any option other than SUSAN.

Ranges of channels or segments can be specified with negative values. For example, {1,-4,10} is internally expanded to {1,2,3,4,10}. When you are not specifying a range in this way, only 48 numbers can be specified explicitly.

SRCBGD

The pixels in the source image to consider as background (NoData) pixels. In general, if a pixel is considered NoData, GCPCAND processes the pixel in a specific manner.

You can choose from the following options:
Note: To specify multiple values, use a comma-delimited list. The first value applies to the first channel, the second value to the second channel, and so on. If fewer values are specified than the number of input channels, the last value is repeated for all remaining channels. If more values are specified than the number of input channels, the extra values are ignored. This parameter is ignored when the value of the SMPLSRC (Candidate samples source method) parameter is any option other than SUSAN.

LOCLMASK

Specify whether to apply a local mask to prevent points from being collected in those locations. If no value is specified for this parameter (default), or you specify a value, but one or more of the images do not contain a bitmap or vector segment, no local exclusion mask will be applied for those images.

The syntax for LOCLMASK is:
LOCLMASK = (NONE | BIT | VEC | <n>)
You can specify the value of LOCLMASK using the following:

This parameter is optional.

SMPLSRC

The source of sample points for the candidates

If no value is specified for this parameter, GRID is used by default.

The SUSAN and GRID options determine how to find the candidate positions in the reference image. AutoGCP will attempt to collect GCPs at these locations.

When collecting GCPs, the GRID option is preferred, because the SUSAN option finds candidates on building corners that may not be represented in the digital elevation model (DEM), leading to GCPs with higher residuals due to height errors.

DISTRIB

The unit of value to use for the DISTNUM parameter.

You can choose from the following options:

DISTNUM

This controls the number of GCPs to find, in the units specified for the DISTRIB (Distribution) parameter. The default value generally produces approximately 100 points evenly distributed over the reference image. When the value of the DISTRIB (Distribution) parameter is MAPSPACING, and the reference image has a projection in degrees, you can specify a string in the format degrees-minutes-seconds. The specific format is as follows:

TRIALS

The number of trials per candidate. Trials are backup candidates to try when the main candidate failed to match a given raw image. When there is an insufficient number of stereo GCPs, it is recommended that you use a denser distribution rather than more trials, as the backup trials are only collected if the main candidate failed to match for a particular image.

PROC

The amount of memory (in megabytes) used by GCPCAND.

If the host memory limit is not specified, the function uses a default of 1 gigabyte (GB) or half the available physical memory, whichever is less.

FILO

The name of the output file or folder to which to write the processed files, depending on the value of the MFILE parameter:

The vector segment GCPCAND creates will be named GCPCand and have a description of GCP candidate points.

REPORT

Specifies where to direct the generated report.

Available options are:

Back to top

Details

GCPCAND generates candidates for automatic GCP collection by preprocessing reference images and writing a vector segment containing the generated candidates to a file. These candidates can be used by AUTOGCP to collect GCPs. The vector segment created by GCPCAND will be named GCPCand and have a description of GCP candidate points.

Back to top

Example

The following example finds GCPs for an input image called "spotRaw.pix".


EASI>mfile = "SPOT_MOSAIC.PIX" 
EASI>dbic =
EASI>srcbgd = "" 
EASI>loclmask = "" 
EASI>smplsrc = "GRID" 
EASI>distrib = "PIXELSPACING" 
EASI>distnum = "1000"
EASI>trials = 1
EASI>proc = "" 
EASI>filo = "cSPOT_MOSAIC.PIX" 

EASI>r gcpcand                

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