guochengqian / PointNeXt

[NeurIPS'22] PointNeXt: Revisiting PointNet++ with Improved Training and Scaling Strategies
https://guochengqian.github.io/PointNeXt/
MIT License
757 stars 108 forks source link

ValueError: cannot reshape array of size 2097142 into shape (780299,7) #18

Closed JackieWang9811 closed 2 years ago

JackieWang9811 commented 2 years ago

Hi, Great work and thanks for releasing the Code. There is an error below, Is it related to numpy? Thanks a lot.

''[07/12 10:37:08 S3DIS]: Successful Loading the ckpt from log/s3dis/s3dis-train-pointnext-l-ngpus1-seed8572-20220711-202106-MtuyFobTuHUC9ZWGpn9bng/checkpoint/s3dis-train-pointnext-l-ngpus1-seed8572-20220711-202106-MtuyFobTuHUC9ZWGpn9bng_ckpt_best.pth [07/12 10:37:08 S3DIS]: ckpts @ 66 epoch( {'best_val': 67.55729675292969} ) 0%| | 0/63 [00:00<?, ?it/s]examples/segmentation/main.py:395: DeprecationWarning: np.int is a deprecated alias for the builtin int. To silence this warning, use int by itself. Doing this will not modify any behavior and is safe. When replacing np.int, you may wish to use e.g. np.int64 or np.int32 to specify the precision. If you wish to review your current use, check the release note link for additional information. Deprecated in NumPy 1.20; for more details and guidance: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations label = torch.from_numpy(cdata[:, 6].astype(np.int).squeeze()).cuda(non_blocking=True) 6%|██▋ | 4/63 [02:00<36:23, 37.02s/it] 17%|███████▎ | 11/63 [11:03<42:01, 48.48s/it] 95%|████████████████████████████████████████ | 60/63 [57:40<02:53, 57.68s/it] Traceback (most recent call last): File "examples/segmentation/main.py", line 528, in main(0, cfg) File "examples/segmentation/main.py", line 208, in main test_miou, test_macc, test_oa, test_ious, testaccs, = test_entire_room(model, cfg.dataset.common.test_area, cfg) File "/home/olan/anaconda3/envs/openpoints/lib/python3.7/site-packages/torch/autograd/grad_mode.py", line 28, in decorate_context return func(*args, *kwargs) File "examples/segmentation/main.py", line 392, in test_entire_room cdata = np.load(data_path).astype(np.float32) # xyz, rgb, label, N7 File "/home/olan/anaconda3/envs/openpoints/lib/python3.7/site-packages/numpy/lib/npyio.py", line 441, in load pickle_kwargs=pickle_kwargs) File "/home/olan/anaconda3/envs/openpoints/lib/python3.7/site-packages/numpy/lib/format.py", line 783, in read_array array.shape = shape ValueError: cannot reshape array of size 2097142 into shape (780299,7)

guochengqian commented 2 years ago

could you please share the command

JackieWang9811 commented 2 years ago

could you please share the command of course, the command is bash script/main_segmentation.sh cfgs/s3dis/pointnext-l.yaml