Skip to content

Commit

Permalink
--upgrade
Browse files Browse the repository at this point in the history
  • Loading branch information
carmocca committed Jun 2, 2022
1 parent 84e3562 commit c2435ee
Show file tree
Hide file tree
Showing 20 changed files with 40 additions and 41 deletions.
4 changes: 2 additions & 2 deletions .azure-pipelines/gpu-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,8 @@ jobs:
python -c "fname = 'requirements/strategies.txt' ; lines = [line for line in open(fname).readlines() if 'horovod' not in line] ; open(fname, 'w').writelines(lines)"
CUDA_VERSION_MM=$(python -c "import torch ; print(''.join(map(str, torch.version.cuda.split('.')[:2])))")
pip install "bagua-cuda$CUDA_VERSION_MM>=0.9.0"
pip install . --requirement requirements/devel.txt --upgrade-strategy eager
pip install . --requirement requirements/strategies.txt --upgrade-strategy eager
pip install . --requirement requirements/devel.txt -U --upgrade-strategy eager
pip install . --requirement requirements/strategies.txt -U --upgrade-strategy eager
pip list
displayName: 'Install dependencies'
Expand Down
4 changes: 2 additions & 2 deletions .azure-pipelines/hpu-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ jobs:
displayName: 'Instance HW info'
- bash: |
pip install . --requirement requirements/extra.txt --upgrade-strategy eager
pip install . --requirement requirements/test.txt --upgrade-strategy eager
pip install . --requirement requirements/extra.txt -U --upgrade-strategy eager
pip install . --requirement requirements/test.txt -U --upgrade-strategy eager
displayName: 'Install dependencies'
- bash: |
Expand Down
2 changes: 1 addition & 1 deletion .azure-pipelines/ipu-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ jobs:
export GIT_TERMINAL_PROMPT=1
python ./requirements/adjust-versions.py requirements/extra.txt
python ./requirements/adjust-versions.py requirements/examples.txt
pip install . --requirement ./requirements/devel.txt --upgrade-strategy eager
pip install . --requirement ./requirements/devel.txt -U --upgrade-strategy eager
pip list
displayName: 'Install dependencies'
Expand Down
2 changes: 1 addition & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ references:
# the image uses python 2.7 by default, force a different version
pyenv global 3.7.3
python --version
pip install -r requirements/docs.txt --upgrade-strategy eager
pip install -r requirements/docs.txt -U --upgrade-strategy eager
pip list
cd docs
make clean
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/ci_pkg-install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
if: runner.os == 'windows'
run: |
# this is just a hotfix because of Win cannot install it directly
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --upgrade-strategy eager
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html -U --upgrade-strategy eager
- name: Install | Uninstall package - archive
run: |
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci_test-base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ jobs:
python --version
python -m pip install --upgrade --user pip
pip --version
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --upgrade --upgrade-strategy eager
pip install -r requirements/test.txt --upgrade-strategy eager
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html -U --upgrade-strategy eager
pip install -r requirements/test.txt -U --upgrade-strategy eager
pip list
shell: bash

Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci_test-conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ jobs:
# adjust versions according installed Torch version
python ./requirements/adjust-versions.py requirements/extra.txt
python ./requirements/adjust-versions.py requirements/examples.txt
pip install -r requirements/devel.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --upgrade-strategy eager
pip install -r requirements/strategies.txt --upgrade-strategy eager
pip install -r requirements/devel.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html -U --upgrade-strategy eager
pip install -r requirements/strategies.txt -U --upgrade-strategy eager
# set a per-test timeout of 2.5 minutes to fail sooner; this aids with hanging tests
pip install pytest-timeout
pip list
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/ci_test-full.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,19 +89,19 @@ jobs:
run: |
flag=$(python -c "print('--pre' if '${{matrix.release}}' == 'pre' else '')" 2>&1)
url=$(python -c "print('test/cpu/torch_test.html' if '${{matrix.release}}' == 'pre' else 'cpu/torch_stable.html')" 2>&1)
pip install -r requirements.txt --upgrade $flag --upgrade-strategy eager --find-links "https://download.pytorch.org/whl/${url}"
pip install -r requirements.txt $flag -U --upgrade-strategy eager --find-links "https://download.pytorch.org/whl/${url}"
# adjust versions according installed Torch version
python ./requirements/adjust-versions.py requirements/examples.txt
pip install -r requirements/examples.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --upgrade --upgrade-strategy eager
pip install -r requirements/test.txt --upgrade --upgrade-strategy eager
pip install -r requirements/examples.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html -U --upgrade-strategy eager
pip install -r requirements/test.txt -U --upgrade-strategy eager
pip list
shell: bash

- name: Install extra dependencies
run: |
# adjust versions according installed Torch version
python ./requirements/adjust-versions.py requirements/extra.txt
pip install --requirement ./requirements/extra.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --upgrade --upgrade-strategy eager
pip install --requirement ./requirements/extra.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html -U --upgrade-strategy eager
pip list
shell: bash

Expand All @@ -116,7 +116,7 @@ jobs:
if [[ $HOROVOD_BUILT != "SUCCESS" ]]; then
pip uninstall -y horovod
grep "horovod" requirements/strategies.txt > requirements/horovod.txt
pip install --no-cache-dir -r requirements/horovod.txt --upgrade-strategy eager
pip install --no-cache-dir -r requirements/horovod.txt -U --upgrade-strategy eager
fi
horovodrun --check-build
python -c "import horovod.torch"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/ci_test-slow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ jobs:
run: |
# adjust versions according installed Torch version
python ./requirements/adjust-versions.py requirements.txt ${{ matrix.pytorch-version }}
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --upgrade --upgrade-strategy eager
pip install -r requirements/test.txt --upgrade-strategy eager
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html -U --upgrade-strategy eager
pip install -r requirements/test.txt -U --upgrade-strategy eager
pip list
shell: bash

Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/code-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
run: |
pip install torch==1.11 --find-links https://download.pytorch.org/whl/cpu/torch_stable.html
python ./requirements/adjust-versions.py requirements/extra.txt
pip install '.[dev]' --upgrade-strategy eager
pip install '.[dev]' -U --upgrade-strategy eager
pip list
- name: Type check
Expand Down
9 changes: 4 additions & 5 deletions .github/workflows/docs-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,9 @@ jobs:
sudo apt-get install -y cmake pandoc
pip --version
pip install -q fire
# python -m pip install --upgrade --user pip
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet --upgrade-strategy eager
pip install -r requirements/devel.txt --upgrade-strategy eager
pip install -r requirements/docs.txt --upgrade-strategy eager
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet -U --upgrade-strategy eager
pip install -r requirements/devel.txt -U --upgrade-strategy eager
pip install -r requirements/docs.txt -U --upgrade-strategy eager
pip list
shell: bash

Expand Down Expand Up @@ -83,7 +82,7 @@ jobs:
sudo apt-get update
sudo apt-get install -y cmake pandoc
pip --version
pip install --requirement requirements/docs.txt --upgrade-strategy eager
pip install --requirement requirements/docs.txt -U --upgrade-strategy eager
# install Texlive, see https://linuxconfig.org/how-to-install-latex-on-ubuntu-20-04-focal-fossa-linux
sudo apt-get update && sudo apt-get install -y texlive-latex-extra dvipng texlive-pictures
pip list
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/legacy-checkpoints.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:

- name: Install dependencies
run: |
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet --upgrade-strategy eager
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet -U --upgrade-strategy eager
pip install awscli
- name: Configure AWS credentials
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-pypi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ jobs:

- name: Install dependencies
run: |
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet --upgrade-strategy eager
pip install -r requirements.txt --find-links https://download.pytorch.org/whl/cpu/torch_stable.html --quiet -U --upgrade-strategy eager
pip install awscli
- name: Configure AWS credentials
Expand Down
8 changes: 4 additions & 4 deletions dockers/base-conda/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,9 @@ RUN \
python requirements/adjust-versions.py requirements/extra.txt && \
python requirements/adjust-versions.py requirements/examples.txt && \
# Install remaining requirements
pip install -r requirements/base.txt --no-cache-dir --find-links https://download.pytorch.org/whl/test/torch_test.html --upgrade-strategy eager && \
pip install -r requirements/extra.txt --no-cache-dir --find-links https://download.pytorch.org/whl/test/torch_test.html --upgrade-strategy eager && \
pip install -r requirements/examples.txt --no-cache-dir --find-links https://download.pytorch.org/whl/test/torch_test.html --upgrade-strategy eager && \
pip install -r requirements/base.txt --no-cache-dir --find-links https://download.pytorch.org/whl/test/torch_test.html-U --upgrade-strategy eager && \
pip install -r requirements/extra.txt --no-cache-dir --find-links https://download.pytorch.org/whl/test/torch_test.html-U --upgrade-strategy eager && \
pip install -r requirements/examples.txt --no-cache-dir --find-links https://download.pytorch.org/whl/test/torch_test.html-U --upgrade-strategy eager && \
rm assistant.py

ENV \
Expand All @@ -117,7 +117,7 @@ ENV \
RUN \
HOROVOD_BUILD_CUDA_CC_LIST=${TORCH_CUDA_ARCH_LIST//";"/","} && \
export HOROVOD_BUILD_CUDA_CC_LIST=${HOROVOD_BUILD_CUDA_CC_LIST//"."/""} && \
pip install --no-cache-dir -r requirements/strategies.txt --upgrade-strategy eager
pip install --no-cache-dir -r requirements/strategies.txt -U --upgrade-strategy eager

RUN \
CUDA_VERSION_MAJOR=$(python -c "import torch ; print(torch.version.cuda.split('.')[0])") && \
Expand Down
4 changes: 2 additions & 2 deletions dockers/base-cuda/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ RUN \
python ./requirements/adjust-versions.py requirements/extra.txt ${PYTORCH_VERSION} && \
python ./requirements/adjust-versions.py requirements/examples.txt ${PYTORCH_VERSION} && \
# Install all requirements \
pip install -r requirements/devel.txt --no-cache-dir --find-links https://download.pytorch.org/whl/cu${CUDA_VERSION_MM}/torch_stable.html --upgrade-strategy eager && \
pip install -r requirements/devel.txt --no-cache-dir --find-links https://download.pytorch.org/whl/cu${CUDA_VERSION_MM}/torch_stable.html -U --upgrade-strategy eager && \
rm assistant.py

RUN \
Expand Down Expand Up @@ -117,7 +117,7 @@ RUN \
export HOROVOD_BUILD_CUDA_CC_LIST=${HOROVOD_BUILD_CUDA_CC_LIST//"."/""} && \
echo $HOROVOD_BUILD_CUDA_CC_LIST && \
cmake --version && \
pip install --no-cache-dir -r ./requirements/strategies.txt --upgrade-strategy eager && \
pip install --no-cache-dir -r ./requirements/strategies.txt -U --upgrade-strategy eager && \
horovodrun --check-build

RUN \
Expand Down
4 changes: 2 additions & 2 deletions dockers/base-ipu/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ RUN \
python adjust_versions.py requirements-extra.txt && \
pip install -q fire && \
# Install remaining requirements
pip install -r requirements-extra.txt --no-cache-dir --upgrade-strategy eager && \
pip install -r requirements-test.txt --no-cache-dir --upgrade-strategy eager && \
pip install -r requirements-extra.txt --no-cache-dir -U --upgrade-strategy eager && \
pip install -r requirements-test.txt --no-cache-dir -U --upgrade-strategy eager && \
rm requirements*

RUN \
Expand Down
2 changes: 1 addition & 1 deletion dockers/base-xla/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ RUN \
# drop unnecessary packages
python ./requirements/adjust-versions.py ./requirements/extra.txt && \
# install PL dependencies
pip install --requirement ./requirements/devel.txt --no-cache-dir --upgrade-strategy eager && \
pip install --requirement ./requirements/devel.txt --no-cache-dir -U --upgrade-strategy eager && \
cd .. && \
rm -rf pytorch-lightning && \
rm -rf /root/.cache
Expand Down
8 changes: 4 additions & 4 deletions dockers/nvidia/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ RUN \
# Installations \
pip install -q fire && \
python ./pytorch-lightning/.actions/assistant.py requirements_prune_pkgs horovod --req_files ./pytorch-lightning/requirements/extra.txt && \
pip install "Pillow>=8.2, !=8.3.0" "cryptography>=3.4" "py>=1.10" "protobuf>=3.15.6" --no-cache-dir --upgrade-strategy eager && \
pip install -r ./pytorch-lightning/requirements/extra.txt --no-cache-dir --upgrade-strategy eager && \
pip install -r ./pytorch-lightning/requirements/examples.txt --no-cache-dir --upgrade-strategy eager && \
pip install ./pytorch-lightning --no-cache-dir --upgrade-strategy eager && \
pip install "Pillow>=8.2, !=8.3.0" "cryptography>=3.4" "py>=1.10" "protobuf>=3.15.6" --no-cache-dir -U --upgrade-strategy eager && \
pip install -r ./pytorch-lightning/requirements/extra.txt --no-cache-dir -U --upgrade-strategy eager && \
pip install -r ./pytorch-lightning/requirements/examples.txt --no-cache-dir -U --upgrade-strategy eager && \
pip install ./pytorch-lightning --no-cache-dir -U --upgrade-strategy eager && \
rm -rf pytorch-lightning && \
pip install jupyterlab[all] -U && \
pip list
Expand Down
2 changes: 1 addition & 1 deletion dockers/release/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ RUN \
mv pytorch-lightning-*/ pytorch-lightning ; \
rm *.zip ; \
fi && \
pip install ./pytorch-lightning["extra"] --no-cache-dir --upgrade-strategy eager && \
pip install ./pytorch-lightning["extra"] --no-cache-dir -U --upgrade-strategy eager && \
rm -rf pytorch-lightning

RUN python --version && \
Expand Down
2 changes: 1 addition & 1 deletion dockers/tpu-tests/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ RUN cd pytorch-lightning && \
RUN \
pip install -q fire && \
# drop unnecessary packages
pip install -r pytorch-lightning/requirements/devel.txt --no-cache-dir --upgrade-strategy eager
pip install -r pytorch-lightning/requirements/devel.txt --no-cache-dir -U --upgrade-strategy eager

COPY ./dockers/tpu-tests/docker-entrypoint.sh /usr/local/bin/
RUN chmod +x /usr/local/bin/docker-entrypoint.sh
Expand Down

0 comments on commit c2435ee

Please sign in to comment.