refine_surface_model_poseT_refine_surface_model_poseRefineSurfaceModelPoseRefineSurfaceModelPoserefine_surface_model_pose (算子)

名称

refine_surface_model_poseT_refine_surface_model_poseRefineSurfaceModelPoseRefineSurfaceModelPoserefine_surface_model_pose — 优化三维场景中表模型的姿态。

签名

refine_surface_model_pose( : : SurfaceModelID, ObjectModel3D, InitialPose, MinScore, ReturnResultHandle, GenParamName, GenParamValue : Pose, Score, SurfaceMatchingResultID)

Herror T_refine_surface_model_pose(const Htuple SurfaceModelID, const Htuple ObjectModel3D, const Htuple InitialPose, const Htuple MinScore, const Htuple ReturnResultHandle, const Htuple GenParamName, const Htuple GenParamValue, Htuple* Pose, Htuple* Score, Htuple* SurfaceMatchingResultID)

void RefineSurfaceModelPose(const HTuple& SurfaceModelID, const HTuple& ObjectModel3D, const HTuple& InitialPose, const HTuple& MinScore, const HTuple& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Pose, HTuple* Score, HTuple* SurfaceMatchingResultID)

HPoseArray HObjectModel3D::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HPoseArray& InitialPose, const HTuple& MinScore, const HString& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResultArray* SurfaceMatchingResultID) const

HPose HObjectModel3D::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HPose& InitialPose, double MinScore, const HString& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResult* SurfaceMatchingResultID) const

HPose HObjectModel3D::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HPose& InitialPose, double MinScore, const char* ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResult* SurfaceMatchingResultID) const

HPose HObjectModel3D::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HPose& InitialPose, double MinScore, const wchar_t* ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResult* SurfaceMatchingResultID) const   ( Windows only)

HPoseArray HSurfaceModel::RefineSurfaceModelPose(const HObjectModel3D& ObjectModel3D, const HPoseArray& InitialPose, const HTuple& MinScore, const HString& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResultArray* SurfaceMatchingResultID) const

HPose HSurfaceModel::RefineSurfaceModelPose(const HObjectModel3D& ObjectModel3D, const HPose& InitialPose, double MinScore, const HString& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResult* SurfaceMatchingResultID) const

HPose HSurfaceModel::RefineSurfaceModelPose(const HObjectModel3D& ObjectModel3D, const HPose& InitialPose, double MinScore, const char* ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResult* SurfaceMatchingResultID) const

HPose HSurfaceModel::RefineSurfaceModelPose(const HObjectModel3D& ObjectModel3D, const HPose& InitialPose, double MinScore, const wchar_t* ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResult* SurfaceMatchingResultID) const   ( Windows only)

static HPoseArray HSurfaceMatchingResult::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HObjectModel3D& ObjectModel3D, const HPoseArray& InitialPose, const HTuple& MinScore, const HString& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score, HSurfaceMatchingResultArray* SurfaceMatchingResultID)

HPose HSurfaceMatchingResult::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HObjectModel3D& ObjectModel3D, const HPose& InitialPose, double MinScore, const HString& ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score)

HPose HSurfaceMatchingResult::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HObjectModel3D& ObjectModel3D, const HPose& InitialPose, double MinScore, const char* ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score)

HPose HSurfaceMatchingResult::RefineSurfaceModelPose(const HSurfaceModel& SurfaceModelID, const HObjectModel3D& ObjectModel3D, const HPose& InitialPose, double MinScore, const wchar_t* ReturnResultHandle, const HTuple& GenParamName, const HTuple& GenParamValue, HTuple* Score)   ( Windows only)

static void HOperatorSet.RefineSurfaceModelPose(HTuple surfaceModelID, HTuple objectModel3D, HTuple initialPose, HTuple minScore, HTuple returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple pose, out HTuple score, out HTuple surfaceMatchingResultID)

HPose[] HObjectModel3D.RefineSurfaceModelPose(HSurfaceModel surfaceModelID, HPose[] initialPose, HTuple minScore, string returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple score, out HSurfaceMatchingResult[] surfaceMatchingResultID)

HPose HObjectModel3D.RefineSurfaceModelPose(HSurfaceModel surfaceModelID, HPose initialPose, double minScore, string returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple score, out HSurfaceMatchingResult surfaceMatchingResultID)

HPose[] HSurfaceModel.RefineSurfaceModelPose(HObjectModel3D objectModel3D, HPose[] initialPose, HTuple minScore, string returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple score, out HSurfaceMatchingResult[] surfaceMatchingResultID)

HPose HSurfaceModel.RefineSurfaceModelPose(HObjectModel3D objectModel3D, HPose initialPose, double minScore, string returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple score, out HSurfaceMatchingResult surfaceMatchingResultID)

static HPose[] HSurfaceMatchingResult.RefineSurfaceModelPose(HSurfaceModel surfaceModelID, HObjectModel3D objectModel3D, HPose[] initialPose, HTuple minScore, string returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple score, out HSurfaceMatchingResult[] surfaceMatchingResultID)

HPose HSurfaceMatchingResult.RefineSurfaceModelPose(HSurfaceModel surfaceModelID, HObjectModel3D objectModel3D, HPose initialPose, double minScore, string returnResultHandle, HTuple genParamName, HTuple genParamValue, out HTuple score)

def refine_surface_model_pose(surface_model_id: HHandle, object_model_3d: HHandle, initial_pose: Sequence[Union[float, int]], min_score: MaybeSequence[Union[float, int]], return_result_handle: str, gen_param_name: Sequence[str], gen_param_value: Sequence[Union[str, float, int]]) -> Tuple[Sequence[Union[float, int]], Sequence[float], Sequence[HHandle]]

def refine_surface_model_pose_s(surface_model_id: HHandle, object_model_3d: HHandle, initial_pose: Sequence[Union[float, int]], min_score: MaybeSequence[Union[float, int]], return_result_handle: str, gen_param_name: Sequence[str], gen_param_value: Sequence[Union[str, float, int]]) -> Tuple[Sequence[Union[float, int]], Sequence[float], HHandle]

描述

算子 refine_surface_model_poserefine_surface_model_poseRefineSurfaceModelPoseRefineSurfaceModelPoseRefineSurfaceModelPoserefine_surface_model_pose refines the approximate pose InitialPoseInitialPoseInitialPoseInitialPoseinitialPoseinitial_pose of the surface model SurfaceModelIDSurfaceModelIDSurfaceModelIDSurfaceModelIDsurfaceModelIDsurface_model_id in the 3D scene ObjectModel3DObjectModel3DObjectModel3DObjectModel3DobjectModel3Dobject_model_3d. The surface model SurfaceModelIDSurfaceModelIDSurfaceModelIDSurfaceModelIDsurfaceModelIDsurface_model_id must have been created previously with create_surface_modelcreate_surface_modelCreateSurfaceModelCreateSurfaceModelCreateSurfaceModelcreate_surface_model or read_surface_modelread_surface_modelReadSurfaceModelReadSurfaceModelReadSurfaceModelread_surface_model。Additionally, set_surface_model_paramset_surface_model_paramSetSurfaceModelParamSetSurfaceModelParamSetSurfaceModelParamset_surface_model_param can be used to set certain parameters that influence the refinement, such as restricting the allowed range of rotations.

refine_surface_model_poserefine_surface_model_poseRefineSurfaceModelPoseRefineSurfaceModelPoseRefineSurfaceModelPoserefine_surface_model_pose is useful if the pose of an object in a scene is approximately known and only needs to be refined. The refined pose is returned in PosePosePosePoseposepose, along with a score in ScoreScoreScoreScorescorescore. It is possible to pass multiple poses for refinement. Note that, contrary to find_surface_modelfind_surface_modelFindSurfaceModelFindSurfaceModelFindSurfaceModelfind_surface_model, the returned poses are not sorted by their score but are returned in the same order as the input poses.

The maximum possible error in the approximate pose that can still be refined depends on the type of object, the amount of clutter in the scene and the visible parts of the objects. In general, differences in the orientation of up to 15° and differences in the position of up to 10% can be refined.

The accuracy of the pose refinement is limited to around 0.1% of the model's size due to numerical reasons. The accuracy further depends on the noise of the scene points, the number of scene points and the shape of the model.

Details about the pose refinement and the parameters are described in the documentation of find_surface_modelfind_surface_modelFindSurfaceModelFindSurfaceModelFindSurfaceModelfind_surface_model in the section about the dense pose refinement step. The following generic parameters can be set for refine_surface_model_poserefine_surface_model_poseRefineSurfaceModelPoseRefineSurfaceModelPoseRefineSurfaceModelPoserefine_surface_model_pose, and are also documented in find_surface_modelfind_surface_modelFindSurfaceModelFindSurfaceModelFindSurfaceModelfind_surface_model: 'pose_ref_num_steps'"pose_ref_num_steps""pose_ref_num_steps""pose_ref_num_steps""pose_ref_num_steps""pose_ref_num_steps", 'pose_ref_sub_sampling'"pose_ref_sub_sampling""pose_ref_sub_sampling""pose_ref_sub_sampling""pose_ref_sub_sampling""pose_ref_sub_sampling", 'pose_ref_dist_threshold_rel'"pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel", 'pose_ref_dist_threshold_abs'"pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs", 'pose_ref_scoring_dist_rel'"pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel", 'pose_ref_scoring_dist_abs'"pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs", 'pose_ref_use_scene_normals'"pose_ref_use_scene_normals""pose_ref_use_scene_normals""pose_ref_use_scene_normals""pose_ref_use_scene_normals""pose_ref_use_scene_normals", '3d_edge_min_amplitude_rel'"3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel", '3d_edge_min_amplitude_abs'"3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs", '3d_edges'"3d_edges""3d_edges""3d_edges""3d_edges""3d_edges", 'use_3d_edges'"use_3d_edges""use_3d_edges""use_3d_edges""use_3d_edges""use_3d_edges", 'use_view_based'"use_view_based""use_view_based""use_view_based""use_view_based""use_view_based", 'use_self_similar_poses'"use_self_similar_poses""use_self_similar_poses""use_self_similar_poses""use_self_similar_poses""use_self_similar_poses", 'pose_ref_dist_threshold_edges_rel'"pose_ref_dist_threshold_edges_rel""pose_ref_dist_threshold_edges_rel""pose_ref_dist_threshold_edges_rel""pose_ref_dist_threshold_edges_rel""pose_ref_dist_threshold_edges_rel", 'pose_ref_dist_threshold_edges_abs'"pose_ref_dist_threshold_edges_abs""pose_ref_dist_threshold_edges_abs""pose_ref_dist_threshold_edges_abs""pose_ref_dist_threshold_edges_abs""pose_ref_dist_threshold_edges_abs", 'pose_ref_scoring_dist_edges_rel'"pose_ref_scoring_dist_edges_rel""pose_ref_scoring_dist_edges_rel""pose_ref_scoring_dist_edges_rel""pose_ref_scoring_dist_edges_rel""pose_ref_scoring_dist_edges_rel", and 'pose_ref_scoring_dist_edges_abs'"pose_ref_scoring_dist_edges_abs""pose_ref_scoring_dist_edges_abs""pose_ref_scoring_dist_edges_abs""pose_ref_scoring_dist_edges_abs""pose_ref_scoring_dist_edges_abs".

执行信息

此算子返回一个句柄。请注意,即使该句柄被用作特定算子的输入参数,这些算子仍可能改变此句柄类型的实例状态。

此算子支持取消超时和中断。

参数

SurfaceModelIDSurfaceModelIDSurfaceModelIDSurfaceModelIDsurfaceModelIDsurface_model_id (输入控制)  surface_model HSurfaceModel, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of the surface model.

ObjectModel3DObjectModel3DObjectModel3DObjectModel3DobjectModel3Dobject_model_3d (输入控制)  object_model_3d HObjectModel3D, HTupleHHandleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of the 3D object model containing the scene.

InitialPoseInitialPoseInitialPoseInitialPoseinitialPoseinitial_pose (输入控制)  pose(-array) HPose, HTupleSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Initial pose of the surface model in the scene.

MinScoreMinScoreMinScoreMinScoreminScoremin_score (输入控制)  real(-array) HTupleMaybeSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Minimum score of the returned poses.

默认值: 0

限制: MinScore >= 0

ReturnResultHandleReturnResultHandleReturnResultHandleReturnResultHandlereturnResultHandlereturn_result_handle (输入控制)  string HTuplestrHTupleHtuple (string) (string) (HString) (char*)

Enable returning a result handle in SurfaceMatchingResultIDSurfaceMatchingResultIDSurfaceMatchingResultIDSurfaceMatchingResultIDsurfaceMatchingResultIDsurface_matching_result_id

默认值: 'false' "false" "false" "false" "false" "false"

值列表: 'false'"false""false""false""false""false", 'true'"true""true""true""true""true"

GenParamNameGenParamNameGenParamNameGenParamNamegenParamNamegen_param_name (输入控制)  attribute.name-array HTupleSequence[str]HTupleHtuple (string) (string) (HString) (char*)

通用参数的名称。

默认值: []

值列表: '3d_edge_min_amplitude_abs'"3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs""3d_edge_min_amplitude_abs", '3d_edge_min_amplitude_rel'"3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel""3d_edge_min_amplitude_rel", '3d_edges'"3d_edges""3d_edges""3d_edges""3d_edges""3d_edges", 'pose_ref_dist_threshold_abs'"pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs""pose_ref_dist_threshold_abs", 'pose_ref_dist_threshold_rel'"pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel""pose_ref_dist_threshold_rel", 'pose_ref_num_steps'"pose_ref_num_steps""pose_ref_num_steps""pose_ref_num_steps""pose_ref_num_steps""pose_ref_num_steps", 'pose_ref_scoring_dist_abs'"pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs""pose_ref_scoring_dist_abs", 'pose_ref_scoring_dist_rel'"pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel""pose_ref_scoring_dist_rel", 'pose_ref_sub_sampling'"pose_ref_sub_sampling""pose_ref_sub_sampling""pose_ref_sub_sampling""pose_ref_sub_sampling""pose_ref_sub_sampling", 'pose_ref_use_scene_normals'"pose_ref_use_scene_normals""pose_ref_use_scene_normals""pose_ref_use_scene_normals""pose_ref_use_scene_normals""pose_ref_use_scene_normals", 'use_3d_edges'"use_3d_edges""use_3d_edges""use_3d_edges""use_3d_edges""use_3d_edges", 'use_self_similar_poses'"use_self_similar_poses""use_self_similar_poses""use_self_similar_poses""use_self_similar_poses""use_self_similar_poses", 'use_view_based'"use_view_based""use_view_based""use_view_based""use_view_based""use_view_based", 'viewpoint'"viewpoint""viewpoint""viewpoint""viewpoint""viewpoint"

GenParamValueGenParamValueGenParamValueGenParamValuegenParamValuegen_param_value (输入控制)  attribute.value-array HTupleSequence[Union[str, float, int]]HTupleHtuple (string / real / integer) (string / double / int / long) (HString / double / Hlong) (char* / double / Hlong)

通用参数的值。

默认值: []

建议值: 0, 1, 'true'"true""true""true""true""true", 'false'"false""false""false""false""false", 0.005, 0.01, 0.03, 0.05, 0.1

PosePosePosePoseposepose (输出控制)  pose(-array) HPose, HTupleSequence[Union[float, int]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

3D pose of the surface model in the scene.

ScoreScoreScoreScorescorescore (输出控制)  real-array HTupleSequence[float]HTupleHtuple (real) (double) (double) (double)

Score of the found instances of the model.

SurfaceMatchingResultIDSurfaceMatchingResultIDSurfaceMatchingResultIDSurfaceMatchingResultIDsurfaceMatchingResultIDsurface_matching_result_id (输出控制)  surface_matching_result(-array) HSurfaceMatchingResult, HTupleSequence[HHandle]HTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of the matching result, if enabled in ReturnResultHandleReturnResultHandleReturnResultHandleReturnResultHandlereturnResultHandlereturn_result_handle

结果

refine_surface_model_poserefine_surface_model_poseRefineSurfaceModelPoseRefineSurfaceModelPoseRefineSurfaceModelPoserefine_surface_model_pose 在所有参数正确时返回 2 ( H_MSG_TRUE )。如有必要,则抛出异常。

可能的前趋

read_object_model_3dread_object_model_3dReadObjectModel3dReadObjectModel3dReadObjectModel3dread_object_model_3d, xyz_to_object_model_3dxyz_to_object_model_3dXyzToObjectModel3dXyzToObjectModel3dXyzToObjectModel3dxyz_to_object_model_3d, get_object_model_3d_paramsget_object_model_3d_paramsGetObjectModel3dParamsGetObjectModel3dParamsGetObjectModel3dParamsget_object_model_3d_params, read_surface_modelread_surface_modelReadSurfaceModelReadSurfaceModelReadSurfaceModelread_surface_model, create_surface_modelcreate_surface_modelCreateSurfaceModelCreateSurfaceModelCreateSurfaceModelcreate_surface_model, get_surface_model_paramget_surface_model_paramGetSurfaceModelParamGetSurfaceModelParamGetSurfaceModelParamget_surface_model_param, find_surface_modelfind_surface_modelFindSurfaceModelFindSurfaceModelFindSurfaceModelfind_surface_model, edges_object_model_3dedges_object_model_3dEdgesObjectModel3dEdgesObjectModel3dEdgesObjectModel3dedges_object_model_3d

可能的后继

get_surface_matching_resultget_surface_matching_resultGetSurfaceMatchingResultGetSurfaceMatchingResultGetSurfaceMatchingResultget_surface_matching_result, clear_surface_matching_resultclear_surface_matching_resultClearSurfaceMatchingResultClearSurfaceMatchingResultClearSurfaceMatchingResultclear_surface_matching_result, clear_object_model_3dclear_object_model_3dClearObjectModel3dClearObjectModel3dClearObjectModel3dclear_object_model_3d

替代

find_surface_modelfind_surface_modelFindSurfaceModelFindSurfaceModelFindSurfaceModelfind_surface_model, refine_surface_model_pose_imagerefine_surface_model_pose_imageRefineSurfaceModelPoseImageRefineSurfaceModelPoseImageRefineSurfaceModelPoseImagerefine_surface_model_pose_image, find_surface_model_imagefind_surface_model_imageFindSurfaceModelImageFindSurfaceModelImageFindSurfaceModelImagefind_surface_model_image

另见

create_surface_modelcreate_surface_modelCreateSurfaceModelCreateSurfaceModelCreateSurfaceModelcreate_surface_model, find_surface_modelfind_surface_modelFindSurfaceModelFindSurfaceModelFindSurfaceModelfind_surface_model, refine_surface_model_pose_imagerefine_surface_model_pose_imageRefineSurfaceModelPoseImageRefineSurfaceModelPoseImageRefineSurfaceModelPoseImagerefine_surface_model_pose_image

模块

三维计量