1.安装 MinkowskiEngine
安装MinkowskiEngine时可能会有些问题,因为要求的环境比较旧,有些库的版本较低,参考/issues/594,/issues/596,/issues/543
首先按commit进行修改
export TORCH_CUDA_ARCH_LIST="8.9"
export CUDA_HOME=/usr/local/cuda-12.1
export MAX_JOBS=2
安装依赖:
conda install openblas-devel -c anaconda
我的conda环境:
Package Version
----------------------------- --------------
actionlib 1.14.0
angles 1.9.13
base_local_planner 1.17.3
bondpy 1.8.6
camera-calibration 1.17.0
camera-calibration-parsers 1.12.0
catkin 0.8.10
controller-manager 0.20.0
controller-manager-msgs 0.20.0
cv-bridge 1.16.2
diagnostic-analysis 1.11.0
diagnostic-common-diagnostics 1.11.0
diagnostic-updater 1.11.0
dynamic-reconfigure 1.7.3
filelock 3.16.1
fsspec 2024.12.0
gazebo_plugins 2.9.2
gazebo_ros 2.9.2
gencpp 0.7.0
geneus 3.0.0
genlisp 0.4.18
genmsg 0.6.0
gennodejs 2.0.2
genpy 0.6.15
image-geometry 1.16.2
interactive-markers 1.12.0
Jinja2 3.1.5
joint-state-publisher 1.15.1
joint-state-publisher-gui 1.15.1
laser_geometry 1.6.7
MarkupSafe 3.0.2
message-filters 1.17.0
MinkowskiEngine 0.5.4
moveit-commander 1.1.16
moveit-core 1.1.16
moveit-python 0.4.5
moveit-ros-planning-interface 1.1.16
moveit-ros-visualization 1.1.16
moveit-task-constructor-core 0.1.3
mpmath 1.3.0
networkx 3.4.2
numpy 2.2.1
nvidia-cublas-cu12 12.1.3.1
nvidia-cuda-cupti-cu12 12.1.105
nvidia-cuda-nvrtc-cu12 12.1.105
nvidia-cuda-runtime-cu12 12.1.105
nvidia-cudnn-cu12 8.9.2.26
nvidia-cufft-cu12 11.0.2.54
nvidia-curand-cu12 10.3.2.106
nvidia-cusolver-cu12 11.4.5.107
nvidia-cusparse-cu12 12.1.0.106
nvidia-nccl-cu12 2.20.5
nvidia-nvjitlink-cu12 12.6.85
nvidia-nvtx-cu12 12.1.105
pillow 11.1.0
pip 24.2
python-qt-binding 0.4.4
qt-dotgraph 0.4.2
qt-gui 0.4.2
qt-gui-cpp 0.4.2
qt-gui-py-common 0.4.2
resource_retriever 1.12.7
rosbag 1.17.0
rosboost-cfg 1.15.8
rosclean 1.15.8
roscreate 1.15.8
rosgraph 1.17.0
roslaunch 1.17.0
roslib 1.15.8
roslint 0.12.0
roslz4 1.17.0
rosmake 1.15.8
rosmaster 1.17.0
rosmsg 1.17.0
rosnode 1.17.0
rosparam 1.17.0
rospy 1.17.0
rosservice 1.17.0
rostest 1.17.0
rostopic 1.17.0
rosunit 1.15.8
roswtf 1.17.0
rqt_action 0.4.9
rqt_bag 0.5.1
rqt_bag_plugins 0.5.1
rqt-console 0.4.12
rqt_dep 0.4.12
rqt_graph 0.4.14
rqt_gui 0.5.3
rqt_gui_py 0.5.3
rqt-image-view 0.4.17
rqt_launch 0.4.9
rqt-logger-level 0.4.12
rqt-moveit 0.5.11
rqt_msg 0.4.10
rqt_nav_view 0.5.7
rqt_plot 0.4.13
rqt_pose_view 0.5.11
rqt_publisher 0.4.10
rqt_py_common 0.5.3
rqt_py_console 0.4.10
rqt-reconfigure 0.5.5
rqt-robot-dashboard 0.5.8
rqt-robot-monitor 0.5.15
rqt_robot_steering 0.5.12
rqt-runtime-monitor 0.5.10
rqt-rviz 0.7.0
rqt_service_caller 0.4.10
rqt_shell 0.4.11
rqt_srv 0.4.9
rqt-tf-tree 0.6.4
rqt_top 0.4.10
rqt_topic 0.4.13
rqt_web 0.4.10
rviz 1.14.25
sensor-msgs 1.13.1
setuptools 59.6.0
smach 2.5.2
smach-ros 2.5.2
smclib 1.8.6
srdfdom 0.6.4
sympy 1.13.3
tf 1.13.2
tf-conversions 1.13.2
tf2-geometry-msgs 0.7.7
tf2-kdl 0.7.7
tf2-py 0.7.7
tf2-ros 0.7.7
topic-tools 1.17.0
torch 2.3.1+cu121
torchaudio 2.3.1+rocm6.0
torchvision 0.18.1+rocm6.0
trac_ik_python 1.6.6
triton 2.3.1
typing_extensions 4.12.2
urdfdom-py 0.4.6
wheel 0.44.0
xacro 1.14.18
安装 MinkowskiEngine:
python setup.py install --blas_include_dirs=${CONDA_PREFIX}/include --blas=openblas
安装如果出现有关numpy.distutils
的报错包装低版本的库就可以了(setuptools
)。
安装成功:
2.安装其他依赖
git clone https://github.com/graspnet/anygrasp_sdk.git
pip install -r requirements.txt
其中和grasp最相关的是 graspnetAPI,我在install的过程安装不成功graspnetAPI,于是我便单独源码安装了。
3.安装 graspnetAPI
pip install graspnetAPI
or (the way for me)
git clone https://github.com/graspnet/graspnetAPI.git
cd graspnetAPI
pip install .
这一步也会安装挺多依赖,见上图中的install_requires
。
如果在安装graspnetAPI
时遇到某些库安装不成功可以先单独安装该库,邻近版本有时候也是可以的,可以多试试(e.g. 我安装numpy1.20.3没有成功,但是我安装numpy1.21.1是成功的,后面也是可以成功应用anygrasp的)。
4.安装 pointnet2
cd /anygrasp_sdk/pointnet2/
python setup.py install
5. AnyGrasp Detection Demo
获取到的个人license
要放到此目录下并重命名为“license”
6. AnyGrasp Tracking Demo
获取到的个人license
要放到此目录下并重命名为“license”