From feab66b190d0c035036f19ec91e5197cb8b1bf83 Mon Sep 17 00:00:00 2001 From: Niels Rogge Date: Thu, 5 Aug 2021 10:14:33 +0200 Subject: [PATCH] Add detectron2 CI job --- .circleci/config.yml | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index ec29b0fb74a00..21a04f03aac4f 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -524,6 +524,41 @@ jobs: - run: pip install requests - run: python ./utils/link_tester.py + run_tests_detectron2: + working_directory: ~/transformers + docker: + - image: circleci/python:3.7 + environment: + OMP_NUM_THREADS: 1 + TRANSFORMERS_IS_CI: yes + resource_class: xlarge + parallelism: 1 + steps: + - checkout + - restore_cache: + keys: + - v0.4-torch-{{ checksum "setup.py" }} + - v0.4-{{ checksum "setup.py" }} + - run: sudo apt-get -y update && sudo apt-get install -y libsndfile1-dev + - run: pip install --upgrade pip + - run: pip install .[sklearn,torch,testing,sentencepiece,speech,vision,timm] + - run: python -m pip install 'git+https://github.com/facebookresearch/detectron2.git' + - save_cache: + key: v0.4-torch-{{ checksum "setup.py" }} + paths: + - '~/.cache/pip' + - run: python utils/tests_fetcher.py | tee test_preparation.txt + - store_artifacts: + path: ~/transformers/test_preparation.txt + - run: | + if [ -f test_list.txt ]; then + python -m pytest -n 3 --dist=loadfile -s --make-reports=tests_torch $(cat test_list.txt) | tee tests_output.txt + fi + - store_artifacts: + path: ~/transformers/tests_output.txt + - store_artifacts: + path: ~/transformers/reports + # TPU JOBS run_examples_tpu: docker: