Rename TextDet directories

This commit is contained in:
gaotongxiao 2022-05-20 14:34:14 +08:00
parent a2a3b677d8
commit f820a50752
24 changed files with 15 additions and 14 deletions

View File

@ -1,11 +1,11 @@
# Copyright (c) OpenMMLab. All rights reserved.
from . import dense_heads, detectors, losses, necks, postprocess
from .dense_heads import * # NOQA
from . import detectors, heads, losses, necks, postprocessors
from .detectors import * # NOQA
from .heads import * # NOQA
from .losses import * # NOQA
from .necks import * # NOQA
from .postprocess import * # NOQA
from .postprocessors import * # NOQA
__all__ = (
dense_heads.__all__ + detectors.__all__ + losses.__all__ + necks.__all__ +
postprocess.__all__)
heads.__all__ + detectors.__all__ + losses.__all__ + necks.__all__ +
postprocessors.__all__)

View File

@ -6,7 +6,7 @@ from mmcv.runner import BaseModule
from mmdet.core import multi_apply
from mmocr.registry import MODELS
from ..postprocess.utils import poly_nms
from ..postprocessors.utils import poly_nms
from .head_mixin import HeadMixin

View File

@ -5,7 +5,7 @@ import torch
from lanms import merge_quadrangle_n9 as la_nms
from mmcv.ops import RoIAlignRotated
from mmocr.models.textdet.postprocess.utils import fill_hole
from mmocr.models.textdet.postprocessors.utils import fill_hole
from .utils import (euclidean_distance_matrix, feature_embedding,
normalize_adjacent_matrix)

View File

@ -2,7 +2,7 @@
import numpy as np
import pytest
import mmocr.models.textdet.dense_heads.pan_head as pan_head
import mmocr.models.textdet.heads.pan_head as pan_head
def test_panhead():

View File

@ -2,7 +2,7 @@
import numpy as np
import torch
from mmocr.models.textdet.dense_heads import DRRGHead
from mmocr.models.textdet.heads import DRRGHead
def test_drrg_head():

View File

@ -3,10 +3,11 @@ import numpy as np
import pytest
import torch
from mmocr.models.textdet.postprocess import (DBPostprocessor,
FCEPostprocessor,
TextSnakePostprocessor)
from mmocr.models.textdet.postprocess.utils import comps2boundaries, poly_nms
from mmocr.models.textdet.postprocessors import (DBPostprocessor,
FCEPostprocessor,
TextSnakePostprocessor)
from mmocr.models.textdet.postprocessors.utils import (comps2boundaries,
poly_nms)
def test_db_boxes_from_bitmaps():

View File

@ -7,7 +7,7 @@ from mmengine import InstanceData
from mmocr.core import TextDetDataSample
from mmocr.core.evaluation.utils import points2polygon, poly_iou
from mmocr.models.textdet.postprocess import BaseTextDetPostProcessor
from mmocr.models.textdet.postprocessors import BaseTextDetPostProcessor
class TestBaseTextDetPostProcessor(unittest.TestCase):