config.yml 3.26 KB
Newer Older
Julien Chaumond's avatar
Julien Chaumond committed
1
2
version: 2
jobs:
3
    build_py3_torch_and_tf:
4
        working_directory: ~/transformers
5
6
7
8
9
10
11
        docker:
            - image: circleci/python:3.5
        resource_class: xlarge
        parallelism: 1
        steps:
            - checkout
            - run: sudo pip install torch
12
            - run: sudo pip install tensorflow
13
14
15
            - run: sudo pip install --progress-bar off .
            - run: sudo pip install pytest codecov pytest-cov
            - run: sudo pip install tensorboardX scikit-learn
16
            - run: python -m pytest -sv ./transformers/tests/ --cov
17
            - run: codecov
thomwolf's avatar
thomwolf committed
18
    build_py3_torch:
19
        working_directory: ~/transformers
Julien Chaumond's avatar
Julien Chaumond committed
20
        docker:
21
            - image: circleci/python:3.5
22
        resource_class: xlarge
23
        parallelism: 1
Julien Chaumond's avatar
Julien Chaumond committed
24
25
        steps:
            - checkout
thomwolf's avatar
thomwolf committed
26
            - run: sudo pip install torch
Julien Chaumond's avatar
Julien Chaumond committed
27
            - run: sudo pip install --progress-bar off .
thomwolf's avatar
thomwolf committed
28
            - run: sudo pip install pytest codecov pytest-cov
thomwolf's avatar
thomwolf committed
29
            - run: sudo pip install tensorboardX scikit-learn
30
            - run: python -m pytest -sv ./transformers/tests/ --cov
thomwolf's avatar
thomwolf committed
31
32
33
            - run: python -m pytest -sv ./examples/
            - run: codecov
    build_py3_tf:
34
        working_directory: ~/transformers
thomwolf's avatar
thomwolf committed
35
36
37
38
39
40
        docker:
            - image: circleci/python:3.5
        resource_class: xlarge
        parallelism: 1
        steps:
            - checkout
41
            - run: sudo pip install tensorflow
thomwolf's avatar
thomwolf committed
42
            - run: sudo pip install --progress-bar off .
thomwolf's avatar
thomwolf committed
43
            - run: sudo pip install pytest codecov pytest-cov
thomwolf's avatar
thomwolf committed
44
            - run: sudo pip install tensorboardX scikit-learn
45
            - run: python -m pytest -sv ./transformers/tests/ --cov
thomwolf's avatar
thomwolf committed
46
            - run: codecov
47
48
49
50
51
52
53
54
55
    build_py3_custom_tokenizers:
        working_directory: ~/transformers
        docker:
            - image: circleci/python:3.5
        steps:
            - checkout
            - run: sudo pip install --progress-bar off .
            - run: sudo pip install pytest
            - run: sudo pip install mecab-python3
Julien Chaumond's avatar
Julien Chaumond committed
56
            - run: RUN_CUSTOM_TOKENIZERS=1 python -m pytest -sv ./transformers/tests/tokenization_bert_japanese_test.py
LysandreJik's avatar
LysandreJik committed
57
    deploy_doc:
58
        working_directory: ~/transformers
LysandreJik's avatar
LysandreJik committed
59
60
61
62
63
64
65
        docker:
            - image: circleci/python:3.5
        steps:
            - add_ssh_keys:
                  fingerprints:
                      - "5b:7a:95:18:07:8c:aa:76:4c:60:35:88:ad:60:56:71"
            - checkout
66
67
            - run: sudo pip install --progress-bar off -r docs/requirements.txt
            - run: sudo pip install --progress-bar off -r requirements.txt
Lysandre's avatar
Lysandre committed
68
            - run: ./.circleci/deploy.sh
R茅mi Louf's avatar
R茅mi Louf committed
69
70
71
72
73
74
75
76
77
78
    repository_consistency:
        working_directory: ~/transformers
        docker:
            - image: circleci/python:3.5
        resource_class: small
        parallelism: 1
        steps:
            - checkout
            - run: sudo pip install requests
            - run: python ./utils/link_tester.py
LysandreJik's avatar
LysandreJik committed
79
80
81
82
workflow_filters: &workflow_filters
    filters:
        branches:
            only:
Lysandre's avatar
Lysandre committed
83
                - master
84
workflows:
LysandreJik's avatar
LysandreJik committed
85
86
87
    version: 2
    build_and_test:
        jobs:
R茅mi Louf's avatar
R茅mi Louf committed
88
            - repository_consistency
Julien Chaumond's avatar
Julien Chaumond committed
89
            - build_py3_custom_tokenizers
thomwolf's avatar
thomwolf committed
90
            - build_py3_torch_and_tf
thomwolf's avatar
thomwolf committed
91
92
            - build_py3_torch
            - build_py3_tf
Lysandre's avatar
Lysandre committed
93
            - deploy_doc: *workflow_filters