sparse-ncnet icon indicating copy to clipboard operation
sparse-ncnet copied to clipboard

Dimension error when evaluate on inloc dataset.

Open PANCHEN-AMA opened this issue 4 years ago • 2 comments

Hello! I'm going to try your method on InLoc dataset. When I ran the eval/eval_inloc_extract.py. I got this error.

Traceback (most recent call last): File "/media/pc/E68247168246EB1F/sparse-ncnet/eval/eval_inloc_extract.py", line 167, in <module> args File "/media/pc/E68247168246EB1F/sparse-ncnet/lib/relocalize.py", line 187, in eval_model_reloc corr4d = corr_and_add(feature_A, feature_B, k = model.k, Npts=None) File "/media/pc/E68247168246EB1F/sparse-ncnet/lib/sparse.py", line 147, in corr_and_add scorr = ME.MinkowskiUnion()(scorr,scorr2) File "/home/pc/.pyenv/versions/anaconda3-5.3.1/envs/sncnet/lib/python3.6/sitepackages/MinkowskiEngine/MinkowskiUnion.py", line 100, in __init__ assert dimension > 0, f"dimension must be a positive integer, {dimension}" AssertionError: dimension must be a positive integer, -1

Could you provide some ideas about how to solve it? Thank you very much!

PANCHEN-AMA avatar Jun 09 '20 08:06 PANCHEN-AMA

It seems some tensor is empty. Maybe you can set a breakpoint and debug with import pdb; pdb.set_trace()?

ignacio-rocco avatar Jun 09 '20 09:06 ignacio-rocco

Thank you for your quick reply. I checked the shape of scorr and scorr2 after transfering to sparseTensor. They are both 300000*1 Tensor. They are not empty. But MinkowskiUnion()(scorr, scorr2) is failed due to the above reason. Maybe they didn't satisfy the dimension they are supposed to be?

PANCHEN-AMA avatar Jun 09 '20 09:06 PANCHEN-AMA