Skip to content

Commit

Permalink
Merge pull request #23 from univieCUBE/pytorchnightly
Browse files Browse the repository at this point in the history
FIX Travis/Linux/AVX512 errors from PyTorch/MKLDNN
  • Loading branch information
LokiLuciferase committed Apr 22, 2020
2 parents 204f8b1 + 386fca7 commit ac4df98
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 7 deletions.
10 changes: 6 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,16 @@ jobs:
python: '3.8'
# See https://blog.travis-ci.com/2019-08-07-extensive-python-testing-on-travis-ci
# for macos config peculiarities.
- name: Python 3.7 on MacOS X (xcode 10.3)
- name: Python 3.7 on MacOS X (xcode 10.2)
os: osx
language: shell
osx_image: xcode10.3 # Python 3.7
- name: Python 3.7 on MacOS X (xcode 11.3)
osx_image: xcode10.2
python: '3.7'
- name: Python 3.8 on MacOS X (xcode 11.3)
os: osx
language: shell
osx_image: xcode11.3 # Python 3.7.5
osx_image: xcode11.3
python: '3.8'

env:
global:
Expand Down
2 changes: 1 addition & 1 deletion requirements/win.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
torch>=1.2.0+cpu
torch==1.5.0+cpu
20 changes: 18 additions & 2 deletions travis/install-pip.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,23 @@

set -e

echo "pip installing required python packages"
pip install -r requirements/dev.txt
# Alternative to "conda init bash"
source "$HOME/miniconda/etc/profile.d/conda.sh"

conda activate test
hash -r

# Work-around for a bug in PyTorch/MKLDNN on Linux and AVX512 systems:
# Fetch the pytorch-nightly, until the official release.
if [[ "$TRAVIS_OS_NAME" == 'linux' ]]; then
echo "install and upgrade PyTorch nightly"
conda install --yes pytorch cpuonly -c pytorch-nightly
echo "pip installing required python packages"
pip install -r requirements/dev.txt
python -c "import torch; print(f'PyTorch version = {torch.__version__}')"
elif [[ "$TRAVIS_OS_NAME" == 'osx' ]]; then
echo "pip installing required python packages"
pip install -r requirements/dev.txt
fi

python --version

0 comments on commit ac4df98

Please sign in to comment.