tatarchm / tangent_conv

Tangent Convolutions for Dense Prediction in 3D
122 stars 26 forks source link

Problem precomputing S3DIS Area_5_hallway_6 #6

Closed tejaskhot closed 6 years ago

tejaskhot commented 6 years ago

In the precompute step, on running python tc.py experiments/stanford/dhnrgb/config.json --precompute, I get:

:: precompute
processing scan: Area_5_hallway_6, rot: 0
Traceback (most recent call last):
  File "tc.py", line 21, in <module>
    run_precompute(config)
  File "util/precompute.py", line 93, in run_precompute
    labels_gt=np.reshape(np.asarray(pcd_labels_down.point_cloud.colors)[:, 0], (num_points)),
  File "/usr0/home/tkhot/anaconda3/envs/tensorflow/lib/python3.6/site-packages/numpy/core/fromnumeric.py", line 257, in reshape
    return _wrapfunc(a, 'reshape', newshape, order=order)
  File "/usr0/home/tkhot/anaconda3/envs/tensorflow/lib/python3.6/site-packages/numpy/core/fromnumeric.py", line 52, in _wrapfunc
    return getattr(obj, method)(*args, **kwds)
ValueError: cannot reshape array of size 0 into shape (46214,)

Here, pcd_labels_down.point_cloud.colors is empty although in the preceding step before downsampling, pcd_labels.colors is correctly sized.

syncle commented 6 years ago

Not quite sure based on the provided log file. Just quick answer: can you check Area_5_hallway_6 is correctly downloaded?

tejaskhot commented 6 years ago

I tried downloading the data zip file again and ran into the same issue. The colors data is present until the down sampling step but is empty as the result of the downsampling. This happens for: Area_5_office_20 and Area_5_hallway_6.

tatarchm commented 6 years ago

The problem was in the 'get_data.py' script. The two scans you've mentioned have bad points which were not present in the output .pcd files but were present in the .labels files. This caused a shape mismatch. I fixed this now, you can re-run the 'get_data.py' script.

tejaskhot commented 6 years ago

That fixed it. Thanks!