Hey, thanks for releasing the code for the project!
I have one question, what do I need to change if I want to work with 480x640 images?
For now, in order to make them compatible with your framework out-of-the-box, I upscale the images to 720x1280, send them to the point-cloud helper to get the view_points and then call the networks, as you do in your demo.
My issue is that the final grasp predictions are going to be expressed in the upscaled pointcloud coordinates. So if I visualize the pointcloud I get from the resized 720x1280 images I get nice and tight grasps
but if I visualize them together with the original resolution pointcloud it is not (obviously).
I tried to manually post-process the translation component of the proposed grasps, e.g. multiplying by 0.5 to fit the resolution change, by still doesnt work.
Is it possible to make your demo.py run for image resolution (480, 640)? Following your implementation at demo.py I did the following changes:
Changed input_h, input_w in the arguments to half my desired size (240,320) as from what I understand thats what you need there (currently has 360,640 for 720x1280 images).
Changed the PointCloudHelper class to replace the (1280, 720) constants with (640, 480). In particular I changed the line ymap, xmap = np.meshgrid(np.arange(480), np.arange(640)) and the line factor = 640 / self.output_shape[0].
If I run the demo with this setting, I get the following error:
Traceback (most recent call last):
File "grasp_proposal_test.py", line 353, in <module>
pred_gg = inference(view_points,
File "grasp_proposal_test.py", line 149, in inference
pred_2d, perpoint_features = anchornet(x)
File "/home/p300488/miniconda3/envs/hggd/lib/python3.8/site-packages/torch/nn/modules/module.py", line 1110, in _call_impl
return forward_call(*input, **kwargs)
File "/home/p300488/6d_grasp_ws/src/hggd_grasp_server/src/inference/models/anchornet.py", line 213, in forward
x = layer(x + xs[self.depth - i])
RuntimeError: The size of tensor a (29) must match the size of tensor b (30) at non-singleton dimension 3
I assume that maybe there are some other hyper-parameters that need to be modified? Or some other change to make it run for my desired resolution? Please let me know if there is an easy fix for this!! Thank you!
Hey, thanks for releasing the code for the project!
I have one question, what do I need to change if I want to work with 480x640 images?
For now, in order to make them compatible with your framework out-of-the-box, I upscale the images to 720x1280, send them to the point-cloud helper to get the
view_points
and then call the networks, as you do in your demo.My issue is that the final grasp predictions are going to be expressed in the upscaled pointcloud coordinates. So if I visualize the pointcloud I get from the resized 720x1280 images I get nice and tight grasps but if I visualize them together with the original resolution pointcloud it is not (obviously).
I tried to manually post-process the translation component of the proposed grasps, e.g. multiplying by 0.5 to fit the resolution change, by still doesnt work.
Is it possible to make your
demo.py
run for image resolution (480, 640)? Following your implementation atdemo.py
I did the following changes:input_h, input_w
in the arguments to half my desired size (240,320) as from what I understand thats what you need there (currently has 360,640 for 720x1280 images).PointCloudHelper
class to replace the (1280, 720) constants with (640, 480). In particular I changed the lineymap, xmap = np.meshgrid(np.arange(480), np.arange(640))
and the linefactor = 640 / self.output_shape[0]
.If I run the demo with this setting, I get the following error:
I assume that maybe there are some other hyper-parameters that need to be modified? Or some other change to make it run for my desired resolution? Please let me know if there is an easy fix for this!! Thank you!