Comments (13)
from caffe-feedstock.
Good catch @183amir .
So we install the executable Python scripts in the conda environment. This way you can run them wherever you need to.
That being said, if you still need those importable scripts, maybe just rename the directory to caffe_python
or something else so as not to conflict. Then you should be able to import them.
from caffe-feedstock.
Yeah, it looks like the from ._caffe import ...
is getting you in trouble as that is a shared object that is only in the built package of caffe
. You might be able to do something really hacky and add a symlink to where it is in site-packages
. I don't really recommend it, but Caffe's Python packaging is suboptimal. So it may be an acceptable short-term solution.
In any event, thanks for raising this. It reminded me to bump issue ( BVLC/caffe#4170 ) again.
from caffe-feedstock.
Thanks for the bug report. Unable to reproduce this on the CentOS 6 docker image currently. Could you please provide some more info about your system like what version of Linux Mint and glibc version?
from caffe-feedstock.
I am probably being dim but don't I need to be in that folder to run those python scripts for the neural network?
from caffe-feedstock.
Nope! [Trying to run this: https://github.com/xiaolonw/caffe-video_triplet in case that is useful information.]
olivia@Love11 ~/GitHub/caffe-video_triplet/caffe_python $ source activate CAFFE
(CAFFE) olivia@Love11 ~/GitHub/caffe-video_triplet/caffe_python $ python -c 'import caffe; print(caffe.__version__)'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "caffe/__init__.py", line 1, in <module>
from .pycaffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, RMSPropSolver, AdaDeltaSolver, AdamSolver
File "caffe/pycaffe.py", line 13, in <module>
from ._caffe import Net, SGDSolver, NesterovSolver, AdaGradSolver, \
ImportError: No module named _caffe
from caffe-feedstock.
Aha! Ignore above - was definitely being way way too under-caffeinated. Solved because of your advice! Thanks!
from caffe-feedstock.
@oliviaguest I am closing this since looks like your problem is solved and it's not related to this feedstock anyway.
from caffe-feedstock.
I didn't have a line with that though. For what it's worth all I have was "import caffe" nothing with an underscore. Ideally I'd like to be able install caffe without a virtual environment, but have not managed it so far. I would like to use my Titan X too.
from caffe-feedstock.
It appears in your traceback.
In any event, I think this reduces down to what @183amir has already said. One can't have another caffe
importable on the path.
from caffe-feedstock.
@jakirkham The traceback is a result of running the following as you can see from above too: python -c 'import caffe; print(caffe.__version__)'
Nothing in that line contains caffe with an underscore. Am I missing something?
from caffe-feedstock.
What are the contents of your current directory?
from caffe-feedstock.
The problem is fixed because I was within the caffe directory. So now when I start the virtual environment it works.
from caffe-feedstock.
Related Issues (16)
- Caffe depends on Opencv 2 while 3 is out HOT 1
- GPU branch HOT 7
- caffe fails to import with gflags 2.2.0 package HOT 3
- Windows support HOT 1
- Install issues HOT 19
- Undefined symbol in convert_imageset HOT 27
- python 3 builds HOT 9
- @conda-forge-admin, please update circle HOT 7
- binary is linked to opencv 3.3 HOT 2
- Latest build not linked properly to leveldb HOT 6
- ImportError: libprotobuf.so.21: cannot open shared object file: No such file or directory HOT 17
- Broken packages HOT 2
- @conda-forge-admin, please re-render HOT 1
- BLAS selection fixes HOT 1
- Archive this feedstock HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from caffe-feedstock.