shanice-l / gdrnpp_bop2022

PyTorch Implementation of GDRNPP, winner (most of the awards) of the BOP Challenge 2022 at ECCV'22
Apache License 2.0
215 stars 49 forks source link

Custom training xyz and region loss debugging #84

Open cnalty opened 6 months ago

cnalty commented 6 months ago

I'm trying to train on a custom dataset, and I'm having trouble with some of the losses. I'm getting loss_coor_x,y,z is always 0 (even on the first iteration), and loss_region stays constant throughout the entirety of my training. I'm assuming this has something to do with my object renders not coming out correctly, so I've tried running egl_renderer.py's main replacing the models with my dataset's models. However, I run into an error about not having some robotPose file. If I set robot name to an empty string I get this error:

Traceback (most recent call last): File "/usr/lib/python3.8/runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "/usr/lib/python3.8/runpy.py", line 87, in _run_code exec(code, run_globals) File "/home/chris/PycharmProjects/gdrnpp_bop2022/lib/egl_renderer/egl_renderer.py", line 1573, in renderer = EGLRenderer( File "/home/chris/PycharmProjects/gdrnpp_bop2022/lib/egl_renderer/egl_renderer.py", line 305, in init self.grid = self.generate_grid() File "/home/chris/PycharmProjects/gdrnpp_bop2022/lib/egl_renderer/egl_renderer.py", line 349, in generate_grid positionAttrib = GL.glGetAttribLocation(self.shader_programs["shader_simple"], "aPosition") KeyError: 'shader_simple'

Is this the way I should try to debug my rendering, or should I go about it some other way?

shanice-l commented 6 months ago

Hi, I assume the problem existed in the format of the CAD model. You can try to use the script to verify the XYZ map.