davidtvs / PyTorch-ENet

PyTorch implementation of ENet
MIT License
389 stars 129 forks source link

dataset folder structure #39

Closed svenikea closed 3 years ago

svenikea commented 4 years ago

Hi mate, I was trying to test the Cityscape dataset with this command

python main.py -m train --save-dir save/ENet_Cityscapes/ --name test --dataset cityscapes --dataset-dir data/leftImg8bit_trainvaltest

But it gave me this


Loading dataset...

Selected dataset: cityscapes
Dataset directory: data/leftImg8bit_trainvaltest
Save directory: save/ENet_Cityscapes/
Traceback (most recent call last):
  File "main.py", line 298, in <module>
    loaders, w_class, class_encoding = load_dataset(dataset)
  File "main.py", line 45, in load_dataset
    train_set = dataset(
  File "/home/john/Desktop/PyTorch-ENet/data/cityscapes.py", line 84, in __init__
    self.train_data = utils.get_files(
  File "/home/john/Desktop/PyTorch-ENet/data/utils.py", line 19, in get_files
    raise RuntimeError("\"{0}\" is not a folder.".format(folder))
RuntimeError: "data/leftImg8bit_trainvaltest/leftImg8bit_trainvaltest/leftImg8bit/train" is not a folder.

I have tried different way but it keeps saying is not a folder Can you recommend a directory structure? that would be great

davidtvs commented 4 years ago

You need to provide the path to the root of the Cityscapes dataset, in your case this is the data folder. The current implementation expects to get the folder that contains the the leftImg8bit_trainvaltest folder, as you can see here.

Let me know if that worked

davidtvs commented 3 years ago

Closing due to inactivity