detectRecog / CCPD

[ECCV 2018] CCPD: a diverse and well-annotated dataset for license plate detection and recognition
MIT License
2.21k stars 564 forks source link

No module named 'torch._thnn' #57

Open niushaoda opened 4 years ago

niushaoda commented 4 years ago

No module named 'torch._thnn'

nicpho commented 4 years ago

I have the same issue.

beibuwandeluori commented 4 years ago

you need to use cuda9.x

Hunandaxueheying commented 4 years ago

I have the same problem, and my cuda version is 9.0.176, have you solved the problem?

Panruihua commented 4 years ago

Sorry, I haven't solved the problem yet.

---Original--- From: "Hunandaxueheying"<notifications@github.com> Date: Tue, Feb 25, 2020 16:47 PM To: "detectRecog/CCPD"<CCPD@noreply.github.com>; Cc: "Subscribed"<subscribed@noreply.github.com>; Subject: Re: [detectRecog/CCPD] No module named 'torch._thnn' (#57)

I have the same problem, and my cuda version is 9.0.176, have you solved the problem?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

Harsha-1729 commented 4 years ago

No module named 'torch._thnn'

I am also getting the same problem. I am using the latest versions of pytorch, numpy, cv2 and CUDA. Is it mandatory to use the specified versions of above mentioned items? did you solve the problem?

Thanks

Harsha-1729 commented 4 years ago

No module named 'torch._thnn'

I am also getting the same problem. I am using the latest versions of pytorch, numpy, cv2 and CUDA. Is it mandatory to use the specified versions of above mentioned items? did you solve the problem?

Thanks

I have solved the problem.

I tried installing pytorch(0.3.1) and run the code on Google Colab. It successfully executed and the results were generated.

Harsha-1729 commented 4 years ago

Sorry, I haven't solved the problem yet. ---Original--- From: "Hunandaxueheying"<notifications@github.com> Date: Tue, Feb 25, 2020 16:47 PM To: "detectRecog/CCPD"<CCPD@noreply.github.com>; Cc: "Subscribed"<subscribed@noreply.github.com>; Subject: Re: [detectRecog/CCPD] No module named 'torch._thnn' (#57) I have the same problem, and my cuda version is 9.0.176, have you solved the problem? — You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.

Following procedure worked for me

I tried installing pytorch(0.3.1) and run the code on Google Colab. It successfully executed and the results were generated.

Harsha-1729 commented 4 years ago

I have the same problem, and my cuda version is 9.0.176, have you solved the problem?

Following procedure worked for me

I tried installing pytorch(0.3.1) and run the code on Google Colab. It successfully executed and the results were generated.

LorenzoLamberti94 commented 4 years ago

same issue here

Harsha-1729 commented 4 years ago

same issue here

I tried installing pytorch(0.3.1) and run the code on Google Colab. It successfully executed and the results were generated.

LorenzoLamberti94 commented 4 years ago

I can't even install pytorch 0.3.1 with pip or conda (not supported anymore). I used pytorch 0.4.1 + cuda 9 and fortunately worked for me

Detailed istructions: conda create --name rpnet python=3.6 conda activate rpnet conda install pytorch=0.4.1 cuda90 -c pytorch conda install opencv pip install imutils

MAR-ZLW commented 3 years ago

the same issue,maybe the OS have not the version(0.3.1),reference(https://pytorch.org/get-started/previous-versions/). only mac OS has 'torch-0.3.1-cp27-none-macosx_10_7_x86_64.whl',

chensonglu commented 3 years ago

@LorenzoLamberti94 thanks, it works. After that, we also need to change "type(input)" to "input.type()" in the line 18 of "roi_pooling.py".

dwchen-tech commented 3 years ago

@LorenzoLamberti94 thanks, it works. After that, we also need to change "type(input)" to "input.type()" in the line 18 of "roi_pooling.py".

thanks for the "roi_pooling.py" patch. My steps: conda create --name rpnet python=3.6 conda activate rpnet conda install opencv pip install imutils pip install torch-0.4.1-cp36-cp36m-linux_x86_64.whl the "roi_pooling.py" patch

Finally, it works well! Thanks for @LorenzoLamberti94 and @chensonglu

StevenVerne commented 3 years ago

requirement: numpy==1.21.0 opencv-python==3.4.2.17 torch==1.9.0 torchaudio==0.9.0 torchvision==0.10.0

CUDA:10.2 CUDNN:7.x

revision should be made accorading to https://github.com/872699467/CCPD_CNN

Solved!