Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using different H and W resolution #66

Open
michaelbaltaxe opened this issue May 29, 2024 · 0 comments
Open

Using different H and W resolution #66

michaelbaltaxe opened this issue May 29, 2024 · 0 comments

Comments

@michaelbaltaxe
Copy link

I have changed tpv_h_ and tpv_w_ in config/tpv04_occupancy.py so that the resolution of the grid is different in each direction.
Now I am getting the following error when calculating the loss function during training for occupancy estimation (line 205 in train.py):
Screenshot from 2024-05-29 16-54-05

The issue seems to come from an inconsistency in the use of H and W dimensions.
According to config/tpv04_occupancy.py, H corresponds to the first dimension and W to the second:
grid_size = [tpv_h_*scale_h, tpv_w_*scale_w, tpv_z_*scale_z]

However, in tpvformer04/tpv_aggregator.py the role of H and W are inverted (W is used for the first dimension and H is used for the second dimension):
Screenshot from 2024-05-29 17-01-05
Screenshot from 2024-05-29 17-01-18

When using the code in the repository this error does not happen because H = W = 100 and the calculations are consistent. However when tpv_h_ != tpv_w_ the shapes do not correspond.

It seems to me that I need to work on tpvformer04/tpv_aggregator.py and on tpvformer04/tpv_head.py to be able to run with tpv_h_ != tpv_w_. However, I am not sure if this is correct and if there are other sections of the code that need to be updated. Could you point me on how to address this issue? Is there an easier way to do it?

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant