Skip to content

Commit

Permalink
fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
sunjiahao1999 committed Sep 18, 2023
1 parent 9824778 commit 681423f
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 11 deletions.
1 change: 0 additions & 1 deletion mmdet3d/datasets/waymo_dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import os.path as osp
from typing import Callable, List, Union

import mmengine
import numpy as np
from mmengine import print_log
from mmengine.fileio import load
Expand Down
2 changes: 1 addition & 1 deletion mmdet3d/models/necks/second_fpn.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ class SECONDFPN(BaseModule):
conv_cfg (dict): Config dict of conv layers.
use_conv_for_no_stride (bool): Whether to use conv when stride is 1.
init_cfg (dict or :obj:`ConfigDict` or list[dict or :obj:`ConfigDict`],
optional): Initialization config dict. Defaults to
optional): Initialization config dict. Defaults to
[dict(type='Kaiming', layer='ConvTranspose2d'),
dict(type='Constant', layer='NaiveSyncBatchNorm2d', val=1.0)].
"""
Expand Down
9 changes: 4 additions & 5 deletions projects/DSVT/dsvt/dsvt_head.py
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
import math
from typing import Dict, List, Tuple

import torch
import torch.nn as nn
from mmcv.ops import boxes_iou3d
from mmdet.models.utils import multi_apply
from mmengine.model import kaiming_init
from mmengine.structures import InstanceData
from torch import Tensor
from torch.nn.init import constant_

from mmdet3d.models import CenterHead
from mmdet3d.models.layers import circle_nms, nms_bev
from mmdet3d.models.utils import (clip_sigmoid, draw_heatmap_gaussian,
gaussian_radius)
from mmdet3d.registry import MODELS
from mmdet3d.structures import Det3DDataSample, xywhr2xyxyr
from mmengine.model import kaiming_init
import math
from torch.nn.init import constant_
import torch.nn as nn


@MODELS.register_module()
Expand Down Expand Up @@ -53,7 +53,6 @@ def init_weights(self):
kaiming_init(
m, mode='fan_in', nonlinearity='leaky_relu')


def forward_single(self, x: Tensor) -> dict:
"""Forward function for CenterPoint.
Expand Down
4 changes: 1 addition & 3 deletions projects/DSVT/dsvt/res_second.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# modified from https://github.com/Haiyang-W/DSVT

import warnings
from typing import Optional, Sequence, Tuple
from typing import Sequence, Tuple

from mmengine.model import BaseModule
from torch import Tensor
Expand Down
2 changes: 1 addition & 1 deletion projects/DSVT/dsvt/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from mmdet3d.models.task_modules import CenterPointBBoxCoder
from mmdet3d.registry import MODELS, TASK_UTILS
from .ops.ingroup_inds.ingroup_inds_op import ingroup_inds
from mmengine import print_log

get_inner_win_inds_cuda = ingroup_inds


Expand Down

0 comments on commit 681423f

Please sign in to comment.