1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- version: 2.1
- jobs:
- build_cu102:
- machine:
- image: ubuntu-2004-cuda-11.4:202110-01
- docker_layer_caching: true
- resource_class: gpu.nvidia.small
- steps:
- - checkout
- - run:
- name: Configure Python
- command: |
- pyenv install 3.8.0
- pyenv global 3.8.0
- - run:
- name: Upgrade setuptools and pip
- command: python -m pip install --upgrade setuptools pip
- - run:
- name: Install PyTorch
- command: python -m pip install torch==1.8.1+cu111 torchvision==0.9.1+cu111 -f https://download.pytorch.org/whl/torch_stable.html
- - run:
- name: Build and install
- command: |
- rm -rf .eggs
- python setup.py check -m -s
- python -m pip install -e .
- - run:
- name: Install dependencies for unit tests
- command: |
- python -m pip install -r requirements/tests.txt
- - run:
- name: Run unittests and generate coverage report
- command: |
- python -m coverage run --branch --source mim -m pytest tests/
- python -m coverage xml
- python -m coverage report -m
- workflows:
- unit_tests:
- jobs:
- - hold:
- type: approval
- - build_cu102:
- requires:
- - hold
|