Hello,
I installed gqcnn ros service on ROS kinetic and used pretrained models for doing some sample tests for Grasp planning on some of my cuboid shaped objects.But Grasp sampler seems to be doing wrong sampling or not be to sample proper antipodal points along edges of my object.In first 2 iterations it seems to have got some antipodal points but still not perfectly aligned to my object geometry.In final iteration all those grasps are also filtered leaving sampler with some on body grasps.Kindly have a look into images attached below.
RGBD Cropped image
Sampled antipodal points
Following is my log output.I did enabled debug logs to get more clearity. Kindly help me solve this issue.Also find grasp_sampler_node.yaml file data following the logs.
root@akashp-Latitude-E5570:~/catkin_ws# roslaunch gqcnn gqcnn.launch
... logging to /home/akashp/.ros/log/af0cabda-c938-11e7-a093-f0d5bf915032/roslaunch-akashp-Latitude-E5570-10112.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://akashp-Latitude-E5570:46762/
SUMMARY
PARAMETERS
- /GQCNN_grasp_planner/config: /home/akashp/catk...
- /rosdistro: kinetic
- /rosversion: 1.12.7
NODES
/
GQCNN_grasp_planner (gqcnn/grasp_planner_node.py)
ROS_MASTER_URI=http://localhost:11311
core service [/rosout] found
process[GQCNN_grasp_planner-1]: started with pid [10161]
WARNING:root:autolab_core not installed as catkin package, RigidTransform ros methods will be unavailable
WARNING:root:Unable to import pylibfreenect2. Python-only Kinect driver may not work properly.
WARNING:root:Unable to import openni2 driver. Python-only Primesense driver may not work properly
WARNING:root:primesense_sensor.py not installed as catkin package. ROS functionality not available.
[INFO] [1510669240.601043]: Creating Grasp Policy
2017-11-14 19:50:40.799114: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations.
2017-11-14 19:50:40.799143: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations.
2017-11-14 19:50:40.799157: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations.
2017-11-14 19:50:40.799166: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX2 instructions, but these are available on your machine and could speed up CPU computations.
2017-11-14 19:50:40.799174: W tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use FMA instructions, but these are available on your machine and could speed up CPU computations.
[INFO] [1510669240.990180]: Grasp Sampler Server Initialized
[INFO] [1510669241.244419]: Planning Grasp
[INFO] [1510669243.259270]: Planning Grasp
2017-11-14 19:50:43,259 - root - DEBUG - Sampling 2d candidates
2017-11-14 19:50:43,262 - root - DEBUG - Depth edge detection took 0.002 sec
2017-11-14 19:50:43,262 - root - DEBUG - Found 3322 edge pixels
2017-11-14 19:50:43,318 - root - DEBUG - Normal computation took 0.056 sec
2017-11-14 19:50:43,601 - root - DEBUG - Normal pruning 0.283 sec
/home/akashp/catkin_ws/src/gqcnn/./gqcnn/image_grasp_sampler.py:40: RuntimeWarning: invalid value encountered in arccos
in_cone_2 = (np.arccos(n2.dot(v)) < alpha)
2017-11-14 19:50:44,108 - root - DEBUG - Sampled 200 grasps from image
2017-11-14 19:50:44,108 - root - DEBUG - Sampling grasps took 0.849 sec
2017-11-14 19:50:44,108 - root - DEBUG - Computing the seed set took 0.849 sec
2017-11-14 19:50:44,153 - root - DEBUG - Tensor conversion took 0.044 sec
2017-11-14 19:50:44,154 - root - DEBUG - CEM iter 0
2017-11-14 19:50:44,154 - root - DEBUG - Predicting file 0
2017-11-14 19:50:44,286 - root - DEBUG - Predicting file 16
2017-11-14 19:50:44,416 - root - DEBUG - Predicting file 32
2017-11-14 19:50:44,545 - root - DEBUG - Predicting file 48
2017-11-14 19:50:44,677 - root - DEBUG - Predicting file 64
2017-11-14 19:50:44,818 - root - DEBUG - Predicting file 80
2017-11-14 19:50:44,953 - root - DEBUG - Predicting file 96
2017-11-14 19:50:45,088 - root - DEBUG - Predicting file 112
2017-11-14 19:50:45,222 - root - DEBUG - Predicting file 128
2017-11-14 19:50:45,356 - root - DEBUG - Predicting file 144
2017-11-14 19:50:45,489 - root - DEBUG - Predicting file 160
2017-11-14 19:50:45,632 - root - DEBUG - Predicting file 176
2017-11-14 19:50:45,772 - root - DEBUG - Predicting file 192
2017-11-14 19:50:45,913 - root - DEBUG - Prediction took 1.759 sec
2017-11-14 19:50:52,938 - root - DEBUG - GMM fitting with 20 components took 0.038 sec
2017-11-14 19:50:52,941 - root - DEBUG - GMM sampling took 0.003 sec
2017-11-14 19:50:52,960 - root - DEBUG - Tensor conversion took 0.017 sec
2017-11-14 19:50:52,960 - root - DEBUG - CEM iter 1
2017-11-14 19:50:52,960 - root - DEBUG - Predicting file 0
2017-11-14 19:50:53,113 - root - DEBUG - Predicting file 16
2017-11-14 19:50:53,249 - root - DEBUG - Predicting file 32
2017-11-14 19:50:53,375 - root - DEBUG - Predicting file 48
2017-11-14 19:50:53,507 - root - DEBUG - Prediction took 0.547 sec
2017-11-14 19:50:56,777 - root - DEBUG - GMM fitting with 6 components took 0.004 sec
2017-11-14 19:50:56,781 - root - DEBUG - GMM sampling took 0.003 sec
2017-11-14 19:50:56,802 - root - DEBUG - Tensor conversion took 0.019 sec
2017-11-14 19:50:56,802 - root - DEBUG - CEM iter 2
2017-11-14 19:50:56,802 - root - DEBUG - Predicting file 0
2017-11-14 19:50:56,981 - root - DEBUG - Predicting file 16
2017-11-14 19:50:57,117 - root - DEBUG - Predicting file 32
2017-11-14 19:50:57,254 - root - DEBUG - Predicting file 48
2017-11-14 19:50:57,391 - root - DEBUG - Prediction took 0.589 sec
2017-11-14 19:51:03,555 - root - DEBUG - GMM fitting with 6 components took 0.022 sec
2017-11-14 19:51:03,556 - root - DEBUG - GMM sampling took 0.001 sec
2017-11-14 19:51:03,576 - root - DEBUG - Tensor conversion took 0.018 sec
2017-11-14 19:51:03,577 - root - DEBUG - Predicting file 0
2017-11-14 19:51:03,742 - root - DEBUG - Predicting file 16
2017-11-14 19:51:03,883 - root - DEBUG - Predicting file 32
2017-11-14 19:51:04,013 - root - DEBUG - Predicting file 48
2017-11-14 19:51:04,151 - root - DEBUG - Final prediction took 0.574 sec
[INFO] [1510669284.796026]: Total grasp planning time: 41.5362010002 secs.
2017-11-14 19:51:24,795 - rosout - INFO - Total grasp planning time: 41.5362010002 secs.
grasp_sampler_node.yaml
visualization
vis:
vis_cropped_rgbd_image: 1
vis_uncropped_color_image: 0
vis_uncropped_depth_image: 0
padding for the cropped images so when they are rotated to be centered on the grasp point there will not be any gaps where there is no part of the image
width_pad: 0
height_pad: 0
inpaint
inpaint_rescale_factor: 0.5 # amount to rescale the images before inpainting (smaller numbers == faster code)
policy params
policy:
optimization params
num_seed_samples: 200 # number of seed samples
num_gmm_samples: 50
num_iters: 3
gmm_refit_p: 0.25
gmm_component_frac: 0.4
gmm_reg_covar: 0.01
gqcnn params
gqcnn_model: /home/akashp/Work/GQ-Image-Wise
general params
deterministic: 1
gripper_width: 0.140
crop_height: 96
crop_width: 96
#logging_dir: /home/akashp/Work
sampling params
sampling:
# type
type: antipodal_depth
# antipodality
friction_coef: 1.0
depth_grad_thresh: 0.0025
depth_grad_gaussian_sigma: 1.0
downsample_rate: 4
max_rejection_samples: 2500
# distance
max_dist_from_center: 10000000
min_dist_from_boundary: 40
min_grasp_dist: 2.5
angle_dist_weight: 5.0
# depth sampling
depth_samples_per_grasp: 1
depth_sample_win_height: 1
depth_sample_win_width: 1
min_depth_offset: 0.015
max_depth_offset: 0.0
visualization
vis:
grasp_sampling : 0
tf_images: 0
grasp_candidates: 1
elite_grasps: 0
grasp_ranking: 0
grasp_plan: 1
final_grasp: 1
k: 25