speedinghzl / Pytorch-Deeplab

DeepLab-ResNet rebuilt in Pytorch
MIT License
263 stars 62 forks source link

Run on non-CUDA device #11

Closed ddhgiang closed 6 years ago

ddhgiang commented 6 years ago

Hi, can I run the code on my laptop where I don't have a GPU that supports CUDA? Can you guide me how to make it work? Cheers.

speedinghzl commented 6 years ago

It's very time-consuming if you train deeplab on CPU. You can try to run testing on CPU by modify evaluate.py (.cuda(gpu0) -> .cpu() ).

ddhgiang commented 6 years ago

Thanks!! But then I couldn't load the pre-trained model where I got the error "No such file or directory: './deeplab_resnet.ckpt'". Can you show me where this file is?

speedinghzl commented 6 years ago

You can find the download link from the README.md. The init model and trained model are given.

ddhgiang commented 6 years ago

Hey sorry but I couldn't find the link to download deeplab_resnet.ckpt but I found one from your reference to the tensorflow-implemented model (https://drive.google.com/drive/folders/0B_rootXHuswsTF90M1NWQmFYelU).

However, when I tried to put it in the folder and ran the code, error still appeared: UnpicklingError: invalid load key, '\x00'.

Is it in the README.md the file 'VOC12_scenes_20000.pth'?

ddhgiang commented 6 years ago

Also, could you explain why your replicated model achieve less accuracy, where you got 74% mIoU instead of 76.4% without CRF as the original paper did?