Closed liangchunlan closed 2 years ago
When reading cam_coord in save_flow(), instead of
cam_coord = np.fromfile(info['cam_coords'], dtype=np.int32).reshape([-1, 2])
try
cam_coord = np.fromfile(info['cam_coords'], dtype=np.float32).astype(np.int16).reshape([-1, 2])
sorry for the bug. fixed.
I installed the PWC-DC network according to https://github.com/NVlabs/PWC-Net. When I ran “python tools/create_data nuscenes_data_prep --root_path /path/to/nuscenes” command, I encountered the following problems.
Traceback (most recent call last): File "motion/datasets/nuscenes/flow.py", line 654, in
res = save_flow(info, root_path)
File "motion/datasets/nuscenes/flow.py", line 638, in save_flow
optf[cam_id == cid, :2] = flo[cam_coord[cam_id == cid, 1].astype(np.int32), points[cam_id == cid, 0].astype(np.int32)]
IndexError: index 1147174912 is out of bounds for axis 0 with size 900
========================================== The following are some variables I checked, which are really out of range. I hope you can help me. Thank you very much.
print(points.shape)