-
Notifications
You must be signed in to change notification settings - Fork 11
/
.travis.yml
75 lines (66 loc) · 1.96 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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
# Mostly duplicated from
# https://github.com/pytorch/vision/blob/master/.travis.yml
language: python
sudo: required
dist: xenial
cache:
timeout: 300 # 5 min timeout
pip: true
directories:
- /tmp/cache
matrix:
include:
- env: LINT_CHECK
python: "3.6"
install: pip install flake8 mypy
script:
- flake8
- mypy src/torchvideo
- env: NOTEBOOK_CHECK
python: "3.6"
script:
- pip install jupyter
- './examples/run-notebooks.sh'
- python: "3.6"
# - python: "3.6"
# env: IMAGE_BACKEND=Pillow-SIMD
- python: "3.7"
# - python: "3.7"
# env: IMAGE_BACKEND=Pillow-SIMD
install:
- sudo apt-get update
- wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
- if [[ -d $HOME/miniconda ]]; then
bash miniconda.sh -b -u -p $HOME/miniconda;
else
bash miniconda.sh -b -p $HOME/miniconda;
fi
- export PATH="$HOME/miniconda/bin:$PATH"
- hash -r
- conda config --set always_yes yes --set changeps1 no
- conda update -q conda
# Useful for debugging any issues with conda
- conda info -a
- sed -i "s/python=[0-9\.]\+/python=$TRAVIS_PYTHON_VERSION/g" environment.yml
- cat environment.yml
- conda env create -n torchvideo -f environment.yml
- source activate torchvideo
- pip install codecov
- python setup.py install
- if [[ "$IMAGE_BACKEND" == "Pillow-SIMD" ]]; then
pip uninstall -y pillow && CC="cc -march=native" pip install --force-reinstall pillow-simd;
fi
- if [[ -f /tmp/cache/big_buck_bunny_360p_5mb.mp4 ]]; then
cp /tmp/cache/big_buck_bunny_360p_5mb.mp4 tests/data/media;
fi
- pushd tests/data/media; ./gen_test_media.sh; popd
- if [[ ! -f /tmp/cache/big_buck_bunny_360p_5mb.mp4 ]]; then
mkdir -p /tmp/cache;
cp tests/data/media/big_buck_bunny_360p_5mb.mp4 /tmp/cache;
fi
script:
- make test
after_success:
- coverage combine
- coverage report
- codecov