[Enhancement] Add win-ci (#1296)
* [Enhancement] Add win-ci * add timm in win unittest * remove mmflow with mmseg in win unittest * remove opencv-python in requirements * add opencv2 back * move opencv installation into build.ymlpull/1801/head
parent
ff25d2ff0e
commit
bcd0c89ebb
|
@ -214,3 +214,39 @@ jobs:
|
||||||
env_vars: OS,PYTHON
|
env_vars: OS,PYTHON
|
||||||
name: codecov-umbrella
|
name: codecov-umbrella
|
||||||
fail_ci_if_error: false
|
fail_ci_if_error: false
|
||||||
|
|
||||||
|
test_windows:
|
||||||
|
runs-on: ${{ matrix.os }}
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
os: [windows-2022]
|
||||||
|
python: [3.8]
|
||||||
|
platform: [cpu, cu111]
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Set up Python ${{ matrix.python }}
|
||||||
|
uses: actions/setup-python@v2
|
||||||
|
with:
|
||||||
|
python-version: ${{ matrix.python }}
|
||||||
|
- name: Upgrade pip
|
||||||
|
run: pip install pip --upgrade --user
|
||||||
|
- name: Install OpenCV
|
||||||
|
run: pip install opencv-python>=3
|
||||||
|
- name: Install PyTorch
|
||||||
|
# As a complement to Linux CI, we test on PyTorch LTS version
|
||||||
|
run: pip install torch==1.8.2+${{ matrix.platform }} torchvision==0.9.2+${{ matrix.platform }} -f https://download.pytorch.org/whl/lts/1.8/torch_lts.html
|
||||||
|
- name: Install MMCV
|
||||||
|
run: |
|
||||||
|
pip install mmcv-full -f https://download.openmmlab.com/mmcv/dist/cpu/torch1.8/index.html --only-binary mmcv-full
|
||||||
|
- name: Install unittest dependencies
|
||||||
|
run: pip install -r requirements/tests.txt -r requirements/optional.txt
|
||||||
|
- name: Build and install
|
||||||
|
run: pip install -e .
|
||||||
|
- name: Run unittests
|
||||||
|
run: |
|
||||||
|
python -m pip install timm
|
||||||
|
coverage run --branch --source mmseg -m pytest tests/
|
||||||
|
- name: Generate coverage report
|
||||||
|
run: |
|
||||||
|
coverage xml
|
||||||
|
coverage report -m
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
codecov
|
codecov
|
||||||
flake8
|
flake8
|
||||||
interrogate
|
interrogate
|
||||||
isort==4.3.21
|
|
||||||
pytest
|
pytest
|
||||||
xdoctest>=0.10.0
|
xdoctest>=0.10.0
|
||||||
yapf
|
yapf
|
||||||
|
|
Loading…
Reference in New Issue