Trains this 3DPatMax pattern. If the pattern is already trained then
it is untrained and retrained.
Namespace: Cognex.VisionPro3DAssembly: Cognex.VisionPro3D (in Cognex.VisionPro3D.dll) Version: 83.0.0.0
Syntax
Events
| Event Type | Reason |
|---|---|
| ICogChangedEvent Changed |
Fires when this method changes the
Trained
state of the pattern.
The following state flags may be affected:
|
| ICogChangedEvent Changed |
Fires when this method trains the pattern successfully and also
computes a new subsampling cube size. This can only happen when
GranularityAutoSelect
is "true".
The following state flags may be affected:
|
Exceptions
| Exception | Condition |
|---|---|
| CogSecurityViolationException | Licensing for this operation cannot be confirmed. See Understanding VisionPro Security for more information. |
| CogOperatorNoTrainImageException | The TrainVisionData is null. |
| ArgumentOutOfRangeException |
The TrainVisionData
you supplied is not a valid source of 3D vision data.
3D vision data can be stored in a single CogImage16Range or stored in a CogVisionDataContainer as a matched pair, with one CogImage16Range holding the 3D data and one CogImage16Grey holding corresponding grey-level information or stored in a Cog3DPointCloudMesh. Either style of input is acceptable. All objects are referred to by the term "vision data" and all support the ICogVisionData interface. |
| InvalidOperationException | The TrainRegion contains too few 3D points to allow training. This might occur because the region falls completely outside of the TrainVisionData, Or has an invalid SelectedSpaceName3D. |
| CogTimeoutExpiredException | The pattern training took longer than the enabled TrainTimeout value. |
Remarks
See Also