forked from chainer/chainerrl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
58 lines (58 loc) · 1.63 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
language: python
dist: xenial
cache: pip
python:
- "2.7"
- "3.6"
env:
- CHAINER_VERSION=4
- CHAINER_VERSION=stable
services:
- xvfb
before_install:
- sudo add-apt-repository -y ppa:jonathonf/ffmpeg-4
- sudo apt-get update
- sudo apt install -y freeglut3-dev ffmpeg
# command to install dependencies
install:
- pip install --upgrade pip setuptools wheel
- |
if [[ $CHAINER_VERSION == 4 ]]; then
pip install "chainer==4.0.0"
else
pip install chainer
fi
- pip install pytest-cov
- pip install -r requirements.txt --only-binary=numpy,scipy
- pip install jupyter
# gym 0.11.0 causes an error with Python 2
# gym 0.13 requires atari_py 0.2, which is not available in Python 2
# atari_py==0.1.4 causes an error
- if [[ $TRAVIS_PYTHON_VERSION == 2.7 ]]; then
pip install gym==0.9.7;
pip install atari_py==0.1.7;
else
pip install gym==0.13.0;
pip install atari_py==0.2.0;
fi
- pip install autopep8
- pip install flake8
- pip install coveralls
- pip install opencv-python
- pip install pybullet
- python setup.py develop
- python -c "import numpy; numpy.show_config()"
# command to run tests
script:
- flake8 chainerrl
- flake8 tests
- flake8 examples
- autopep8 -r chainerrl tests examples --diff | tee check_autopep8
- test ! -s check_autopep8
- pytest -m "not gpu and not slow" -x tests --cov=chainerrl
- ./test_examples.sh -1
- if [[ $TRAVIS_PYTHON_VERSION == 3.6 && $CHAINER_VERSION == stable ]]; then
jupyter nbconvert --to notebook --execute examples/quickstart/quickstart.ipynb --ExecutePreprocessor.timeout=600;
fi
after_success:
- coveralls