davidtvs / PyTorch-ENet

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

How to get the test results of cityscapes dataset? #11

Closed MrLinNing closed 5 years ago

MrLinNing commented 5 years ago

I have trained the cityscapes dataset using the following, and the Mean IoU is valid dataset.

python main.py -m train --save-dir save/folder/ --name model_name --dataset name --dataset-dir path/root_directory/

Then I want to get the test results of cityscapes dataset, and I run the Testing code but find problem.

python main.py -m test --save-dir save/folder/ --name model_name --dataset name --dataset-dir path/root_directory/

THCudaCheck FAIL file=/pytorch/torch/lib/THC/generic/THCStorage.cu line=58 error=2 : out of memory
*** Error in `python': free(): invalid pointer: 0x00007fbf14a51d40 ***
======= Backtrace: =========
/lib/x86_64-linux-gnu/libc.so.6(+0x777e5)[0x7fbf92c6b7e5]
...

can you help me ? thank you @davidtvs

davidtvs commented 5 years ago

You can't test cityscapes, the test dataset is not public. You might have a test folder but all images are black.

About the error: never seen that error, but the message says that your computer is out-of-memory. And a quick google pointed me here https://github.com/pytorch/pytorch/issues/958. So I would lower the batch size in situations like this