Unverified Commit 377597b6 authored by Xiang Xu's avatar Xiang Xu Committed by GitHub
Browse files

[Fix] Adjust the minimum supported python version to 3.7 (#2241)

* upgrade python to 3.7

* Update test.yml

* remove
parent bf9488d7
...@@ -130,8 +130,7 @@ workflows: ...@@ -130,8 +130,7 @@ workflows:
- dev-1.x - dev-1.x
pr_stage_test: pr_stage_test:
when: when:
not: not: << pipeline.parameters.lint_only >>
<< pipeline.parameters.lint_only >>
jobs: jobs:
- lint: - lint:
name: lint name: lint
...@@ -167,8 +166,7 @@ workflows: ...@@ -167,8 +166,7 @@ workflows:
- hold - hold
merge_stage_test: merge_stage_test:
when: when:
not: not: << pipeline.parameters.lint_only >>
<< pipeline.parameters.lint_only >>
jobs: jobs:
- build_cuda: - build_cuda:
name: minimum_version_gpu name: minimum_version_gpu
......
...@@ -215,7 +215,7 @@ jobs: ...@@ -215,7 +215,7 @@ jobs:
- name: Build MMCV from source - name: Build MMCV from source
run: pip install -e . -v run: pip install -e . -v
- name: Install unit tests dependencies - name: Install unit tests dependencies
run: pip install -r requirements/test.txt run: pip install -r requirements/tests.txt
- name: Run unittests and generate coverage report - name: Run unittests and generate coverage report
run: | run: |
coverage run --branch --source mmcv -m pytest tests coverage run --branch --source mmcv -m pytest tests
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
In this section we demonstrate how to prepare an environment with PyTorch. In this section we demonstrate how to prepare an environment with PyTorch.
MMDetection3D works on Linux, Windows (experimental support) and macOS and requires the following packages: MMDetection3D works on Linux, Windows (experimental support) and macOS and requires the following packages:
- Python 3.6+ - Python 3.7+
- PyTorch 1.6+ - PyTorch 1.6+
- CUDA 9.2+ (If you build PyTorch from source, CUDA 9.0 is also compatible) - CUDA 9.2+ (If you build PyTorch from source, CUDA 9.0 is also compatible)
- GCC 5+ - GCC 5+
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
在本节中,我们将展示如何使用 PyTorch 准备环境。MMDetection3D 支持在 Linux,Windows(实验性支持),MacOS 上运行,它具体需要下列安装包: 在本节中,我们将展示如何使用 PyTorch 准备环境。MMDetection3D 支持在 Linux,Windows(实验性支持),MacOS 上运行,它具体需要下列安装包:
- Python 3.6+ - Python 3.7+
- PyTorch 1.6+ - PyTorch 1.6+
- CUDA 9.2+(如果您从源码编译 PyTorch,CUDA 9.0 也是兼容的) - CUDA 9.2+(如果您从源码编译 PyTorch,CUDA 9.0 也是兼容的)
- GCC 5+ - GCC 5+
......
# Copyright (c) OpenMMLab. All rights reserved.
import os import os
import platform import platform
import shutil import shutil
...@@ -23,13 +24,7 @@ version_file = 'mmdet3d/version.py' ...@@ -23,13 +24,7 @@ version_file = 'mmdet3d/version.py'
def get_version(): def get_version():
with open(version_file, 'r') as f: with open(version_file, 'r') as f:
exec(compile(f.read(), version_file, 'exec')) exec(compile(f.read(), version_file, 'exec'))
import sys return locals()['__version__']
# return short version for sdist
if 'sdist' in sys.argv or 'bdist_wheel' in sys.argv:
return locals()['short_version']
else:
return locals()['__version__']
def make_cuda_ext(name, def make_cuda_ext(name,
...@@ -163,7 +158,7 @@ def add_mim_extention(): ...@@ -163,7 +158,7 @@ def add_mim_extention():
else: else:
return return
filenames = ['tools', 'configs', 'model-index.yml'] filenames = ['tools', 'configs', 'demo', 'model-index.yml']
repo_path = osp.dirname(__file__) repo_path = osp.dirname(__file__)
mim_path = osp.join(repo_path, 'mmdet3d', '.mim') mim_path = osp.join(repo_path, 'mmdet3d', '.mim')
os.makedirs(mim_path, exist_ok=True) os.makedirs(mim_path, exist_ok=True)
...@@ -205,16 +200,16 @@ if __name__ == '__main__': ...@@ -205,16 +200,16 @@ if __name__ == '__main__':
author_email='zwwdev@gmail.com', author_email='zwwdev@gmail.com',
keywords='computer vision, 3D object detection', keywords='computer vision, 3D object detection',
url='https://github.com/open-mmlab/mmdetection3d', url='https://github.com/open-mmlab/mmdetection3d',
packages=find_packages(), packages=find_packages(exclude=('configs', 'tools', 'demo')),
include_package_data=True, include_package_data=True,
package_data={'mmdet3d.ops': ['*/*.so']},
classifiers=[ classifiers=[
'Development Status :: 4 - Beta', 'Development Status :: 5 - Production/Stable',
'License :: OSI Approved :: Apache Software License', 'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent', 'Operating System :: OS Independent',
'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7', 'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
], ],
license='Apache License 2.0', license='Apache License 2.0',
install_requires=parse_requirements('requirements/runtime.txt'), install_requires=parse_requirements('requirements/runtime.txt'),
...@@ -225,5 +220,6 @@ if __name__ == '__main__': ...@@ -225,5 +220,6 @@ if __name__ == '__main__':
'optional': parse_requirements('requirements/optional.txt'), 'optional': parse_requirements('requirements/optional.txt'),
'mim': parse_requirements('requirements/mminstall.txt'), 'mim': parse_requirements('requirements/mminstall.txt'),
}, },
ext_modules=[],
cmdclass={'build_ext': BuildExtension}, cmdclass={'build_ext': BuildExtension},
zip_safe=False) zip_safe=False)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment