FileNotFoundError: [Errno 2] Нет такого файла или каталога: '/ coco / images / people-train2017-wrapper' - PullRequest
0 голосов
/ 21 апреля 2020

Я пытаюсь следовать этому репозиторию github https://github.com/Maninae/segmentation-191, но продолжаю сталкиваться с этой ошибкой. Я попытался:

  1. Чтобы запустить его на своем ноутбуке с помощью командной строки, но это было слишком медленно
  2. Я сейчас использую Google Colab Laboratory и Tensorflow GPU, и это намного быстрее, но все та же ошибка
  3. Я сделал папку с точно таким же именем и путем, но все та же ошибка

Это ошибка, показанная:

Traceback (most recent call last):
  File "training.py", line 179, in <module>
    train_generator, val_generator = get_generators(local_debug=local_debug)
  File "training.py", line 110, in get_generators
    train_generator = get_generator(train_gen_img_path, train_gen_mask_path)
  File "/content/drive/My Drive/app/segmentation-191/util/dataflow.py", line 53, in get_generator
    target_size=(128,128))
  File "/usr/local/lib/python3.6/dist-packages/keras/preprocessing/image.py", line 467, in flow_from_directory
    interpolation=interpolation
  File "/usr/local/lib/python3.6/dist-packages/keras/preprocessing/image.py", line 150, in __init__
    dtype=dtype)
  File "/usr/local/lib/python3.6/dist-packages/keras_preprocessing/image/directory_iterator.py", line 106, in __init__
    for subdir in sorted(os.listdir(directory)):
FileNotFoundError: [Errno 2] No such file or directory: '/coco/images/people-train2017-wrapper'

Это инструкции readme:

### Usage:
Download the model weights (not in Github because of size):   
```python3 download_diamondback_weights.py```   
_-> weights/diamondback\_{...}.h5_   
_-> model/densenet_encoder/encoder_model.h5_   

Run a demo prediction:   
```python3 predict.py --demo --load_path weights/diamondback_{...}.h5```   

Train:   
```python3 training.py [--debug] [--load_path weights/diamondback_{...}.h5]```    

### Notes:
To run certain data scripts, make sure to install (or be in a virtualenv with) the COCO API.   
Some paths (namely ```util/pathutil.py```, shell scripts in ```tmp```) are hardcoded for FloydHub's environment, where data and model weights were expected to be at the drive root ```/```.

Есть ли какой-то код или файлы, которые мне здесь не хватает? Пожалуйста помоги. Спасибо

...