mirror of
https://github.com/open-mmlab/mmdeploy.git
synced 2025-01-14 08:09:43 +08:00
* update test for mmcls and mmdet * update det3d mmedit mmocr mmpose mmrotate * update mmseg * bug fixing * refactor ops * rename variable * remove comment
20 lines
521 B
Python
20 lines
521 B
Python
# Copyright (c) OpenMMLab. All rights reserved.
|
|
import pytest
|
|
|
|
from mmdeploy.codebase import import_codebase
|
|
from mmdeploy.utils import Codebase
|
|
|
|
|
|
def pytest_ignore_collect(*args, **kwargs):
|
|
import importlib
|
|
return importlib.util.find_spec('mmrotate') is None
|
|
|
|
|
|
@pytest.fixture(autouse=True, scope='package')
|
|
def import_all_modules():
|
|
codebase = Codebase.MMROTATE
|
|
try:
|
|
import_codebase(codebase)
|
|
except ImportError:
|
|
pytest.skip(f'{codebase} is not installed.', allow_module_level=True)
|