read_matrixT_read_matrixReadMatrixReadMatrixread_matrix (Operator)

Name

read_matrixT_read_matrixReadMatrixReadMatrixread_matrix — Einlesen eine Matrix von einer Datei.

Signatur

read_matrix( : : FileName : MatrixID)

Herror T_read_matrix(const Htuple FileName, Htuple* MatrixID)

void ReadMatrix(const HTuple& FileName, HTuple* MatrixID)

void HMatrix::HMatrix(const HString& FileName)

void HMatrix::HMatrix(const char* FileName)

void HMatrix::HMatrix(const wchar_t* FileName)   (Nur Windows)

void HMatrix::ReadMatrix(const HString& FileName)

void HMatrix::ReadMatrix(const char* FileName)

void HMatrix::ReadMatrix(const wchar_t* FileName)   (Nur Windows)

static void HOperatorSet.ReadMatrix(HTuple fileName, out HTuple matrixID)

public HMatrix(string fileName)

void HMatrix.ReadMatrix(string fileName)

def read_matrix(file_name: str) -> HHandle

Beschreibung

read_matrixread_matrixReadMatrixReadMatrixReadMatrixread_matrix liest eine Matrix, die mit write_matrixwrite_matrixWriteMatrixWriteMatrixWriteMatrixwrite_matrix geschrieben wurde, aus der Datei FileNameFileNameFileNameFileNamefileNamefile_name ein. Die Dateiendung für die Matrix ist in HALCON 'mtx'. Das Dateiformat kann binär oder ASCII sein. Jede Zeile der Datei enthält eine Zeile der Matrix mit einer Anzahl von Spalten. Die Spalten sind durch Leerzeichen oder Tabulatoren getrennt. Jede Zeile muss dieselbe Anzahl an Spalten beinhalten. Leere Zeilen werden ignoriert.

Die eingelesenen Ergebnisse werden in der generierten Matrix MatrixMatrixMatrixMatrixmatrixmatrix gespeichert. Es wird das Matrix Handle MatrixIDMatrixIDMatrixIDMatrixIDmatrixIDmatrix_id dieser Matrix zurückgegeben. Zugriff auf die Elemente der Matrizen ist z.B. mit dem Operator get_full_matrixget_full_matrixGetFullMatrixGetFullMatrixGetFullMatrixget_full_matrix möglich.

Ausführungsinformationen

Dieser Operator liefert ein Handle zurück. Es ist zu beachten, dass der Zustand einer Instanz dieses Handletyps durch bestimmte Operatoren geändert werden kann, obwohl das Handle als Eingabeparameter in diesen Operatoren verwendet wird.

Parameter

FileNameFileNameFileNameFileNamefileNamefile_name (input_control)  filename.read HTuplestrHTupleHtuple (string) (string) (HString) (char*)

Name der Datei.

Dateiendung: .mtx

MatrixIDMatrixIDMatrixIDMatrixIDmatrixIDmatrix_id (output_control)  matrix HMatrix, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Matrix Handle.

Ergebnis

Ist der Dateiname korrekt, dann liefert read_matrixread_matrixReadMatrixReadMatrixReadMatrixread_matrix den Wert TRUE. Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Nachfolger

get_full_matrixget_full_matrixGetFullMatrixGetFullMatrixGetFullMatrixget_full_matrix

Modul

Foundation