run_test.sh 507 Bytes
Newer Older
1
2
3
4
5
6
7
#!/usr/bin/env bash

set -e

eval "$(./conda/bin/conda shell.bash hook)"
conda activate ./env

8
export PYTORCH_TEST_WITH_SLOW='1'
9
10
11
12
13
14
15
if [ "${CU_VERSION:-}" == cpu ] ; then
    NUMPROCESSES="auto"
    export OMP_NUM_THREADS="1"
else
    NUMPROCESSES="1"
fi

16
python -m torch.utils.collect_env
17
18
19
20
21
22
23
24
25
pytest \
    --numprocesses=$NUMPROCESSES \
    --timeout=300 \
    --cov=torchvision \
    --junitxml=test-results/junit.xml \
    --verbose \
    --durations 20 \
    --ignore=test/test_datasets_download.py \
    test