variables: PYTORCH_IMAGE: registry.sensetime.com/eig-research/pytorch:1.3.1-cuda10.1-cudnn7-devel stages: - linting - test before_script: - echo $PATH - gcc --version - nvcc --version - python --version - pip --version - python -c "import torch; print(torch.__version__)" .linting_template: &linting_template_def stage: linting script: - pip install flake8 yapf isort - flake8 . - isort -rc --check-only --diff mmdet3d/ tools/ tests/ - yapf -r -d mmdet3d/ tools/ tests/ configs/ .test_template: &test_template_def stage: test script: - echo "Start building..." - pip install "git+https://github.com/cocodataset/cocoapi.git#subdirectory=PythonAPI" - pip install git+https://github.com/open-mmlab/mmdetection.git - python -c "import mmdet; print(mmdet.__version__)" - pip install -v -e .[all] - python -c "import mmdet3d; print(mmdet3d.__version__)" - echo "Start testing..." - coverage run --branch --source mmdet3d -m pytest tests/ - coverage report -m linting:pytorch1.3-cuda10: image: $PYTORCH_IMAGE <<: *linting_template_def test:pytorch1.3-cuda10: image: $PYTORCH_IMAGE <<: *test_template_def