Unverified Commit 6f1a268e authored by ChaimZhu's avatar ChaimZhu Committed by GitHub
Browse files

[Enhancement] Upgrade isort in pre-commit hook (#1217)

* update isort

* update setuptools

* fix

* pre-commit run --all-files
parent 53488dad
# Copyright (c) OpenMMLab. All rights reserved.
import torch
from functools import partial
import torch
from mmdet3d.core.points import get_points_type
......
# Copyright (c) OpenMMLab. All rights reserved.
import math
import numpy as np
from mmcv.cnn import ConvModule, build_conv_layer
from mmcv.runner import BaseModule
......
# Copyright (c) OpenMMLab. All rights reserved.
from abc import ABCMeta, abstractmethod
from mmcv.runner import BaseModule
......
# Copyright (c) OpenMMLab. All rights reserved.
import warnings
from torch.nn import functional as F
from mmdet3d.core import AssignResult
......
# Copyright (c) OpenMMLab. All rights reserved.
from os import path as osp
import mmcv
import numpy as np
import torch
from mmcv.parallel import DataContainer as DC
from mmcv.runner import auto_fp16
from os import path as osp
from mmdet3d.core import show_seg_result
from mmseg.models.segmentors import BaseSegmentor
......
# Copyright (c) OpenMMLab. All rights reserved.
from typing import List
import torch
from mmcv.runner import force_fp32
from torch import nn as nn
from typing import List
from .furthest_point_sample import (furthest_point_sample,
furthest_point_sample_with_dist)
......
# Copyright (c) OpenMMLab. All rights reserved.
from typing import Tuple
import torch
from torch import nn as nn
from torch.autograd import Function
from typing import Tuple
from ..ball_query import ball_query
from ..knn import knn
......
# Copyright (c) OpenMMLab. All rights reserved.
from typing import Tuple
import torch
from torch.autograd import Function
from typing import Tuple
from . import interpolate_ext
......
# Copyright (c) OpenMMLab. All rights reserved.
from typing import Tuple
import torch
from torch.autograd import Function
from typing import Tuple
from . import interpolate_ext
......
# Copyright (c) OpenMMLab. All rights reserved.
import copy
import torch
from mmcv.cnn import (ConvModule, build_activation_layer, build_norm_layer,
constant_init)
......
# Copyright (c) OpenMMLab. All rights reserved.
from typing import List
import torch
from mmcv.cnn import ConvModule
from mmcv.runner import BaseModule, force_fp32
from torch import nn as nn
from typing import List
from mmdet3d.ops import three_interpolate, three_nn
......
......@@ -12,6 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.
import math
import numpy as np
import torch
from mmcv.cnn import CONV_LAYERS
......
......@@ -12,8 +12,9 @@
# See the License for the specific language governing permissions and
# limitations under the License.
import sys
import torch
from collections import OrderedDict
import torch
from torch import nn
from .structure import SparseConvTensor
......
......@@ -11,9 +11,10 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import numpy as np
import unittest
import numpy as np
class TestCase(unittest.TestCase):
......
# Copyright (c) OpenMMLab. All rights reserved.
import logging
from mmcv.utils import get_logger
......
......@@ -6,7 +6,7 @@ SPLIT_BEFORE_EXPRESSION_AFTER_OPENING_PAREN = true
[isort]
line_length = 79
multi_line_output = 0
known_standard_library = setuptools
extra_standard_library = setuptools
known_first_party = mmdet,mmseg,mmdet3d
known_third_party = cv2,imageio,indoor3d_util,load_scannet_data,lyft_dataset_sdk,m2r,matplotlib,mmcv,nuimages,numba,numpy,nuscenes,pandas,plyfile,pycocotools,pyquaternion,pytest,pytorch_sphinx_theme,recommonmark,requests,scannet_utils,scipy,seaborn,shapely,skimage,sphinx,tensorflow,terminaltables,torch,trimesh,ts,waymo_open_dataset
no_lines_before = STDLIB,LOCALFOLDER
......
from setuptools import find_packages, setup
import os
import platform
import shutil
import sys
import torch
import warnings
from os import path as osp
from setuptools import find_packages, setup
import torch
from torch.utils.cpp_extension import (BuildExtension, CppExtension,
CUDAExtension)
......
# Copyright (c) OpenMMLab. All rights reserved.
import math
import numpy as np
import os
import pytest
import tempfile
import numpy as np
import pytest
import torch
from mmdet3d.core.bbox import LiDARInstance3DBoxes, limit_period
......@@ -255,9 +256,10 @@ def test_evaluate():
def test_show():
import mmcv
from os import path as osp
import mmcv
from mmdet3d.core.bbox import LiDARInstance3DBoxes
tmp_dir = tempfile.TemporaryDirectory()
temp_dir = tmp_dir.name
......
# Copyright (c) OpenMMLab. All rights reserved.
import tempfile
import mmcv
import numpy as np
import tempfile
import torch
from mmdet3d.core import limit_period
......@@ -140,9 +141,10 @@ def test_evaluate():
def test_show():
import mmcv
from os import path as osp
import mmcv
from mmdet3d.core.bbox import LiDARInstance3DBoxes
tmp_dir = tempfile.TemporaryDirectory()
temp_dir = tmp_dir.name
......
# Copyright (c) OpenMMLab. All rights reserved.
import numpy as np
import tempfile
import numpy as np
import torch
from mmdet3d.datasets import NuScenesDataset
......@@ -65,9 +66,10 @@ def test_getitem():
def test_show():
import mmcv
from os import path as osp
import mmcv
from mmdet3d.core.bbox import LiDARInstance3DBoxes
tmp_dir = tempfile.TemporaryDirectory()
temp_dir = tmp_dir.name
......
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