From 6e9ce183232648858d12f6c8f4061c0e83af92d3 Mon Sep 17 00:00:00 2001 From: Zaida Zhou <58739961+zhouzaida@users.noreply.github.com> Date: Thu, 24 Feb 2022 09:24:25 +0800 Subject: [PATCH] Add copyright pre-commit-hook (#1742) * first commit * Add copyright pre-commit-hook --- .pre-commit-config.yaml | 6 ++++++ mmcv/cnn/bricks/plugin.py | 1 + mmcv/cnn/utils/sync_bn.py | 1 + mmcv/runner/default_constructor.py | 1 + mmcv/tensorrt/preprocess.py | 1 + mmcv/utils/hub.py | 1 + mmcv/utils/trace.py | 1 + tests/data/config/a.b.py | 1 + tests/data/config/a.py | 1 + tests/data/config/base.py | 1 + tests/data/config/code.py | 1 + tests/data/config/d.py | 1 + tests/data/config/delete.py | 1 + tests/data/config/deprecated.py | 1 + tests/data/config/deprecated_as_base.py | 1 + tests/data/config/e.py | 1 + tests/data/config/expected.py | 1 + tests/data/config/f.py | 1 + tests/data/config/g.py | 1 + tests/data/config/h.py | 1 + tests/data/config/i_base.py | 1 + tests/data/config/i_child.py | 1 + tests/data/config/l.py | 1 + tests/data/config/l1.py | 1 + tests/data/config/l4.py | 1 + tests/data/config/m.py | 1 + tests/data/config/n.py | 1 + tests/data/config/q.py | 1 + tests/data/config/r.py | 1 + tests/data/config/s.py | 1 + tests/data/config/t.py | 1 + tests/data/config/u.py | 1 + tests/data/config/v.py | 1 + tests/data/scripts/hello.py | 1 + tests/test_cnn/test_build_layers.py | 1 + tests/test_cnn/test_context_block.py | 1 + tests/test_cnn/test_conv2d_adaptive_padding.py | 1 + tests/test_cnn/test_conv_module.py | 1 + tests/test_cnn/test_depthwise_seperable_conv_module.py | 1 + tests/test_cnn/test_flops_counter.py | 1 + tests/test_cnn/test_fuse_conv_bn.py | 1 + tests/test_cnn/test_generalized_attention.py | 1 + tests/test_cnn/test_hsigmoid.py | 1 + tests/test_cnn/test_hswish.py | 1 + tests/test_cnn/test_model_registry.py | 1 + tests/test_cnn/test_non_local.py | 1 + tests/test_cnn/test_revert_syncbn.py | 1 + tests/test_cnn/test_scale.py | 1 + tests/test_cnn/test_swish.py | 1 + tests/test_cnn/test_transformer.py | 1 + tests/test_cnn/test_wrappers.py | 1 + tests/test_fileclient.py | 1 + tests/test_ops/test_active_rotated_filter.py | 1 + tests/test_ops/test_assign_score_withk.py | 1 + tests/test_ops/test_ball_query.py | 1 + tests/test_ops/test_bbox.py | 1 + tests/test_ops/test_bilinear_grid_sample.py | 1 + tests/test_ops/test_border_align.py | 1 + tests/test_ops/test_box_iou_rotated.py | 1 + tests/test_ops/test_carafe.py | 1 + tests/test_ops/test_cc_attention.py | 1 + tests/test_ops/test_contour_expand.py | 1 + tests/test_ops/test_convex_iou.py | 1 + tests/test_ops/test_corner_pool.py | 1 + tests/test_ops/test_deform_conv.py | 1 + tests/test_ops/test_deform_roi_pool.py | 1 + tests/test_ops/test_focal_loss.py | 1 + tests/test_ops/test_furthest_point_sample.py | 1 + tests/test_ops/test_fused_bias_leakyrelu.py | 1 + tests/test_ops/test_gather_points.py | 1 + tests/test_ops/test_group_points.py | 1 + tests/test_ops/test_info.py | 1 + tests/test_ops/test_iou3d.py | 1 + tests/test_ops/test_knn.py | 1 + tests/test_ops/test_masked_conv2d.py | 1 + tests/test_ops/test_merge_cells.py | 1 + tests/test_ops/test_min_area_polygons.py | 1 + tests/test_ops/test_modulated_deform_conv.py | 1 + tests/test_ops/test_ms_deformable_attn.py | 1 + tests/test_ops/test_nms.py | 1 + tests/test_ops/test_nms_rotated.py | 1 + tests/test_ops/test_onnx.py | 1 + tests/test_ops/test_pixel_group.py | 1 + tests/test_ops/test_points_in_polygons.py | 1 + tests/test_ops/test_psa_mask.py | 1 + tests/test_ops/test_riroi_align_rotated.py | 1 + tests/test_ops/test_roi_align.py | 1 + tests/test_ops/test_roi_align_rotated.py | 1 + tests/test_ops/test_roi_pool.py | 1 + tests/test_ops/test_roipoint_pool3d.py | 1 + tests/test_ops/test_rotated_feature_align.py | 1 + tests/test_ops/test_saconv.py | 1 + tests/test_ops/test_scatter_points.py | 1 + tests/test_ops/test_spconv.py | 1 + tests/test_ops/test_syncbn.py | 1 + tests/test_ops/test_tensorrt.py | 1 + tests/test_ops/test_tensorrt_preprocess.py | 1 + tests/test_ops/test_three_interpolate.py | 1 + tests/test_ops/test_three_nn.py | 1 + tests/test_ops/test_tin_shift.py | 1 + tests/test_ops/test_upfirdn2d.py | 1 + tests/test_ops/test_voxelization.py | 1 + tests/test_parallel.py | 1 + tests/test_runner/test_basemodule.py | 1 + tests/test_runner/test_checkpoint.py | 1 + tests/test_runner/test_dist_utils.py | 1 + tests/test_runner/test_eval_hook.py | 1 + tests/test_runner/test_fp16.py | 1 + tests/test_runner/test_hooks.py | 1 + tests/test_runner/test_optimizer.py | 1 + tests/test_runner/test_utils.py | 1 + tests/test_utils/test_env.py | 1 + tests/test_utils/test_hub.py | 1 + tests/test_utils/test_logging.py | 1 + tests/test_utils/test_parrots_jit.py | 1 + tests/test_utils/test_registry.py | 1 + tests/test_utils/test_testing.py | 1 + tests/test_utils/test_trace.py | 1 + tests/test_utils/test_version_utils.py | 1 + 119 files changed, 124 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e581ce437a..b2686b7ca7 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -40,6 +40,12 @@ repos: hooks: - id: docformatter args: ["--in-place", "--wrap-descriptions", "79"] + + - repo: https://github.com/open-mmlab/pre-commit-hooks + rev: v0.2.0 # Use the ref you want to point at + hooks: + - id: check-copyright + args: ["mmcv", "tests", "--excludes", "mmcv/ops"] # - repo: local # hooks: # - id: clang-format diff --git a/mmcv/cnn/bricks/plugin.py b/mmcv/cnn/bricks/plugin.py index 82a876f018..009f7529be 100644 --- a/mmcv/cnn/bricks/plugin.py +++ b/mmcv/cnn/bricks/plugin.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import inspect import platform diff --git a/mmcv/cnn/utils/sync_bn.py b/mmcv/cnn/utils/sync_bn.py index 8a79ff4a4f..0c52526e95 100644 --- a/mmcv/cnn/utils/sync_bn.py +++ b/mmcv/cnn/utils/sync_bn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch import mmcv diff --git a/mmcv/runner/default_constructor.py b/mmcv/runner/default_constructor.py index 0bad847f2f..4a4f2cc646 100644 --- a/mmcv/runner/default_constructor.py +++ b/mmcv/runner/default_constructor.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. from .builder import RUNNER_BUILDERS, RUNNERS diff --git a/mmcv/tensorrt/preprocess.py b/mmcv/tensorrt/preprocess.py index d07c67fc99..3b3b9d7f03 100644 --- a/mmcv/tensorrt/preprocess.py +++ b/mmcv/tensorrt/preprocess.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import onnx diff --git a/mmcv/utils/hub.py b/mmcv/utils/hub.py index f8f1505c31..12fbff2ee4 100644 --- a/mmcv/utils/hub.py +++ b/mmcv/utils/hub.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. # The 1.6 release of PyTorch switched torch.save to use a new zipfile-based # file format. It will cause RuntimeError when a checkpoint was saved in # torch >= 1.6.0 but loaded in torch < 1.7.0. diff --git a/mmcv/utils/trace.py b/mmcv/utils/trace.py index 8e49bfd384..45423bd055 100644 --- a/mmcv/utils/trace.py +++ b/mmcv/utils/trace.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import warnings import torch diff --git a/tests/data/config/a.b.py b/tests/data/config/a.b.py index a591adf0cb..2364e1d10b 100644 --- a/tests/data/config/a.b.py +++ b/tests/data/config/a.b.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = [1, 2] item2 = {'a': 0} item3 = True diff --git a/tests/data/config/a.py b/tests/data/config/a.py index a591adf0cb..2364e1d10b 100644 --- a/tests/data/config/a.py +++ b/tests/data/config/a.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = [1, 2] item2 = {'a': 0} item3 = True diff --git a/tests/data/config/base.py b/tests/data/config/base.py index a591adf0cb..2364e1d10b 100644 --- a/tests/data/config/base.py +++ b/tests/data/config/base.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = [1, 2] item2 = {'a': 0} item3 = True diff --git a/tests/data/config/code.py b/tests/data/config/code.py index 2825c9b882..65f70045d2 100644 --- a/tests/data/config/code.py +++ b/tests/data/config/code.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. from mmcv import Config # isort:skip cfg = Config.fromfile('./tests/data/config/a.py') diff --git a/tests/data/config/d.py b/tests/data/config/d.py index f40e921170..19edcf82d0 100644 --- a/tests/data/config/d.py +++ b/tests/data/config/d.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './base.py' item1 = [2, 3] item2 = {'a': 1} diff --git a/tests/data/config/delete.py b/tests/data/config/delete.py index 668400c135..f8a1eaf64c 100644 --- a/tests/data/config/delete.py +++ b/tests/data/config/delete.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './base.py' item1 = {'a': 0, '_delete_': True} item2 = {'b': 0} diff --git a/tests/data/config/deprecated.py b/tests/data/config/deprecated.py index d4c40b2708..791b0f6ad8 100644 --- a/tests/data/config/deprecated.py +++ b/tests/data/config/deprecated.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './expected.py' _deprecation_ = dict( diff --git a/tests/data/config/deprecated_as_base.py b/tests/data/config/deprecated_as_base.py index 22e534fb6d..406964d102 100644 --- a/tests/data/config/deprecated_as_base.py +++ b/tests/data/config/deprecated_as_base.py @@ -1 +1,2 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './deprecated.py' \ No newline at end of file diff --git a/tests/data/config/e.py b/tests/data/config/e.py index 173fbe4716..1340e4bd27 100644 --- a/tests/data/config/e.py +++ b/tests/data/config/e.py @@ -1,2 +1,3 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './base.py' item3 = {'a': 1} diff --git a/tests/data/config/expected.py b/tests/data/config/expected.py index 96eb408cfb..7f6b729171 100644 --- a/tests/data/config/expected.py +++ b/tests/data/config/expected.py @@ -1 +1,2 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = 'expected' diff --git a/tests/data/config/f.py b/tests/data/config/f.py index c626885f31..b6ed109bde 100644 --- a/tests/data/config/f.py +++ b/tests/data/config/f.py @@ -1,2 +1,3 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './d.py' item4 = 'test_recursive_bases' diff --git a/tests/data/config/g.py b/tests/data/config/g.py index 9c55589947..34d4ebe2f8 100644 --- a/tests/data/config/g.py +++ b/tests/data/config/g.py @@ -1 +1,2 @@ +# Copyright (c) OpenMMLab. All rights reserved. filename = 'reserved.py' diff --git a/tests/data/config/h.py b/tests/data/config/h.py index 9562bb0ebc..82594590cf 100644 --- a/tests/data/config/h.py +++ b/tests/data/config/h.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = '{{fileBasename}}' item2 = '{{ fileDirname}}' item3 = 'abc_{{ fileBasenameNoExtension }}' diff --git a/tests/data/config/i_base.py b/tests/data/config/i_base.py index 5032f16287..f31a46a15d 100644 --- a/tests/data/config/i_base.py +++ b/tests/data/config/i_base.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = [1, 2] item2 = {'a': 0} item3 = True diff --git a/tests/data/config/i_child.py b/tests/data/config/i_child.py index 9fb59721e0..dfb91d16e9 100644 --- a/tests/data/config/i_child.py +++ b/tests/data/config/i_child.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = './i_base.py' item_cfg = {'b': 2} item6 = {'cfg': item_cfg} diff --git a/tests/data/config/l.py b/tests/data/config/l.py index b63dd5ef71..85736f96e0 100644 --- a/tests/data/config/l.py +++ b/tests/data/config/l.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = ['./l1.py', './l2.yaml', './l3.json', './l4.py'] item3 = False item4 = 'test' diff --git a/tests/data/config/l1.py b/tests/data/config/l1.py index 939ac08d93..13db1375e7 100644 --- a/tests/data/config/l1.py +++ b/tests/data/config/l1.py @@ -1 +1,2 @@ +# Copyright (c) OpenMMLab. All rights reserved. item1 = [1, 2] diff --git a/tests/data/config/l4.py b/tests/data/config/l4.py index 2bfc70bef8..cb7b4365ec 100644 --- a/tests/data/config/l4.py +++ b/tests/data/config/l4.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. item5 = dict(a=0, b=1) item6 = [dict(a=0), dict(b=1)] item7 = dict(a=[0, 1, 2], b=dict(c=[3.1, 4.2, 5.3])) diff --git a/tests/data/config/m.py b/tests/data/config/m.py index 950e40e528..af81ca35ca 100644 --- a/tests/data/config/m.py +++ b/tests/data/config/m.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = ['./l1.py', './l2.yaml', './l3.json', 'a.py'] item3 = False item4 = 'test' diff --git a/tests/data/config/n.py b/tests/data/config/n.py index fb193e6881..fa7aae266e 100644 --- a/tests/data/config/n.py +++ b/tests/data/config/n.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. test_item1 = [1, 2] bool_item2 = True str_item3 = 'test' diff --git a/tests/data/config/q.py b/tests/data/config/q.py index 440a3056d1..f7ca0a70bb 100644 --- a/tests/data/config/q.py +++ b/tests/data/config/q.py @@ -1 +1,2 @@ +# Copyright (c) OpenMMLab. All rights reserved. custom_imports = dict(imports=['r'], allow_failed_imports=False) diff --git a/tests/data/config/r.py b/tests/data/config/r.py index 9360128d57..26d982e82a 100644 --- a/tests/data/config/r.py +++ b/tests/data/config/r.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os os.environ["TEST_VALUE"] = 'test' diff --git a/tests/data/config/s.py b/tests/data/config/s.py index 7c142f117a..cca07539c8 100644 --- a/tests/data/config/s.py +++ b/tests/data/config/s.py @@ -1 +1,2 @@ +# Copyright (c) OpenMMLab. All rights reserved. item = [{'a': 0}, {'b': 0, 'c': 0}] diff --git a/tests/data/config/t.py b/tests/data/config/t.py index 9f085ae675..1df57cb5ad 100644 --- a/tests/data/config/t.py +++ b/tests/data/config/t.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = ['./l1.py', './l2.yaml', './l3.json', './l4.py'] item3 = False item4 = 'test' diff --git a/tests/data/config/u.py b/tests/data/config/u.py index bdd96a7e46..be6c5bbb7e 100644 --- a/tests/data/config/u.py +++ b/tests/data/config/u.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = ['./t.py'] base = '_base_.item8' item11 = {{ _base_.item8 }} diff --git a/tests/data/config/v.py b/tests/data/config/v.py index 3d2a1a436c..13d204d24f 100644 --- a/tests/data/config/v.py +++ b/tests/data/config/v.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. _base_ = ['./u.py'] item21 = {{ _base_.item11 }} item22 = item21 diff --git a/tests/data/scripts/hello.py b/tests/data/scripts/hello.py index d7215d0b7f..2ed1a1e319 100755 --- a/tests/data/scripts/hello.py +++ b/tests/data/scripts/hello.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. #!/usr/bin/env python import argparse diff --git a/tests/test_cnn/test_build_layers.py b/tests/test_cnn/test_build_layers.py index 445cb8e1a8..519874ecd7 100644 --- a/tests/test_cnn/test_build_layers.py +++ b/tests/test_cnn/test_build_layers.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_cnn/test_context_block.py b/tests/test_cnn/test_context_block.py index 8aa18f86a7..864cb41793 100644 --- a/tests/test_cnn/test_context_block.py +++ b/tests/test_cnn/test_context_block.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_cnn/test_conv2d_adaptive_padding.py b/tests/test_cnn/test_conv2d_adaptive_padding.py index 051d6e585c..83114bd5b5 100644 --- a/tests/test_cnn/test_conv2d_adaptive_padding.py +++ b/tests/test_cnn/test_conv2d_adaptive_padding.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch from mmcv.cnn.bricks import Conv2dAdaptivePadding diff --git a/tests/test_cnn/test_conv_module.py b/tests/test_cnn/test_conv_module.py index 6ef531c8ee..ee89c3f276 100644 --- a/tests/test_cnn/test_conv_module.py +++ b/tests/test_cnn/test_conv_module.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import warnings from unittest.mock import patch diff --git a/tests/test_cnn/test_depthwise_seperable_conv_module.py b/tests/test_cnn/test_depthwise_seperable_conv_module.py index 10b4c56824..748fc1bf88 100644 --- a/tests/test_cnn/test_depthwise_seperable_conv_module.py +++ b/tests/test_cnn/test_depthwise_seperable_conv_module.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch import torch.nn as nn diff --git a/tests/test_cnn/test_flops_counter.py b/tests/test_cnn/test_flops_counter.py index 99a53b7571..e2ba6e242f 100644 --- a/tests/test_cnn/test_flops_counter.py +++ b/tests/test_cnn/test_flops_counter.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch import torch.nn as nn diff --git a/tests/test_cnn/test_fuse_conv_bn.py b/tests/test_cnn/test_fuse_conv_bn.py index f1346f6de7..e60be5386c 100644 --- a/tests/test_cnn/test_fuse_conv_bn.py +++ b/tests/test_cnn/test_fuse_conv_bn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch import torch.nn as nn diff --git a/tests/test_cnn/test_generalized_attention.py b/tests/test_cnn/test_generalized_attention.py index 27207c9241..6b844f0ad5 100644 --- a/tests/test_cnn/test_generalized_attention.py +++ b/tests/test_cnn/test_generalized_attention.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch from mmcv.cnn.bricks import GeneralizedAttention diff --git a/tests/test_cnn/test_hsigmoid.py b/tests/test_cnn/test_hsigmoid.py index 5f9baf5d37..43e9f624a2 100644 --- a/tests/test_cnn/test_hsigmoid.py +++ b/tests/test_cnn/test_hsigmoid.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_cnn/test_hswish.py b/tests/test_cnn/test_hswish.py index 05300840a6..5cd1bcf312 100644 --- a/tests/test_cnn/test_hswish.py +++ b/tests/test_cnn/test_hswish.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch from torch.nn.functional import relu6 diff --git a/tests/test_cnn/test_model_registry.py b/tests/test_cnn/test_model_registry.py index 86fb15b685..dd446cef5d 100644 --- a/tests/test_cnn/test_model_registry.py +++ b/tests/test_cnn/test_model_registry.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch.nn as nn import mmcv diff --git a/tests/test_cnn/test_non_local.py b/tests/test_cnn/test_non_local.py index de231f957e..25d7883391 100644 --- a/tests/test_cnn/test_non_local.py +++ b/tests/test_cnn/test_non_local.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch import torch.nn as nn diff --git a/tests/test_cnn/test_revert_syncbn.py b/tests/test_cnn/test_revert_syncbn.py index 69c916160c..004259d496 100644 --- a/tests/test_cnn/test_revert_syncbn.py +++ b/tests/test_cnn/test_revert_syncbn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import platform diff --git a/tests/test_cnn/test_scale.py b/tests/test_cnn/test_scale.py index a380b902c8..bee78eb57f 100644 --- a/tests/test_cnn/test_scale.py +++ b/tests/test_cnn/test_scale.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch from mmcv.cnn.bricks import Scale diff --git a/tests/test_cnn/test_swish.py b/tests/test_cnn/test_swish.py index 073a3d8796..2317f5a139 100644 --- a/tests/test_cnn/test_swish.py +++ b/tests/test_cnn/test_swish.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch import torch.nn.functional as F diff --git a/tests/test_cnn/test_transformer.py b/tests/test_cnn/test_transformer.py index 0fc14a8969..b330aed34a 100644 --- a/tests/test_cnn/test_transformer.py +++ b/tests/test_cnn/test_transformer.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import copy import pytest diff --git a/tests/test_cnn/test_wrappers.py b/tests/test_cnn/test_wrappers.py index ffc933fec2..02e0f13cd7 100644 --- a/tests/test_cnn/test_wrappers.py +++ b/tests/test_cnn/test_wrappers.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. from unittest.mock import patch import pytest diff --git a/tests/test_fileclient.py b/tests/test_fileclient.py index 30f32432a9..9a10d930f3 100644 --- a/tests/test_fileclient.py +++ b/tests/test_fileclient.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import os.path as osp import sys diff --git a/tests/test_ops/test_active_rotated_filter.py b/tests/test_ops/test_active_rotated_filter.py index a1afc55a49..30ea59c5c6 100644 --- a/tests/test_ops/test_active_rotated_filter.py +++ b/tests/test_ops/test_active_rotated_filter.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_assign_score_withk.py b/tests/test_ops/test_assign_score_withk.py index 4f45525310..f8fc6ae626 100644 --- a/tests/test_ops/test_assign_score_withk.py +++ b/tests/test_ops/test_assign_score_withk.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_ball_query.py b/tests/test_ops/test_ball_query.py index cf30a7efab..4c78dc6600 100644 --- a/tests/test_ops/test_ball_query.py +++ b/tests/test_ops/test_ball_query.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_bbox.py b/tests/test_ops/test_bbox.py index cff7bcca6c..2bdb3ce7a9 100644 --- a/tests/test_ops/test_bbox.py +++ b/tests/test_ops/test_bbox.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_bilinear_grid_sample.py b/tests/test_ops/test_bilinear_grid_sample.py index 0b78227bf6..d8ac22f6b7 100644 --- a/tests/test_ops/test_bilinear_grid_sample.py +++ b/tests/test_ops/test_bilinear_grid_sample.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch import torch.nn.functional as F diff --git a/tests/test_ops/test_border_align.py b/tests/test_ops/test_border_align.py index 410f0285f1..71518ce960 100644 --- a/tests/test_ops/test_border_align.py +++ b/tests/test_ops/test_border_align.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import copy import numpy as np diff --git a/tests/test_ops/test_box_iou_rotated.py b/tests/test_ops/test_box_iou_rotated.py index 07a01792ad..847644339b 100644 --- a/tests/test_ops/test_box_iou_rotated.py +++ b/tests/test_ops/test_box_iou_rotated.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_carafe.py b/tests/test_ops/test_carafe.py index 0265bdeced..3a4c6bef70 100644 --- a/tests/test_ops/test_carafe.py +++ b/tests/test_ops/test_carafe.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch from torch.autograd import gradcheck diff --git a/tests/test_ops/test_cc_attention.py b/tests/test_ops/test_cc_attention.py index 5dd948e5df..3da739b75c 100644 --- a/tests/test_ops/test_cc_attention.py +++ b/tests/test_ops/test_cc_attention.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch import torch.nn as nn diff --git a/tests/test_ops/test_contour_expand.py b/tests/test_ops/test_contour_expand.py index c337b44b50..b36bbf4155 100644 --- a/tests/test_ops/test_contour_expand.py +++ b/tests/test_ops/test_contour_expand.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch diff --git a/tests/test_ops/test_convex_iou.py b/tests/test_ops/test_convex_iou.py index 8eebf2cc58..95dc482434 100644 --- a/tests/test_ops/test_convex_iou.py +++ b/tests/test_ops/test_convex_iou.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_corner_pool.py b/tests/test_ops/test_corner_pool.py index 95d32f3a1a..d6dd25f223 100644 --- a/tests/test_ops/test_corner_pool.py +++ b/tests/test_ops/test_corner_pool.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. """ CommandLine: pytest tests/test_corner_pool.py diff --git a/tests/test_ops/test_deform_conv.py b/tests/test_ops/test_deform_conv.py index 2118cfb62f..cbea9156ce 100644 --- a/tests/test_ops/test_deform_conv.py +++ b/tests/test_ops/test_deform_conv.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_deform_roi_pool.py b/tests/test_ops/test_deform_roi_pool.py index a3eeda97fc..7dbca1a29a 100644 --- a/tests/test_ops/test_deform_roi_pool.py +++ b/tests/test_ops/test_deform_roi_pool.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import numpy as np diff --git a/tests/test_ops/test_focal_loss.py b/tests/test_ops/test_focal_loss.py index e52f060f6a..a9a10cc2e3 100644 --- a/tests/test_ops/test_focal_loss.py +++ b/tests/test_ops/test_focal_loss.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch diff --git a/tests/test_ops/test_furthest_point_sample.py b/tests/test_ops/test_furthest_point_sample.py index d64dedc034..7e61e64a91 100644 --- a/tests/test_ops/test_furthest_point_sample.py +++ b/tests/test_ops/test_furthest_point_sample.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_fused_bias_leakyrelu.py b/tests/test_ops/test_fused_bias_leakyrelu.py index 5f92757b9a..c0169ea6c5 100644 --- a/tests/test_ops/test_fused_bias_leakyrelu.py +++ b/tests/test_ops/test_fused_bias_leakyrelu.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_gather_points.py b/tests/test_ops/test_gather_points.py index 7ca2df02d7..c827db08d0 100644 --- a/tests/test_ops/test_gather_points.py +++ b/tests/test_ops/test_gather_points.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_group_points.py b/tests/test_ops/test_group_points.py index 1b495c2850..b295437fb8 100644 --- a/tests/test_ops/test_group_points.py +++ b/tests/test_ops/test_group_points.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_info.py b/tests/test_ops/test_info.py index 4c95c29129..ba467cbde2 100644 --- a/tests/test_ops/test_info.py +++ b/tests/test_ops/test_info.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch diff --git a/tests/test_ops/test_iou3d.py b/tests/test_ops/test_iou3d.py index 21ed84a9e5..66cc44b947 100644 --- a/tests/test_ops/test_iou3d.py +++ b/tests/test_ops/test_iou3d.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_knn.py b/tests/test_ops/test_knn.py index 2740cb5e1b..1236a5fcbe 100644 --- a/tests/test_ops/test_knn.py +++ b/tests/test_ops/test_knn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_masked_conv2d.py b/tests/test_ops/test_masked_conv2d.py index 6df70bcefa..9150fb5b19 100644 --- a/tests/test_ops/test_masked_conv2d.py +++ b/tests/test_ops/test_masked_conv2d.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch diff --git a/tests/test_ops/test_merge_cells.py b/tests/test_ops/test_merge_cells.py index 47080ff2c3..98a60c5324 100644 --- a/tests/test_ops/test_merge_cells.py +++ b/tests/test_ops/test_merge_cells.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. """ CommandLine: pytest tests/test_merge_cells.py diff --git a/tests/test_ops/test_min_area_polygons.py b/tests/test_ops/test_min_area_polygons.py index 560dc51061..649bdecfd6 100644 --- a/tests/test_ops/test_min_area_polygons.py +++ b/tests/test_ops/test_min_area_polygons.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_modulated_deform_conv.py b/tests/test_ops/test_modulated_deform_conv.py index b528c5112b..5386cc78c3 100644 --- a/tests/test_ops/test_modulated_deform_conv.py +++ b/tests/test_ops/test_modulated_deform_conv.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import numpy diff --git a/tests/test_ops/test_ms_deformable_attn.py b/tests/test_ops/test_ms_deformable_attn.py index 0c350deee0..fee94c575c 100644 --- a/tests/test_ops/test_ms_deformable_attn.py +++ b/tests/test_ops/test_ms_deformable_attn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_nms.py b/tests/test_ops/test_nms.py index 26bac18ef9..44b7dbd74b 100644 --- a/tests/test_ops/test_nms.py +++ b/tests/test_ops/test_nms.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_nms_rotated.py b/tests/test_ops/test_nms_rotated.py index 6c6b10c268..1cf9599de2 100644 --- a/tests/test_ops/test_nms_rotated.py +++ b/tests/test_ops/test_nms_rotated.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_onnx.py b/tests/test_ops/test_onnx.py index 88fb90e8d5..2db003bdc1 100644 --- a/tests/test_ops/test_onnx.py +++ b/tests/test_ops/test_onnx.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import warnings from functools import partial diff --git a/tests/test_ops/test_pixel_group.py b/tests/test_ops/test_pixel_group.py index c7052ce30d..ceb2573657 100644 --- a/tests/test_ops/test_pixel_group.py +++ b/tests/test_ops/test_pixel_group.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch diff --git a/tests/test_ops/test_points_in_polygons.py b/tests/test_ops/test_points_in_polygons.py index b76e1a8ab6..dde8ab0239 100644 --- a/tests/test_ops/test_points_in_polygons.py +++ b/tests/test_ops/test_points_in_polygons.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_psa_mask.py b/tests/test_ops/test_psa_mask.py index df70fd50de..266f466afd 100644 --- a/tests/test_ops/test_psa_mask.py +++ b/tests/test_ops/test_psa_mask.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import torch import torch.nn as nn diff --git a/tests/test_ops/test_riroi_align_rotated.py b/tests/test_ops/test_riroi_align_rotated.py index ddab41db65..3347cfb585 100644 --- a/tests/test_ops/test_riroi_align_rotated.py +++ b/tests/test_ops/test_riroi_align_rotated.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_roi_align.py b/tests/test_ops/test_roi_align.py index db7c037401..70134bd0ac 100644 --- a/tests/test_ops/test_roi_align.py +++ b/tests/test_ops/test_roi_align.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_roi_align_rotated.py b/tests/test_ops/test_roi_align_rotated.py index 3e85ce9b9c..dd9e455403 100644 --- a/tests/test_ops/test_roi_align_rotated.py +++ b/tests/test_ops/test_roi_align_rotated.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_ops/test_roi_pool.py b/tests/test_ops/test_roi_pool.py index d38c45ad17..db7180eabc 100644 --- a/tests/test_ops/test_roi_pool.py +++ b/tests/test_ops/test_roi_pool.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import numpy as np diff --git a/tests/test_ops/test_roipoint_pool3d.py b/tests/test_ops/test_roipoint_pool3d.py index 7db3885d71..a4b10e2788 100644 --- a/tests/test_ops/test_roipoint_pool3d.py +++ b/tests/test_ops/test_roipoint_pool3d.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_rotated_feature_align.py b/tests/test_ops/test_rotated_feature_align.py index af6a66a308..61d2b9f79d 100644 --- a/tests/test_ops/test_rotated_feature_align.py +++ b/tests/test_ops/test_rotated_feature_align.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_saconv.py b/tests/test_ops/test_saconv.py index b34865fc93..607775c385 100644 --- a/tests/test_ops/test_saconv.py +++ b/tests/test_ops/test_saconv.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import torch import torch.nn as nn diff --git a/tests/test_ops/test_scatter_points.py b/tests/test_ops/test_scatter_points.py index 8fe1fe8cd0..8610124e30 100644 --- a/tests/test_ops/test_scatter_points.py +++ b/tests/test_ops/test_scatter_points.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch from torch.autograd import gradcheck diff --git a/tests/test_ops/test_spconv.py b/tests/test_ops/test_spconv.py index 5c897a1baa..8841ac11cc 100644 --- a/tests/test_ops/test_spconv.py +++ b/tests/test_ops/test_spconv.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch from torch import nn diff --git a/tests/test_ops/test_syncbn.py b/tests/test_ops/test_syncbn.py index fb1c8379eb..fb3c1a07b7 100644 --- a/tests/test_ops/test_syncbn.py +++ b/tests/test_ops/test_syncbn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import platform diff --git a/tests/test_ops/test_tensorrt.py b/tests/test_ops/test_tensorrt.py index 8bd9402319..d3b737dd04 100644 --- a/tests/test_ops/test_tensorrt.py +++ b/tests/test_ops/test_tensorrt.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os from functools import partial from typing import Callable diff --git a/tests/test_ops/test_tensorrt_preprocess.py b/tests/test_ops/test_tensorrt_preprocess.py index b5ade24b4b..a35030fc39 100644 --- a/tests/test_ops/test_tensorrt_preprocess.py +++ b/tests/test_ops/test_tensorrt_preprocess.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os from functools import wraps diff --git a/tests/test_ops/test_three_interpolate.py b/tests/test_ops/test_three_interpolate.py index 4dffe5a2ee..900f451ff8 100644 --- a/tests/test_ops/test_three_interpolate.py +++ b/tests/test_ops/test_three_interpolate.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_three_nn.py b/tests/test_ops/test_three_nn.py index e7cba24a83..c30690310c 100644 --- a/tests/test_ops/test_three_nn.py +++ b/tests/test_ops/test_three_nn.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_tin_shift.py b/tests/test_ops/test_tin_shift.py index 93cea6ea58..dac1490ca6 100644 --- a/tests/test_ops/test_tin_shift.py +++ b/tests/test_ops/test_tin_shift.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import numpy as np diff --git a/tests/test_ops/test_upfirdn2d.py b/tests/test_ops/test_upfirdn2d.py index f1c33bcddc..794869dc40 100644 --- a/tests/test_ops/test_upfirdn2d.py +++ b/tests/test_ops/test_upfirdn2d.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_ops/test_voxelization.py b/tests/test_ops/test_voxelization.py index 8af2408b50..db956da41b 100644 --- a/tests/test_ops/test_voxelization.py +++ b/tests/test_ops/test_voxelization.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_parallel.py b/tests/test_parallel.py index f551c4025c..b39db90768 100644 --- a/tests/test_parallel.py +++ b/tests/test_parallel.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. from unittest.mock import MagicMock, patch import pytest diff --git a/tests/test_runner/test_basemodule.py b/tests/test_runner/test_basemodule.py index 845086fe3a..558d7e22f1 100644 --- a/tests/test_runner/test_basemodule.py +++ b/tests/test_runner/test_basemodule.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import tempfile import pytest diff --git a/tests/test_runner/test_checkpoint.py b/tests/test_runner/test_checkpoint.py index 99408d3cc2..0a0f0885ca 100644 --- a/tests/test_runner/test_checkpoint.py +++ b/tests/test_runner/test_checkpoint.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import sys from collections import OrderedDict from tempfile import TemporaryDirectory diff --git a/tests/test_runner/test_dist_utils.py b/tests/test_runner/test_dist_utils.py index 00e43066cb..979c2e4f3f 100644 --- a/tests/test_runner/test_dist_utils.py +++ b/tests/test_runner/test_dist_utils.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os from unittest.mock import patch diff --git a/tests/test_runner/test_eval_hook.py b/tests/test_runner/test_eval_hook.py index 70fc82cbc2..e03ce82db2 100644 --- a/tests/test_runner/test_eval_hook.py +++ b/tests/test_runner/test_eval_hook.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import json import os.path as osp import sys diff --git a/tests/test_runner/test_fp16.py b/tests/test_runner/test_fp16.py index b3c82719e5..e9d68d471a 100644 --- a/tests/test_runner/test_fp16.py +++ b/tests/test_runner/test_fp16.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest import torch diff --git a/tests/test_runner/test_hooks.py b/tests/test_runner/test_hooks.py index 8f56cf2bd7..4c1174f1da 100644 --- a/tests/test_runner/test_hooks.py +++ b/tests/test_runner/test_hooks.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. """Tests the hooks with runners. CommandLine: diff --git a/tests/test_runner/test_optimizer.py b/tests/test_runner/test_optimizer.py index cae22f7b51..724f45db96 100644 --- a/tests/test_runner/test_optimizer.py +++ b/tests/test_runner/test_optimizer.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import sys import warnings from unittest.mock import MagicMock diff --git a/tests/test_runner/test_utils.py b/tests/test_runner/test_utils.py index 974bac8d2f..3d2d18146c 100644 --- a/tests/test_runner/test_utils.py +++ b/tests/test_runner/test_utils.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import os import random diff --git a/tests/test_utils/test_env.py b/tests/test_utils/test_env.py index 7c245c7a52..54f01bc452 100644 --- a/tests/test_utils/test_env.py +++ b/tests/test_utils/test_env.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import sys import pytest diff --git a/tests/test_utils/test_hub.py b/tests/test_utils/test_hub.py index 046415152f..3e117f183f 100644 --- a/tests/test_utils/test_hub.py +++ b/tests/test_utils/test_hub.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest from torch.utils import model_zoo diff --git a/tests/test_utils/test_logging.py b/tests/test_utils/test_logging.py index 4be4bb2ada..f6f9cfb365 100644 --- a/tests/test_utils/test_logging.py +++ b/tests/test_utils/test_logging.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import logging import os import platform diff --git a/tests/test_utils/test_parrots_jit.py b/tests/test_utils/test_parrots_jit.py index 78f8b9f602..ddf08bdfcd 100644 --- a/tests/test_utils/test_parrots_jit.py +++ b/tests/test_utils/test_parrots_jit.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_utils/test_registry.py b/tests/test_utils/test_registry.py index 4ae84de553..cb5c70c997 100644 --- a/tests/test_utils/test_registry.py +++ b/tests/test_utils/test_registry.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import mmcv diff --git a/tests/test_utils/test_testing.py b/tests/test_utils/test_testing.py index 0a479d3725..f428b9de60 100644 --- a/tests/test_utils/test_testing.py +++ b/tests/test_utils/test_testing.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import numpy as np import pytest diff --git a/tests/test_utils/test_trace.py b/tests/test_utils/test_trace.py index 3aca0b1204..2dbf2c8549 100644 --- a/tests/test_utils/test_trace.py +++ b/tests/test_utils/test_trace.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. import pytest import torch diff --git a/tests/test_utils/test_version_utils.py b/tests/test_utils/test_version_utils.py index 58bac0bab9..e20d750fee 100644 --- a/tests/test_utils/test_version_utils.py +++ b/tests/test_utils/test_version_utils.py @@ -1,3 +1,4 @@ +# Copyright (c) OpenMMLab. All rights reserved. from unittest.mock import patch import pytest