Skip to content

read_shape_modelReadShapeModelReadShapeModelread_shape_modelT_read_shape_model🔗

Short description🔗

read_shape_modelReadShapeModelReadShapeModelread_shape_modelT_read_shape_model — Read a shape model from a file.

Signature🔗

read_shape_model( filename.read FileName, out shape_model ModelID )void ReadShapeModel( const HTuple& FileName, HTuple* ModelID )static void HOperatorSet.ReadShapeModel( HTuple fileName, out HTuple modelID )def read_shape_model( file_name: str ) -> HHandle

Herror T_read_shape_model( const Htuple FileName, Htuple* ModelID )

void HShapeModel::HShapeModel( const HString& FileName )

void HShapeModel::HShapeModel( const char* FileName )

void HShapeModel::HShapeModel( const wchar_t* FileName ) (Windows only)

public HShapeModel( string fileName )

void HShapeModel::ReadShapeModel( const HString& FileName )

void HShapeModel::ReadShapeModel( const char* FileName )

void HShapeModel::ReadShapeModel( const wchar_t* FileName ) (Windows only)

void HShapeModel.ReadShapeModel( string fileName )

Description🔗

The operator read_shape_modelReadShapeModel reads a shape model, which has been written with write_shape_modelWriteShapeModel, from the file FileNamefileNamefile_name. The default HALCON file extension for the shape model is 'shm'.

Execution information🔗

Execution information
  • Multithreading type: reentrant (runs in parallel with non-exclusive operators).

  • Multithreading scope: global (may be called from any thread).

  • Processed without parallelization.

This operator returns a handle. Note that the state of an instance of this handle type may be changed by specific operators even though the handle is used as an input parameter by those operators.

Parameters🔗

FileNamefileNamefile_name (input_control) filename.read → (string)HTuple (HString)HTuple (string)strHtuple (char*)

File name.

File extension: .shm

ModelIDmodelIDmodel_id (output_control) shape_model → (handle)HTuple (HHandle)HShapeModel, HTuple (IntPtr)HHandleHtuple (handle)

Handle of the model.

Result🔗

If the file name is valid, the operator read_shape_modelReadShapeModel returns the value 2 (H_MSG_TRUE). If necessary an exception is raised.

Combinations with other operators🔗

Combinations

Possible successors

find_generic_shape_modelFindGenericShapeModel

Module🔗

Matching