How jackaaron01/anygrasp_xarm6 works
This repository implements RGB-D-guided tabletop picking with an xArm6. The principal workflow captures aligned RealSense frames, builds a filtered point cloud, selects an AnyGrasp pose, transforms it using hand-eye calibration, and commands the arm to grasp. Separate entry points add repeated-pick recovery and detector-guided local grasping; README also documents visualization and a 197-configuration variant. The main entry point and grasp loop are sampled; some executor and recovery details are documented but not sampled, so uncertain internal wiring is omitted.
Main entry points: auto_pick_detect.py Target-guided entry · main.py Continuous entry · grasp_loop.py Single grasp inference · auto_pick.py Recovery loop
Components 22
Camera and geometry
- Frame capture
camera/realsense_utils.py - Point cloud conversion
camera/pointcloud_utils.py - Camera calibration
config/camera_params.py - 197 calibration
config/calibration_result.py - 197 camera parameters
config/camera_params_197.py
Grasp perception
- Single grasp inference
grasp/grasp_loop.py - Object detection
vision/detector_utils.py - Local grasp selection
auto_pick_detect.py
Robot control
- Pose transformation
grasp/grasp_pose.py - Grasp execution
grasp/grasp_executor.py - TCP movement
grasp/move_utils.py - Arm initialization
robot/xarm_utils.py - Pick-and-place cycle
grasp/grasp_cycle.py
Picking modes
- Continuous entry
main.py - Target-guided entry
auto_pick_detect.py - Recovery loop
auto_pick.py - Grasp visualization
test_gui.py - 197 entry
main_197.py
Other components
- Operator
- RealSense camera
- xArm6
- AnyGrasp SDK
Connections 39
- Operator → Continuous entry: starts
- Operator → Recovery loop: starts
- Operator → Target-guided entry: starts
- Operator → Grasp visualization: starts
- Operator → 197 entry: starts
- Continuous entry → AnyGrasp SDK: loads model
- Continuous entry → Frame capture: starts camera
- Continuous entry → Arm initialization: initializes arm
- Continuous entry → Single grasp inference: requests grasp
- Single grasp inference → Frame capture: captures frames
- Single grasp inference → Point cloud conversion: converts RGB-D
- Single grasp inference → Camera calibration: reads intrinsics
- Single grasp inference → AnyGrasp SDK: predicts grasps
- Frame capture → RealSense camera: reads frames
- Continuous entry → Pose transformation: transforms grasp
- Continuous entry → Camera calibration: reads transform
- Continuous entry → Grasp execution: executes grasp
- Continuous entry → TCP movement: passes movement helper
- Continuous entry → xArm6: commands
- Arm initialization → xArm6: connects
- Target-guided entry → Frame capture: captures frames
- Target-guided entry → Object detection: detects targets
- Target-guided entry → Local grasp selection: selects target region
- Local grasp selection → Point cloud conversion: builds local cloud
- Target-guided entry → AnyGrasp SDK: predicts local grasps
- Target-guided entry → Pose transformation: transforms grasp
- Target-guided entry → Camera calibration: reads calibration
- Target-guided entry → Arm initialization: initializes arm
- Target-guided entry → Pick-and-place cycle: uses when available
- Target-guided entry → Grasp execution: fallback execution
- Target-guided entry → TCP movement: passes movement helper
- Target-guided entry → xArm6: commands
- Recovery loop → Single grasp inference: repeats detection
- Recovery loop → Arm initialization: initializes arm
- Recovery loop → Grasp execution: executes grasps
- Recovery loop → xArm6: commands
- Grasp visualization → Single grasp inference: visualizes results
- 197 entry → 197 camera parameters: reads parameters
- 197 entry → Single grasp inference: requests grasp