Skip to content
This repository has been archived by the owner on Oct 18, 2019. It is now read-only.

Build error #68

Closed
ghost opened this issue May 13, 2018 · 3 comments
Closed

Build error #68

ghost opened this issue May 13, 2018 · 3 comments

Comments

@ghost
Copy link

ghost commented May 13, 2018

I got a build error (using the new URL from #51)

docker build -t caffe:cpu https://raw.githubusercontent.com/BVLC/caffe/master/docker/cpu/Dockerfile

Downloading build context from remote url: https://raw.githubusercontent.com/BVLC/caffe/master/docker/cpu/Dockerfile  1.349kB
Sending build context to Docker daemon  3.072kB
Step 1/12 : FROM ubuntu:16.04
 ---> 0b1edfbffd27
Step 2/12 : LABEL maintainer [email protected]
 ---> Using cache
 ---> d8b42b3a353c
Step 3/12 : RUN apt-get update && apt-get install -y --no-install-recommends         build-essential         cmake         git         wget         libatlas-base-dev         libboost-all-dev         libgflags-dev         libgoogle-glog-dev         libhdf5-serial-dev         libleveldb-dev         liblmdb-dev         libopencv-dev         libprotobuf-dev         libsnappy-dev         protobuf-compiler         python-dev         python-numpy         python-pip         python-setuptools         python-scipy &&     rm -rf /var/lib/apt/lists/*
 ---> Using cache
 ---> 2fb926bad41f
Step 4/12 : ENV CAFFE_ROOT=/opt/caffe
 ---> Using cache
 ---> 7538610c87fa
Step 5/12 : WORKDIR $CAFFE_ROOT
 ---> Using cache
 ---> 46d10669c5cf
Step 6/12 : ENV CLONE_TAG=1.0
 ---> Using cache
 ---> 302ad52eb00c
Step 7/12 : RUN git clone -b ${CLONE_TAG} --depth 1 https://github.com/BVLC/caffe.git . &&     pip install --upgrade pip &&     cd python && for req in $(cat requirements.txt) pydot; do pip install $req; done && cd .. &&     mkdir build && cd build &&     cmake -DCPU_ONLY=1 .. &&     make -j"$(nproc)"
 ---> Running in 4ed26361a7c6
Cloning into '.'...
Note: checking out 'eeebdab16155d34ff8f5f42137da7df4d1c7eab0'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

Collecting pip
  Downloading https://files.pythonhosted.org/packages/0f/74/ecd13431bcc456ed390b44c8a6e917c1820365cbebcb6a8974d1cd045ab4/pip-10.0.1-py2.py3-none-any.whl (1.3MB)
Installing collected packages: pip
  Found existing installation: pip 8.1.1
    Not uninstalling pip at /usr/lib/python2.7/dist-packages, outside environment /usr
Successfully installed pip-10.0.1
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
Traceback (most recent call last):
  File "/usr/bin/pip", line 9, in <module>
    from pip import main
ImportError: cannot import name main
The command '/bin/sh -c git clone -b ${CLONE_TAG} --depth 1 https://github.com/BVLC/caffe.git . &&     pip install --upgrade pip &&     cd python && for req in $(cat requirements.txt) pydot; do pip install $req; done && cd .. &&     mkdir build && cd build &&     cmake -DCPU_ONLY=1 .. &&     make -j"$(nproc)"' returned a non-zero code: 1
@ghost
Copy link
Author

ghost commented May 14, 2018

The issue is that their build script updates pip. Here's a script their exact same build but without the pip upgrade: https://gist.githubusercontent.com/brentadamson/aaffaf064e1388c07ff38ff7185e9648/raw/aa020adbe006792bc0318da1f20db822a69aba72/caffe

My full instructions for getting this going is here: https://gist.github.com/brentadamson/4e2435bd2970488047e06163e8642dbc

@ghost ghost closed this as completed May 14, 2018
@shafferjohn
Copy link

The issue is that their build script updates pip. Here's a script their exact same build but without the pip upgrade: https://gist.githubusercontent.com/brentadamson/aaffaf064e1388c07ff38ff7185e9648/raw/aa020adbe006792bc0318da1f20db822a69aba72/caffe

My full instructions for getting this going is here: https://gist.github.com/brentadamson/4e2435bd2970488047e06163e8642dbc

the second url are already 404. Could please repost the latest one?

@ghost
Copy link
Author

ghost commented Dec 1, 2018

Oh, sorry about that. I have since moved everything to Docker. I didn't want to cause any confusion on builds so I deleted the individual build scripts. This should work. Please follow up if you can't get it going:

https://github.com/jivesearch/jivesearch/blob/master/docker/nsfw/Dockerfile

This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant