HuguesTHOMAS/KPConv-PyTorch

An error occurred while running train_S3DIS.py data preparation!

Opened this issue · 5 comments

Hi THOMAS!thank you for your contribution!

I met an error while running train_S3DIS as following:

(pytorch) nky@nky-System-Product-Name:~/PycharmProjects/KPConv-pytorch$ python3 train_S3DIS.py

Data Preparation


Preparing ply files
Cloud Area_5 - Room 1/68 : conferenceRoom_2
Cloud Area_5 - Room 2/68 : office_23
Cloud Area_5 - Room 3/68 : office_29
Cloud Area_5 - Room 4/68 : office_12
Cloud Area_5 - Room 5/68 : office_20
Cloud Area_5 - Room 6/68 : office_10
Cloud Area_5 - Room 7/68 : office_41
Cloud Area_5 - Room 8/68 : office_33
Cloud Area_5 - Room 9/68 : pantry_1
Cloud Area_5 - Room 10/68 : hallway_14
Cloud Area_5 - Room 11/68 : hallway_2
Cloud Area_5 - Room 12/68 : hallway_8
Cloud Area_5 - Room 13/68 : office_30
Cloud Area_5 - Room 14/68 : office_25
Cloud Area_5 - Room 15/68 : office_11
Cloud Area_5 - Room 16/68 : office_5
Cloud Area_5 - Room 17/68 : office_14
Cloud Area_5 - Room 18/68 : office_19
Cloud Area_5 - Room 19/68 : hallway_10
Cloud Area_5 - Room 20/68 : office_26
Cloud Area_5 - Room 21/68 : office_4
Cloud Area_5 - Room 22/68 : storage_1
Cloud Area_5 - Room 23/68 : office_24
Cloud Area_5 - Room 24/68 : office_17
Cloud Area_5 - Room 25/68 : conferenceRoom_3
Cloud Area_5 - Room 26/68 : office_15
Cloud Area_5 - Room 27/68 : office_9
Cloud Area_5 - Room 28/68 : office_31
Cloud Area_5 - Room 29/68 : WC_1
Cloud Area_5 - Room 30/68 : office_16
Cloud Area_5 - Room 31/68 : hallway_11
Cloud Area_5 - Room 32/68 : WC_2
Cloud Area_5 - Room 33/68 : office_7
Cloud Area_5 - Room 34/68 : office_38
Cloud Area_5 - Room 35/68 : office_40
Cloud Area_5 - Room 36/68 : hallway_13
Cloud Area_5 - Room 37/68 : hallway_6
Traceback (most recent call last):
File "/home/nky/PycharmProjects/KPConv-pytorch/train_S3DIS.py", line 271, in
training_dataset = S3DISDataset(config, set='training', use_potentials=True)
File "/home/nky/PycharmProjects/KPConv-pytorch/datasets/S3DIS.py", line 135, in init
self.prepare_S3DIS_ply()
File "/home/nky/PycharmProjects/KPConv-pytorch/datasets/S3DIS.py", line 700, in prepare_S3DIS_ply
object_data = np.loadtxt(object_file, dtype=np.float32)
File "/home/nky/anaconda3/envs/pytorch/lib/python3.9/site-packages/numpy/lib/npyio.py", line 1318, in loadtxt
arr = _read(fname, dtype=dtype, comment=comment, delimiter=delimiter,
File "/home/nky/anaconda3/envs/pytorch/lib/python3.9/site-packages/numpy/lib/npyio.py", line 979, in _read
arr = _load_from_filelike(
ValueError: the number of columns changed from 6 to 5 at row 180389; use usecols to select a subset and avoid this error

I have no idea how to solve this problem.I would be grateful if you could help me with this problem.

Best regards!

Check you files, there might be an error in them and you will need to download the dataset again

Check you files, there might be an error in them and you will need to download the dataset again

thank you, but it`s that OK about dataset? I use S3DIS Aligned Version

I downloaded the dataset again and completed the training and testing, but there was a problem.

Open the Area_ 5. ply under the test result folder, the color displayed is only white, and different colors of different categories cannot be seen.

How can I solve this problem?

Thank you!Best regards!

Cloud Area_5 - Room 5/68 : office_15 Cloud Area_5 - Room 6/68 : office_31 Cloud Area_5 - Room 7/68 : office_33 Cloud Area_5 - Room 8/68 : office_9 Cloud Area_5 - Room 9/68 : hallway_8 Cloud Area_5 - Room 10/68 : office_32 Cloud Area_5 - Room 11/68 : hallway_4 Cloud Area_5 - Room 12/68 : conferenceRoom_2 Cloud Area_5 - Room 13/68 : hallway_6 Traceback (most recent call last): File "train_S3DIS.py", line 271, in <module> training_dataset = S3DISDataset(config, set='training', use_potentials=True) File "/home/shi/mycode/KPConv-PyTorch/datasets/S3DIS.py", line 134, in __init__ self.prepare_S3DIS_ply() File "/home/shi/mycode/KPConv-PyTorch/datasets/S3DIS.py", line 699, in prepare_S3DIS_ply object_data = np.loadtxt(object_file, dtype=np.float32) File "/home/shi/miniconda3/envs/kpconv/lib/python3.8/site-packages/numpy/lib/npyio.py", line 1318, in loadtxt arr = _read(fname, dtype=dtype, comment=comment, delimiter=delimiter, File "/home/shi/miniconda3/envs/kpconv/lib/python3.8/site-packages/numpy/lib/npyio.py", line 979, in _read arr = _load_from_filelike( ValueError: the number of columns changed from 6 to 5 at row 180389; use usecols to select a subset and avoid this error
I met the same error. How can I solve it?

There may be a problem with the S3DIS dataset, you can try to re-download the dataset, I did it and was able to run.

Cloud Area_5 - Room 5/68 : office_15 Cloud Area_5 - Room 6/68 : office_31 Cloud Area_5 - Room 7/68 : office_33 Cloud Area_5 - Room 8/68 : office_9 Cloud Area_5 - Room 9/68 : hallway_8 Cloud Area_5 - Room 10/68 : office_32 Cloud Area_5 - Room 11/68 : hallway_4 Cloud Area_5 - Room 12/68 : conferenceRoom_2 Cloud Area_5 - Room 13/68 : hallway_6 Traceback (most recent call last): File "train_S3DIS.py", line 271, in <module> training_dataset = S3DISDataset(config, set='training', use_potentials=True) File "/home/shi/mycode/KPConv-PyTorch/datasets/S3DIS.py", line 134, in __init__ self.prepare_S3DIS_ply() File "/home/shi/mycode/KPConv-PyTorch/datasets/S3DIS.py", line 699, in prepare_S3DIS_ply object_data = np.loadtxt(object_file, dtype=np.float32) File "/home/shi/miniconda3/envs/kpconv/lib/python3.8/site-packages/numpy/lib/npyio.py", line 1318, in loadtxt arr = _read(fname, dtype=dtype, comment=comment, delimiter=delimiter, File "/home/shi/miniconda3/envs/kpconv/lib/python3.8/site-packages/numpy/lib/npyio.py", line 979, in _read arr = _load_from_filelike( ValueError: the number of columns changed from 6 to 5 at row 180389; use usecols to select a subset and avoid this error I met the same error. How can I solve it?