Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up

Python binding for Grasp Pose Generator (pyGPG)

NotificationsYou must be signed in to change notification settings

lianghongzhuo/pygpg

Repository files navigation

DOI

Grasp Pose Generator is a cpp package that creat grasp candidates for 3D point clouds.This package binding it with python.

Install in conda environment

conda install -c conda-forge pcl cmake boost./build_pygpg.sh
  • Note, if the conda failed to find the correct package to install, you can try installingmamba and using mamba to install the dependencies:mamba install pcl cmake boost

Example:

importnumpyasnpimportpygpgpoints=np.random.rand(3000,3)# put your point cloud here, should be a nX3 numpy array, here is an example random arraynum_samples=10000show_grasp=Falsegripper_config_file="PATH_TO_GRIPPER_CONFIG_FILE"# see gripper_params.cfg for an examplegrasps=pygpg.generate_grasps(points,num_samples,show_grasp,gripper_config_file)# grasps is a list of grasp objet, to construct a Transformation matrix from each grasp object, use:pose_list= []forgraspingrasps:pose=np.eye(4)pose[:3,0]=grasp.get_grasp_approach()pose[:3,1]=grasp.get_grasp_binormal()pose[:3,2]=grasp.get_grasp_axis()pose[:3,3]=grasp.get_grasp_bottom()pose_list.append(pose)

Demo with a simple box:

python example/example.py

PressR to see the result:

Citation

If you found pyGPG useful in your research, please consider citing:

@software{pygpg,  author       = {Hongzhuo Liang},  title        = {Python binding for Grasp Pose Generator (pyGPG)},  month        = Aug,  year         = 2021,  doi          = {10.5281/zenodo.5247189},  url          = {https://doi.org/10.5281/zenodo.5247189}}

[8]ページ先頭

©2009-2025 Movatter.jp