mahyarnajibi / SSH

SSH: Single Stage Headless Face Detector
Other
835 stars 280 forks source link

ImportError: No module named cpu_nms #54

Open graycrown opened 5 years ago

graycrown commented 5 years ago

when I run python demo.py, error occured like : File "demo.py", line 8, in from SSH.test import detect File "/home/fmming/test/tt/SSH-master/SSH/test.py", line 14, in from nms.nms_wrapper import nms File "lib/nms/nms_wrapper.py", line 9, in from nms.cpu_nms import cpu_nms ImportError: No module named cpu_nms, how can I fix it ? Thanks a lot

DenisSouth commented 5 years ago

Use google colab with my jupyter notebook. I forked the project and made able to run it online for everyone. https://github.com/DenisSouth/SSH

rabysam28 commented 4 years ago

@DenisSouth Is that still possible to use your Jupiter? I am trying to run the demo file to see how it works.

DenisSouth commented 4 years ago

@DenisSouth Is that still possible to use your Jupiter? I am trying to run the demo file to see how it works.

I removed my old projects one week ago :(, but I will ask GitHub support and text you if they will restore it

DenisSouth commented 4 years ago

@DenisSouth Is that still possible to use your Jupiter? I am trying to run the demo file to see how it works.

Thanks GitHub support) my repository available now, you can try it :)

rabysam28 commented 4 years ago

@DenisSouth Great. I am excited to try it to see how it works. Do I need to follow any of the SSH page's installation instruction as well or I can just run your Jupiter and it would work on its own? Any prerequisite or requirement needed in my machine before running your Jupiter code? Thnx

DenisSouth commented 4 years ago

n as well or I can just run your Jupiter and it would work on its own? Any prerequisite or requirement needed in my machine b

You may use just my notebook, it will download all necessary files, on a machine with GPU. CUDA and Python 2. perhaps OS ubuntu18 in last year I made this notebook for Google collaboratory but now it does not support Python 2

rabysam28 commented 4 years ago

In the first cell, we do a "git clone" to get the original ssh repo. If I do it next to your repo that I have already clone, then the name of both repo is SHH which would not work. So, in order for me to better explain my question, if I want to do the GIT part in command line without jupyter, is the following correct?

Get your repo by running: git clone https://github.com/DenisSouth/SSH and now I want to get the original SSH repo: my question is which I directory should I navigate first before running the following clone? git clone https://github.com/mahyarnajibi/SSH

Maybe I am totally misunderstanding it...

DenisSouth commented 4 years ago

In the first cell, we do a "git clone" to get the original ssh repo. If I do it next to your repo that I have already clone, then the name of both repo is SHH which would not work. So, in order for me to better explain my question, if I want to do the GIT part in command line without jupyter, is the following correct?

Get your repo by running: git clone https://github.com/DenisSouth/SSH and now I want to get the original SSH repo: my question is which I directory should I navigate first before running the following clone? git clone https://github.com/mahyarnajibi/SSH

Maybe I am totally misunderstanding it...

Just copy my notebook without other files, Directory... On Ubuntu it was /content/ You can try do same things. In the root create content folder, then open cmd in that folder and execute command by command from notebook

DenisSouth commented 4 years ago

And before python commands create virtual environment with python 2.7 64 and activate it

rabysam28 commented 4 years ago

Here is what I have done so far, step by step:

I created a virtual environment with python 2.7 cd / mkdir content cd content inside the content folder, I copy your single jupyter file, named caffe_ssh.ipynb. Therefore inside content folder there is only one file in the beginning. Now I open your jupyter file, and run it cell by cell. However when I get to make all I am getting the following error: PROTOC src/caffe/proto/caffe.proto CXX .build_release/src/caffe/proto/caffe.pb.cc In file included from .build_release/src/caffe/proto/caffe.pb.cc:5:0: .build_release/src/caffe/proto/caffe.pb.h:9:42: fatal error: google/protobuf/stubs/common.h: No such file or directory compilation terminated. Makefile:590: recipe for target '.build_release/src/caffe/proto/caffe.pb.o' failed make: *** [.build_release/src/caffe/proto/caffe.pb.o] Error 1

DenisSouth commented 4 years ago

Here is what I have done so far, step by step:

I created a virtual environment with python 2.7 cd / mkdir content cd content inside the content folder, I copy your single jupyter file, named caffe_ssh.ipynb. Therefore inside content folder there is only one file in the beginning. Now I open your jupyter file, and run it cell by cell. However when I get to make all I am getting the following error: PROTOC src/caffe/proto/caffe.proto CXX .build_release/src/caffe/proto/caffe.pb.cc In file included from .build_release/src/caffe/proto/caffe.pb.cc:5:0: .build_release/src/caffe/proto/caffe.pb.h:9:42: fatal error: google/protobuf/stubs/common.h: No such file or directory compilation terminated. Makefile:590: recipe for target '.build_release/src/caffe/proto/caffe.pb.o' failed make: *** [.build_release/src/caffe/proto/caffe.pb.o] Error 1

Check my repository, I updated it. Now it works with Google Colab and you can run it online

rabysam28 commented 4 years ago

Cool. Your google Colab works! Thanks