clear_texture_inspection_result -清除纹理检查结果句柄并释放分配的内存
简短描述
clear_texture_inspection_result -清除纹理检查结果句柄并释放分配的内存
签名
clear_texture_inspection_result( : : TextureInspectionResultID : )
描述
操作符clear_texture_inspection_result清除apply_texture_inspection_model创建的纹理检查结果TextureInspectionResultID。释放模型使用的所有内存。在操作符调用之后,模型的句柄无效。
TextureInspectionResultID
如果没有外部同步,此参数的值不能在多个线程之间共享。
参数
texture_inspectionresultid (input_control, state is modified) texture_inspection_result(-array)→(integer)
纹理检查结果的句柄。
例程
* 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)
* Set parameter to generate a result handle
set_texture_inspection_model_param (TextureInspectionModel, \
'gen_result_handle', 'true')
* 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 (TestImage, 'carpet/carpet_02')
apply_texture_inspection_model (TestImage, DefectCandidates, \
TextureInspectionModel, \
TextureInspectionResultID)
* Clean up
clear_texture_inspection_model (TextureInspectionModel)
clear_texture_inspection_result (TextureInspectionResultID)
返回结果
本文链接:https://www.wtao8.com/post/243.html 转载需授权!