diff --git a/docker/development/Dockerfile.build b/docker/development/Dockerfile.build index 310ec3d51..6f26f1478 100644 --- a/docker/development/Dockerfile.build +++ b/docker/development/Dockerfile.build @@ -12,8 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -# for nnabla>=1.0.17 - ARG BASE FROM ${BASE} @@ -148,6 +146,7 @@ ARG PYTHON_VERSION_MAJOR ARG PYTHON_VERSION_MINOR ENV PYVERNAME=${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} +# Limitation: numpy>=1.17 does not support python2.7 ADD python/requirements.txt /tmp/deps/ RUN umask 0 \ @@ -158,6 +157,7 @@ RUN umask 0 \ && . /opt/miniconda3/bin/activate \ && conda create -n nnabla-build python=${PYVERNAME} \ && conda activate nnabla-build \ + && pip install numpy\<1.17 \ && pip install --only-binary -U -r /tmp/deps/requirements.txt \ && conda clean -y --all \ && cd / \ diff --git a/docker/development/Dockerfile.build-multi-gpu b/docker/development/Dockerfile.build-multi-gpu index b257ccffe..5500fe26b 100644 --- a/docker/development/Dockerfile.build-multi-gpu +++ b/docker/development/Dockerfile.build-multi-gpu @@ -12,8 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -# for nnabla>=1.0.17 - ARG BASE FROM ${BASE} @@ -78,6 +76,7 @@ ARG PYTHON_VERSION_MAJOR ARG PYTHON_VERSION_MINOR ENV PYVERNAME=${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} +# Limitation: numpy>=1.17 does not support python2.7 ADD python/requirements.txt /tmp/deps/ RUN umask 0 \ @@ -88,6 +87,7 @@ RUN umask 0 \ && . /opt/miniconda3/bin/activate \ && conda create -n nnabla-build python=${PYVERNAME} \ && conda activate nnabla-build \ + && pip install numpy\<1.17 \ && pip install --only-binary -U -r /tmp/deps/requirements.txt \ && conda clean -y --all \ && cd / \ diff --git a/docker/development/Dockerfile.build-multi-gpu-ppc64le b/docker/development/Dockerfile.build-multi-gpu-ppc64le index 9ecdfd756..d2a6c4bbc 100644 --- a/docker/development/Dockerfile.build-multi-gpu-ppc64le +++ b/docker/development/Dockerfile.build-multi-gpu-ppc64le @@ -12,8 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -# for nnabla>=1.0.17 - ARG BASE FROM ${BASE} @@ -82,6 +80,8 @@ RUN mkdir /tmp/deps \ ARG PYTHON_VERSION_MAJOR ARG PYTHON_VERSION_MINOR ENV PYVERNAME=${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} + +# Limitation: numpy>=1.17 does not support python2.7 ADD python/requirements.txt /tmp/deps/ RUN umask 0 \ @@ -94,7 +94,7 @@ RUN umask 0 \ && conda activate nnabla-build \ && conda update --all -y \ && pip install -U pip wheel mako pyyaml \ - && pip install -U numpy \ + && pip install -U numpy\<1.17 \ && pip install -U -r /tmp/deps/requirements.txt \ && conda clean -y --all \ && cd / \ diff --git a/docker/development/Dockerfile.build-ppc64le b/docker/development/Dockerfile.build-ppc64le index 9f0797db6..78ce0b74c 100644 --- a/docker/development/Dockerfile.build-ppc64le +++ b/docker/development/Dockerfile.build-ppc64le @@ -12,8 +12,6 @@ # See the License for the specific language governing permissions and # limitations under the License. -# for nnabla>=1.0.17 - ARG BASE FROM ${BASE} @@ -118,6 +116,7 @@ ARG PYTHON_VERSION_MAJOR ARG PYTHON_VERSION_MINOR ENV PYVERNAME=${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR} +# Limitation: numpy>=1.17 does not support python2.7 ADD python/requirements.txt /tmp/deps/ RUN umask 0 \ @@ -132,7 +131,7 @@ RUN umask 0 \ && conda update --all -y \ && pip install -U pip wheel mako pyyaml \ && pip install -U cython \ - && pip install -U numpy \ + && pip install -U numpy\<1.17 \ && pip install -U -r /tmp/deps/requirements.txt \ && conda clean -y --all \ && cd / \ diff --git a/python/requirements.txt b/python/requirements.txt index 59c0f19f3..51ef424a0 100644 --- a/python/requirements.txt +++ b/python/requirements.txt @@ -8,8 +8,8 @@ PyYAML Cython boto3 h5py -numpy>=1.16 -onnx==1.4.1 +numpy>=1.16,<1.17 +onnx protobuf requests tqdm diff --git a/python/setup.py b/python/setup.py index 1bf5b6fae..851e32d92 100644 --- a/python/setup.py +++ b/python/setup.py @@ -46,7 +46,7 @@ assert(__email__ is not None) setup_requires = [ - 'numpy>=1.16', + 'numpy>=1.16,<1.17', 'Cython', # Requires python-dev. ]