add_texture_inspection_model_imageT_add_texture_inspection_model_imageAddTextureInspectionModelImageAddTextureInspectionModelImage (Operator)

Name

add_texture_inspection_model_imageT_add_texture_inspection_model_imageAddTextureInspectionModelImageAddTextureInspectionModelImage — Hinzufügen von Trainingsbildern zu einem Texturinspektionsmodell.

Signatur

add_texture_inspection_model_image(Image : : TextureInspectionModel : Indices)

Herror T_add_texture_inspection_model_image(const Hobject Image, const Htuple TextureInspectionModel, Htuple* Indices)

void AddTextureInspectionModelImage(const HObject& Image, const HTuple& TextureInspectionModel, HTuple* Indices)

HTuple HImage::AddTextureInspectionModelImage(const HTextureInspectionModel& TextureInspectionModel) const

HTuple HTextureInspectionModel::AddTextureInspectionModelImage(const HImage& Image) const

static HTuple HTextureInspectionResult::AddTextureInspectionModelImage(const HImage& Image, const HTextureInspectionModel& TextureInspectionModel)

static void HOperatorSet.AddTextureInspectionModelImage(HObject image, HTuple textureInspectionModel, out HTuple indices)

HTuple HImage.AddTextureInspectionModelImage(HTextureInspectionModel textureInspectionModel)

HTuple HTextureInspectionModel.AddTextureInspectionModelImage(HImage image)

static HTuple HTextureInspectionResult.AddTextureInspectionModelImage(HImage image, HTextureInspectionModel textureInspectionModel)

Beschreibung

add_texture_inspection_model_imageadd_texture_inspection_model_imageAddTextureInspectionModelImageAddTextureInspectionModelImageAddTextureInspectionModelImage fügt Trainingsbilder zum Texturinspektionsmodell TextureInspectionModelTextureInspectionModelTextureInspectionModelTextureInspectionModeltextureInspectionModel hinzu. Für die weitere Verarbeitung wird für jedes Bild die Information innerhalb der Domäne des Bildes berücksichtigt. Da Merkmale, welche im Trainingsprozess für jedes Pixel extrahiert werden, in Relation zu ihrer Nachbarschaft berechnet werden, können für Pixel am Rand der Domäne keine Merkmale extrahiert werden. Die Größe des Randes hängt von der Größe der Merkmale ('patch_size'"patch_size""patch_size""patch_size""patch_size", siehe set_texture_inspection_model_paramset_texture_inspection_model_paramSetTextureInspectionModelParamSetTextureInspectionModelParamSetTextureInspectionModelParam) ab und ergibt sich als:

Alle Bilder, die mit diesem Operator dem Modell hinzugefügt werden, werden zum Trainieren des Texturinspektionsmodells (siehe train_texture_inspection_modeltrain_texture_inspection_modelTrainTextureInspectionModelTrainTextureInspectionModelTrainTextureInspectionModel) verwendet. Des Weiteren ist es möglich, die hinzugefügten Bilder mit get_texture_inspection_model_imageget_texture_inspection_model_imageGetTextureInspectionModelImageGetTextureInspectionModelImageGetTextureInspectionModelImage abzufragen.

Jedes hinzugefügte Bild erhält einen Index (IndicesIndicesIndicesIndicesindices), der es dem Nutzer ermöglicht, eine einfache Zuordnung der hinzugefügten Bilddaten zu seiner Bilddatenbank herzustellen. Der Index kann außerdem dazu verwendet werden, um hinzugefügte Bilder die nicht mehr benötigt werden, mit remove_texture_inspection_model_imageremove_texture_inspection_model_imageRemoveTextureInspectionModelImageRemoveTextureInspectionModelImageRemoveTextureInspectionModelImage gezielt aus aus dem Modell zu entfernen.

Das Konzept der Texturinspektion ist bei der Einleitung zum Kapitel Inspektion / Texturinspektion beschrieben.

Ausführungsinformationen

Dieser Operator modifiziert den Zustand des folgenden Eingabeparameters:

Während der Ausführung dieses Operators muss der Zugriff auf den Wert dieses Parameters synchronisiert werden, wenn er über mehrere Threads hinweg verwendet wird.

Parameter

ImageImageImageImageimage (input_object)  singlechannelimage(-array) objectHImageHImageHobject (byte / uint2)

Eingabebild der zu trainierenden Textur.

TextureInspectionModelTextureInspectionModelTextureInspectionModelTextureInspectionModeltextureInspectionModel (input_control, Zustand wird modifiziert)  texture_inspection_model HTextureInspectionModel, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle des Texturinspektionsmodells.

IndicesIndicesIndicesIndicesindices (output_control)  integer(-array) HTupleHTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Indices der Bilder die dem Texturinspektionsmodell hinzugefügt wurden.

Beispiel (HDevelop)

* Create texture inspection model
create_texture_inspection_model ('basic', TextureInspectionModel)
* Make this short example fast:
set_texture_inspection_model_param (TextureInspectionModel, \
                                    'gmm_em_max_iter', 1)
* Read and add training images
read_image (TrainImage, 'carpet/carpet_01')
add_texture_inspection_model_image (TrainImage, TextureInspectionModel, \
                                    Indices)
* Train the model
train_texture_inspection_model (TextureInspectionModel)
* Read and apply a test image
read_image (TrainImage, 'carpet/carpet_02')
apply_texture_inspection_model (TestImage, DefectCandidates, \
                                TextureInspectionModel, \
                                TextureInspectionResultID)

Ergebnis

Der Operator add_texture_inspection_model_imageadd_texture_inspection_model_imageAddTextureInspectionModelImageAddTextureInspectionModelImageAddTextureInspectionModelImage gibt 2 (H_MSG_TRUE) zurück, sofern alle Parameter korrekt sind. Andernfalls wird eine Fehlerbehandlung ausgelöst.

Vorgänger

create_texture_inspection_modelcreate_texture_inspection_modelCreateTextureInspectionModelCreateTextureInspectionModelCreateTextureInspectionModel, set_texture_inspection_model_paramset_texture_inspection_model_paramSetTextureInspectionModelParamSetTextureInspectionModelParamSetTextureInspectionModelParam, get_texture_inspection_model_paramget_texture_inspection_model_paramGetTextureInspectionModelParamGetTextureInspectionModelParamGetTextureInspectionModelParam

Nachfolger

train_texture_inspection_modeltrain_texture_inspection_modelTrainTextureInspectionModelTrainTextureInspectionModelTrainTextureInspectionModel, clear_texture_inspection_modelclear_texture_inspection_modelClearTextureInspectionModelClearTextureInspectionModelClearTextureInspectionModel, remove_texture_inspection_model_imageremove_texture_inspection_model_imageRemoveTextureInspectionModelImageRemoveTextureInspectionModelImageRemoveTextureInspectionModelImage, get_texture_inspection_model_imageget_texture_inspection_model_imageGetTextureInspectionModelImageGetTextureInspectionModelImageGetTextureInspectionModelImage

Modul

Matching