mirror of https://github.com/open-mmlab/mmocr.git
[Docs] API refactor (#1409)
parent
f30c16ce96
commit
ec395c5c68
docs
mmocr
models/textrecog
utils
|
@ -0,0 +1,14 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
.. currentmodule:: {{ module }}
|
||||
|
||||
|
||||
{{ name | underline}}
|
||||
|
||||
.. autoclass:: {{ name }}
|
||||
:members:
|
||||
|
||||
|
||||
..
|
||||
autogenerated from source/_templates/classtemplate.rst
|
||||
note it does not have :inherited-members:
|
252
docs/en/api.rst
252
docs/en/api.rst
|
@ -1,252 +0,0 @@
|
|||
mmocr.datasets
|
||||
---------------------------------------------
|
||||
.. automodule:: mmocr.datasets
|
||||
:members:
|
||||
|
||||
Dataset Types
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.datasets.ocr_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.icdar_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.recog_lmdb_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.recog_text_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.wildreceipt_dataset
|
||||
:members:
|
||||
|
||||
Transforms
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.datasets.transforms
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.engine
|
||||
---------------------------------------------
|
||||
Hooks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.engine.hooks
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.evaluation
|
||||
---------------------------------------------
|
||||
Evaluator
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.evaluation.evaluator
|
||||
:members:
|
||||
|
||||
Functional
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.evaluation.functional
|
||||
:members:
|
||||
|
||||
Metric
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.evaluation.metrics
|
||||
:members:
|
||||
|
||||
mmocr.utils
|
||||
---------------------------------------------
|
||||
Point utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.utils.point_utils
|
||||
:members:
|
||||
|
||||
Bbox utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.utils.bbox_utils
|
||||
:members:
|
||||
|
||||
Polygon utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.polygon_utils
|
||||
:members:
|
||||
|
||||
Mask utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.mask_utils
|
||||
:members:
|
||||
|
||||
String utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.string_utils
|
||||
:members:
|
||||
|
||||
Image utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.img_utils
|
||||
:members:
|
||||
|
||||
File IO utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.fileio
|
||||
:members:
|
||||
|
||||
Others
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.data_converter_utils
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.utils.parsers
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.models
|
||||
---------------------------------------------
|
||||
Common
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.common.backbones
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.losses
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.dictionary
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.layers
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.modules
|
||||
:members:
|
||||
|
||||
Text Detection Detectors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.detectors
|
||||
:members:
|
||||
|
||||
Text Detection Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.heads
|
||||
:members:
|
||||
|
||||
Text Detection Necks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.necks
|
||||
:members:
|
||||
|
||||
Text Detection Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.module_losses
|
||||
:members:
|
||||
|
||||
Text Detection Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.data_preprocessors
|
||||
:members:
|
||||
|
||||
Text Detection Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.postprocessors
|
||||
:members:
|
||||
|
||||
Text Recognition Recognizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.recognizers
|
||||
:members:
|
||||
|
||||
Text Recognition Backbones
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.backbones
|
||||
:members:
|
||||
|
||||
Text Recognition Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.data_preprocessors
|
||||
:members:
|
||||
|
||||
Text Recognition Layers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.layers
|
||||
:members:
|
||||
|
||||
Text Recognition Plugins
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.plugins
|
||||
:members:
|
||||
|
||||
Text Recognition Encoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.encoders
|
||||
:members:
|
||||
|
||||
Text Recognition Decoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.decoders
|
||||
:members:
|
||||
|
||||
Text Recognition Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.module_losses
|
||||
:members:
|
||||
|
||||
KIE Extractors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.kie.extractors
|
||||
:members:
|
||||
|
||||
KIE Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.kie.heads
|
||||
:members:
|
||||
|
||||
KIE Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.kie.module_losses
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.structures
|
||||
---------------------------------------------
|
||||
|
||||
Text Detection Data Sample
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.structures.textdet_data_sample
|
||||
:members:
|
||||
|
||||
Text Recognition Data Sample
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.structures.textrecog_data_sample
|
||||
:members:
|
||||
|
||||
KIE Data Sample
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.structures.kie_data_sample
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.visualization
|
||||
---------------------------------------------
|
||||
|
||||
Text Detection Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.textdet_visualizer
|
||||
:members:
|
||||
|
||||
Text Recognition Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.textrecog_visualizer
|
||||
:members:
|
||||
|
||||
Text Spotting Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.textspotting_visualizer
|
||||
:members:
|
||||
|
||||
KIE Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.kie_visualizer
|
||||
:members:
|
|
@ -0,0 +1,45 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.datasets
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.datasets
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.datasets
|
||||
|
||||
Datasets
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
OCRDataset
|
||||
WildReceiptDataset
|
||||
|
||||
Compatible Datasets
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
IcdarDataset
|
||||
RecogLMDBDataset
|
||||
RecogTextDataset
|
||||
|
||||
Dataset Wrapper
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ConcatDataset
|
|
@ -0,0 +1,22 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.engine
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.engine
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.engine.hooks
|
||||
|
||||
Hooks
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
VisualizationHook
|
|
@ -0,0 +1,57 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.evaluation
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.evaluation
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.evaluation.evaluator
|
||||
|
||||
Evaluator
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
MultiDatasetsEvaluator
|
||||
|
||||
.. currentmodule:: mmocr.evaluation.metrics
|
||||
|
||||
TextDet Metric
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
HmeanIOUMetric
|
||||
|
||||
TextRecog Metric
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
WordMetric
|
||||
CharMetric
|
||||
OneMinusNEDMetric
|
||||
|
||||
|
||||
KIE Metric
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
F1Metric
|
|
@ -0,0 +1,409 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.models
|
||||
===================================
|
||||
|
||||
- :mod:`~mmocr.models.common`
|
||||
|
||||
- :ref:`commombackbones`
|
||||
- :ref:`commomdictionary`
|
||||
- :ref:`commomlayers`
|
||||
- :ref:`commomlosses`
|
||||
- :ref:`commommodules`
|
||||
|
||||
- :mod:`~mmocr.models.textdet`
|
||||
|
||||
- :ref:`detdetectors`
|
||||
- :ref:`detdatapreprocessors`
|
||||
- :ref:`detnecks`
|
||||
- :ref:`detheads`
|
||||
- :ref:`detmodulelosses`
|
||||
- :ref:`detpostprocessors`
|
||||
|
||||
- :mod:`~mmocr.models.textrecog`
|
||||
|
||||
- :ref:`recrecognizers`
|
||||
- :ref:`recdatapreprocessors`
|
||||
- :ref:`recencoders`
|
||||
- :ref:`recdecoders`
|
||||
- :ref:`recmodulelosses`
|
||||
- :ref:`recpostprocessors`
|
||||
- :ref:`reclayers`
|
||||
|
||||
- :mod:`~mmocr.models.kie`
|
||||
|
||||
- :ref:`kieextractors`
|
||||
- :ref:`kieheads`
|
||||
- :ref:`kiemodulelosses`
|
||||
- :ref:`kiepostprocessors`
|
||||
|
||||
|
||||
.. module:: mmocr.models.common
|
||||
models.common
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.common
|
||||
|
||||
.. _commombackbones:
|
||||
|
||||
BackBones
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
UNet
|
||||
|
||||
.. _commomdictionary:
|
||||
|
||||
Dictionary
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
Dictionary
|
||||
|
||||
.. _commomlosses:
|
||||
|
||||
Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
MaskedBalancedBCEWithLogitsLoss
|
||||
MaskedDiceLoss
|
||||
MaskedSmoothL1Loss
|
||||
MaskedSquareDiceLoss
|
||||
MaskedBCEWithLogitsLoss
|
||||
SmoothL1Loss
|
||||
CrossEntropyLoss
|
||||
MaskedBalancedBCELoss
|
||||
MaskedBCELoss
|
||||
|
||||
.. _commomlayers:
|
||||
|
||||
Layers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TFEncoderLayer
|
||||
TFDecoderLayer
|
||||
|
||||
.. _commommodules:
|
||||
|
||||
Modules
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ScaledDotProductAttention
|
||||
MultiHeadAttention
|
||||
PositionwiseFeedForward
|
||||
PositionalEncoding
|
||||
|
||||
|
||||
.. module:: mmocr.models.textdet
|
||||
models.textdet
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.textdet
|
||||
|
||||
.. _detdetectors:
|
||||
|
||||
Detectors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SingleStageTextDetector
|
||||
DBNet
|
||||
PANet
|
||||
PSENet
|
||||
TextSnake
|
||||
FCENet
|
||||
DRRG
|
||||
MMDetWrapper
|
||||
|
||||
|
||||
.. _detdatapreprocessors:
|
||||
|
||||
Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TextDetDataPreprocessor
|
||||
|
||||
|
||||
.. _detnecks:
|
||||
|
||||
Necks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
FPEM_FFM
|
||||
FPNF
|
||||
FPNC
|
||||
FPN_UNet
|
||||
|
||||
|
||||
.. _detheads:
|
||||
|
||||
Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextDetHead
|
||||
PSEHead
|
||||
PANHead
|
||||
DBHead
|
||||
FCEHead
|
||||
TextSnakeHead
|
||||
DRRGHead
|
||||
|
||||
|
||||
.. _detmodulelosses:
|
||||
|
||||
Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SegBasedModuleLoss
|
||||
PANModuleLoss
|
||||
PSEModuleLoss
|
||||
DBModuleLoss
|
||||
TextSnakeModuleLoss
|
||||
FCEModuleLoss
|
||||
DRRGModuleLoss
|
||||
|
||||
|
||||
.. _detpostprocessors:
|
||||
|
||||
Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextDetPostProcessor
|
||||
PSEPostprocessor
|
||||
PANPostprocessor
|
||||
DBPostprocessor
|
||||
DRRGPostprocessor
|
||||
FCEPostprocessor
|
||||
TextSnakePostprocessor
|
||||
|
||||
|
||||
|
||||
.. module:: mmocr.models.textrecog
|
||||
models.textrecog
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.textrecog
|
||||
|
||||
.. _recrecognizers:
|
||||
|
||||
|
||||
Recognizers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseRecognizer
|
||||
EncoderDecoderRecognizer
|
||||
CRNN
|
||||
SARNet
|
||||
NRTR
|
||||
RobustScanner
|
||||
SATRN
|
||||
ABINet
|
||||
MASTER
|
||||
|
||||
.. _recdatapreprocessors:
|
||||
|
||||
Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TextRecogDataPreprocessor
|
||||
|
||||
|
||||
.. _recbackbones:
|
||||
|
||||
BackBones
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ResNet31OCR
|
||||
MiniVGG
|
||||
NRTRModalityTransform
|
||||
ShallowCNN
|
||||
ResNetABI
|
||||
ResNet
|
||||
MobileNetV2
|
||||
|
||||
|
||||
.. _recencoders:
|
||||
|
||||
Encoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SAREncoder
|
||||
NRTREncoder
|
||||
BaseEncoder
|
||||
ChannelReductionEncoder
|
||||
SATRNEncoder
|
||||
ABIEncoder
|
||||
|
||||
.. _recdecoders:
|
||||
|
||||
Decoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseDecoder
|
||||
ABILanguageDecoder
|
||||
ABIVisionDecoder
|
||||
ABIFuser
|
||||
CRNNDecoder
|
||||
ParallelSARDecoder
|
||||
SequentialSARDecoder
|
||||
ParallelSARDecoderWithBS
|
||||
NRTRDecoder
|
||||
SequenceAttentionDecoder
|
||||
PositionAttentionDecoder
|
||||
RobustScannerFuser
|
||||
MasterDecoder
|
||||
|
||||
.. _recmodulelosses:
|
||||
|
||||
Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextRecogModuleLoss
|
||||
CEModuleLoss
|
||||
CTCModuleLoss
|
||||
ABIModuleLoss
|
||||
|
||||
.. _recpostprocessors:
|
||||
|
||||
Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextRecogPostprocessor
|
||||
AttentionPostprocessor
|
||||
CTCPostProcessor
|
||||
|
||||
.. _reclayers:
|
||||
|
||||
Layers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BidirectionalLSTM
|
||||
Adaptive2DPositionalEncoding
|
||||
BasicBlock
|
||||
Bottleneck
|
||||
RobustScannerFusionLayer
|
||||
DotProductAttentionLayer
|
||||
PositionAwareLayer
|
||||
SATRNEncoderLayer
|
||||
|
||||
|
||||
.. module:: mmocr.models.kie
|
||||
models.kie
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.kie
|
||||
|
||||
.. _kieextractors:
|
||||
|
||||
Extractors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGR
|
||||
|
||||
.. _kieheads:
|
||||
|
||||
Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGRHead
|
||||
|
||||
.. _kiemodulelosses:
|
||||
|
||||
Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGRModuleLoss
|
||||
|
||||
.. _kiepostprocessors:
|
||||
|
||||
Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGRPostProcessor
|
|
@ -0,0 +1,15 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.structures
|
||||
===================================
|
||||
|
||||
.. currentmodule:: mmocr.structures
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TextDetDataSample
|
||||
TextRecogDataSample
|
||||
KIEDataSample
|
|
@ -0,0 +1,106 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.datasets
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.datasets.transforms
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.datasets.transforms
|
||||
|
||||
Loading
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
LoadImageFromFile
|
||||
LoadImageFromLMDB
|
||||
LoadOCRAnnotations
|
||||
LoadKIEAnnotations
|
||||
|
||||
|
||||
TextDet Transforms
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BoundedScaleAspectJitter
|
||||
FixInvalidPolygon
|
||||
RandomFlip
|
||||
SourceImagePad
|
||||
ShortScaleAspectJitter
|
||||
TextDetRandomCrop
|
||||
TextDetRandomCropFlip
|
||||
|
||||
|
||||
TextRecog Transforms
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
PyramidRescale
|
||||
PadToWidth
|
||||
RescaleToHeight
|
||||
|
||||
|
||||
OCR Transforms
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
RandomCrop
|
||||
RandomRotate
|
||||
Resize
|
||||
|
||||
|
||||
|
||||
Formatting
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
PackTextDetInputs
|
||||
PackTextRecogInputs
|
||||
PackKIEInputs
|
||||
|
||||
|
||||
Transform Wrapper
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ImgAugWrapper
|
||||
TorchVisionWrapper
|
||||
|
||||
|
||||
Adapter
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
MMDet2MMOCR
|
||||
MMOCR2MMDet
|
|
@ -0,0 +1,101 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.utils
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.utils
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.utils
|
||||
|
||||
Image Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
crop_img
|
||||
warp_img
|
||||
|
||||
|
||||
Box Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
bbox2poly
|
||||
bbox_center_distance
|
||||
bbox_diag_distance
|
||||
bezier2polygon
|
||||
is_on_same_line
|
||||
rescale_bboxes
|
||||
|
||||
stitch_boxes_into_lines
|
||||
|
||||
|
||||
Point Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
point_distance
|
||||
points_center
|
||||
|
||||
Polygon Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
boundary_iou
|
||||
crop_polygon
|
||||
is_poly_inside_rect
|
||||
offset_polygon
|
||||
poly2bbox
|
||||
poly2shapely
|
||||
poly_intersection
|
||||
poly_iou
|
||||
poly_make_valid
|
||||
poly_union
|
||||
polys2shapely
|
||||
rescale_polygon
|
||||
rescale_polygons
|
||||
shapely2poly
|
||||
sort_points
|
||||
sort_vertex
|
||||
sort_vertex8
|
||||
|
||||
|
||||
Mask Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
fill_hole
|
||||
|
||||
|
||||
Misc Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
equal_len
|
||||
is_2dlist
|
||||
is_3dlist
|
||||
is_none_or_type
|
||||
is_type_list
|
||||
|
||||
|
||||
Setup Env
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
register_all_modules
|
|
@ -0,0 +1,18 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.visualization
|
||||
===================================
|
||||
|
||||
.. currentmodule:: mmocr.visualization
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseLocalVisualizer
|
||||
TextDetLocalVisualizer
|
||||
TextRecogLocalVisualizer
|
||||
TextSpottingLocalVisualizer
|
||||
KIELocalVisualizer
|
|
@ -38,12 +38,20 @@ release = __version__
|
|||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
||||
# ones.
|
||||
extensions = [
|
||||
'sphinx.ext.autodoc', 'sphinx.ext.napoleon', 'sphinx.ext.viewcode',
|
||||
'sphinx_markdown_tables', 'sphinx_copybutton', 'myst_parser',
|
||||
'sphinx.ext.intersphinx', 'sphinx.ext.autodoc.typehints'
|
||||
'sphinx.ext.autodoc',
|
||||
'sphinx.ext.napoleon',
|
||||
'sphinx.ext.viewcode',
|
||||
'sphinx_markdown_tables',
|
||||
'sphinx_copybutton',
|
||||
'myst_parser',
|
||||
'sphinx.ext.intersphinx',
|
||||
'sphinx.ext.autodoc.typehints',
|
||||
'sphinx.ext.autosummary',
|
||||
'sphinx.ext.autosectionlabel',
|
||||
]
|
||||
autodoc_typehints = 'description'
|
||||
autodoc_mock_imports = ['mmcv._ext']
|
||||
autosummary_generate = True # Turn on sphinx.ext.autosummary
|
||||
|
||||
# Ignore >>> when copying code
|
||||
copybutton_prompt_text = r'>>> |\.\.\. '
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
[html writers]
|
||||
table_style: colwidths-auto
|
|
@ -77,7 +77,14 @@ You can switch between English and Chinese in the lower-left corner of the layou
|
|||
:maxdepth: 1
|
||||
:caption: API Reference
|
||||
|
||||
api.rst
|
||||
mmocr.structures <api/structures>
|
||||
mmocr.datasets <api/datasets>
|
||||
mmocr.transforms <api/transforms>
|
||||
mmocr.models <api/models>
|
||||
mmocr.evaluation <api/evaluation>
|
||||
mmocr.visualization <api/visualization>
|
||||
mmocr.engine <api/engine>
|
||||
mmocr.utils <api/utils>
|
||||
|
||||
.. toctree::
|
||||
:caption: Switch Language
|
||||
|
|
|
@ -0,0 +1,14 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
.. currentmodule:: {{ module }}
|
||||
|
||||
|
||||
{{ name | underline}}
|
||||
|
||||
.. autoclass:: {{ name }}
|
||||
:members:
|
||||
|
||||
|
||||
..
|
||||
autogenerated from source/_templates/classtemplate.rst
|
||||
note it does not have :inherited-members:
|
|
@ -1,252 +0,0 @@
|
|||
mmocr.datasets
|
||||
---------------------------------------------
|
||||
.. automodule:: mmocr.datasets
|
||||
:members:
|
||||
|
||||
Dataset Types
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.datasets.ocr_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.icdar_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.recog_lmdb_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.recog_text_dataset
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.datasets.wildreceipt_dataset
|
||||
:members:
|
||||
|
||||
Transforms
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.datasets.transforms
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.engine
|
||||
---------------------------------------------
|
||||
Hooks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.engine.hooks
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.evaluation
|
||||
---------------------------------------------
|
||||
Evaluator
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.evaluation.evaluator
|
||||
:members:
|
||||
|
||||
Functional
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.evaluation.functional
|
||||
:members:
|
||||
|
||||
Metric
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.evaluation.metrics
|
||||
:members:
|
||||
|
||||
mmocr.utils
|
||||
---------------------------------------------
|
||||
Point utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.utils.point_utils
|
||||
:members:
|
||||
|
||||
Bbox utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.utils.bbox_utils
|
||||
:members:
|
||||
|
||||
Polygon utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.polygon_utils
|
||||
:members:
|
||||
|
||||
Mask utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.mask_utils
|
||||
:members:
|
||||
|
||||
String utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.string_utils
|
||||
:members:
|
||||
|
||||
Image utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.img_utils
|
||||
:members:
|
||||
|
||||
File IO utils
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.fileio
|
||||
:members:
|
||||
|
||||
Others
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. automodule:: mmocr.utils.data_converter_utils
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.utils.parsers
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.models
|
||||
---------------------------------------------
|
||||
Common
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.common.backbones
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.losses
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.dictionary
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.layers
|
||||
:members:
|
||||
|
||||
.. automodule:: mmocr.models.common.modules
|
||||
:members:
|
||||
|
||||
Text Detection Detectors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.detectors
|
||||
:members:
|
||||
|
||||
Text Detection Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.heads
|
||||
:members:
|
||||
|
||||
Text Detection Necks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.necks
|
||||
:members:
|
||||
|
||||
Text Detection Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.module_losses
|
||||
:members:
|
||||
|
||||
Text Detection Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.data_preprocessors
|
||||
:members:
|
||||
|
||||
Text Detection Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textdet.postprocessors
|
||||
:members:
|
||||
|
||||
Text Recognition Recognizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.recognizers
|
||||
:members:
|
||||
|
||||
Text Recognition Backbones
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.backbones
|
||||
:members:
|
||||
|
||||
Text Recognition Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.data_preprocessors
|
||||
:members:
|
||||
|
||||
Text Recognition Layers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.layers
|
||||
:members:
|
||||
|
||||
Text Recognition Plugins
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.plugins
|
||||
:members:
|
||||
|
||||
Text Recognition Encoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.encoders
|
||||
:members:
|
||||
|
||||
Text Recognition Decoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.decoders
|
||||
:members:
|
||||
|
||||
Text Recognition Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.textrecog.module_losses
|
||||
:members:
|
||||
|
||||
KIE Extractors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.kie.extractors
|
||||
:members:
|
||||
|
||||
KIE Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.kie.heads
|
||||
:members:
|
||||
|
||||
KIE Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.models.kie.module_losses
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.structures
|
||||
---------------------------------------------
|
||||
|
||||
Text Detection Data Sample
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.structures.textdet_data_sample
|
||||
:members:
|
||||
|
||||
Text Recognition Data Sample
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.structures.textrecog_data_sample
|
||||
:members:
|
||||
|
||||
KIE Data Sample
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.structures.kie_data_sample
|
||||
:members:
|
||||
|
||||
|
||||
mmocr.visualization
|
||||
---------------------------------------------
|
||||
|
||||
Text Detection Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.textdet_visualizer
|
||||
:members:
|
||||
|
||||
Text Recognition Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.textrecog_visualizer
|
||||
:members:
|
||||
|
||||
Text Spotting Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.textspotting_visualizer
|
||||
:members:
|
||||
|
||||
KIE Visualizer
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. automodule:: mmocr.visualization.kie_visualizer
|
||||
:members:
|
|
@ -0,0 +1,45 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.datasets
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.datasets
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.datasets
|
||||
|
||||
Datasets
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
OCRDataset
|
||||
WildReceiptDataset
|
||||
|
||||
Compatible Datasets
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
IcdarDataset
|
||||
RecogLMDBDataset
|
||||
RecogTextDataset
|
||||
|
||||
Dataset Wrapper
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ConcatDataset
|
|
@ -0,0 +1,22 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.engine
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.engine
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.engine.hooks
|
||||
|
||||
Hooks
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
VisualizationHook
|
|
@ -0,0 +1,57 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.evaluation
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.evaluation
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.evaluation.evaluator
|
||||
|
||||
Evaluator
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
MultiDatasetsEvaluator
|
||||
|
||||
.. currentmodule:: mmocr.evaluation.metrics
|
||||
|
||||
TextDet Metric
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
HmeanIOUMetric
|
||||
|
||||
TextRecog Metric
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
WordMetric
|
||||
CharMetric
|
||||
OneMinusNEDMetric
|
||||
|
||||
|
||||
KIE Metric
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
F1Metric
|
|
@ -0,0 +1,409 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.models
|
||||
===================================
|
||||
|
||||
- :mod:`~mmocr.models.common`
|
||||
|
||||
- :ref:`commombackbones`
|
||||
- :ref:`commomdictionary`
|
||||
- :ref:`commomlayers`
|
||||
- :ref:`commomlosses`
|
||||
- :ref:`commommodules`
|
||||
|
||||
- :mod:`~mmocr.models.textdet`
|
||||
|
||||
- :ref:`detdetectors`
|
||||
- :ref:`detdatapreprocessors`
|
||||
- :ref:`detnecks`
|
||||
- :ref:`detheads`
|
||||
- :ref:`detmodulelosses`
|
||||
- :ref:`detpostprocessors`
|
||||
|
||||
- :mod:`~mmocr.models.textrecog`
|
||||
|
||||
- :ref:`recrecognizers`
|
||||
- :ref:`recdatapreprocessors`
|
||||
- :ref:`recencoders`
|
||||
- :ref:`recdecoders`
|
||||
- :ref:`recmodulelosses`
|
||||
- :ref:`recpostprocessors`
|
||||
- :ref:`reclayers`
|
||||
|
||||
- :mod:`~mmocr.models.kie`
|
||||
|
||||
- :ref:`kieextractors`
|
||||
- :ref:`kieheads`
|
||||
- :ref:`kiemodulelosses`
|
||||
- :ref:`kiepostprocessors`
|
||||
|
||||
|
||||
.. module:: mmocr.models.common
|
||||
models.common
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.common
|
||||
|
||||
.. _commombackbones:
|
||||
|
||||
BackBones
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
UNet
|
||||
|
||||
.. _commomdictionary:
|
||||
|
||||
Dictionary
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
Dictionary
|
||||
|
||||
.. _commomlosses:
|
||||
|
||||
Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
MaskedBalancedBCEWithLogitsLoss
|
||||
MaskedDiceLoss
|
||||
MaskedSmoothL1Loss
|
||||
MaskedSquareDiceLoss
|
||||
MaskedBCEWithLogitsLoss
|
||||
SmoothL1Loss
|
||||
CrossEntropyLoss
|
||||
MaskedBalancedBCELoss
|
||||
MaskedBCELoss
|
||||
|
||||
.. _commomlayers:
|
||||
|
||||
Layers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TFEncoderLayer
|
||||
TFDecoderLayer
|
||||
|
||||
.. _commommodules:
|
||||
|
||||
Modules
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ScaledDotProductAttention
|
||||
MultiHeadAttention
|
||||
PositionwiseFeedForward
|
||||
PositionalEncoding
|
||||
|
||||
|
||||
.. module:: mmocr.models.textdet
|
||||
models.textdet
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.textdet
|
||||
|
||||
.. _detdetectors:
|
||||
|
||||
Detectors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SingleStageTextDetector
|
||||
DBNet
|
||||
PANet
|
||||
PSENet
|
||||
TextSnake
|
||||
FCENet
|
||||
DRRG
|
||||
MMDetWrapper
|
||||
|
||||
|
||||
.. _detdatapreprocessors:
|
||||
|
||||
Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TextDetDataPreprocessor
|
||||
|
||||
|
||||
.. _detnecks:
|
||||
|
||||
Necks
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
FPEM_FFM
|
||||
FPNF
|
||||
FPNC
|
||||
FPN_UNet
|
||||
|
||||
|
||||
.. _detheads:
|
||||
|
||||
Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextDetHead
|
||||
PSEHead
|
||||
PANHead
|
||||
DBHead
|
||||
FCEHead
|
||||
TextSnakeHead
|
||||
DRRGHead
|
||||
|
||||
|
||||
.. _detmodulelosses:
|
||||
|
||||
Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SegBasedModuleLoss
|
||||
PANModuleLoss
|
||||
PSEModuleLoss
|
||||
DBModuleLoss
|
||||
TextSnakeModuleLoss
|
||||
FCEModuleLoss
|
||||
DRRGModuleLoss
|
||||
|
||||
|
||||
.. _detpostprocessors:
|
||||
|
||||
Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextDetPostProcessor
|
||||
PSEPostprocessor
|
||||
PANPostprocessor
|
||||
DBPostprocessor
|
||||
DRRGPostprocessor
|
||||
FCEPostprocessor
|
||||
TextSnakePostprocessor
|
||||
|
||||
|
||||
|
||||
.. module:: mmocr.models.textrecog
|
||||
models.textrecog
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.textrecog
|
||||
|
||||
.. _recrecognizers:
|
||||
|
||||
|
||||
Recognizers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseRecognizer
|
||||
EncoderDecoderRecognizer
|
||||
CRNN
|
||||
SARNet
|
||||
NRTR
|
||||
RobustScanner
|
||||
SATRN
|
||||
ABINet
|
||||
MASTER
|
||||
|
||||
.. _recdatapreprocessors:
|
||||
|
||||
Data Preprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TextRecogDataPreprocessor
|
||||
|
||||
|
||||
.. _recbackbones:
|
||||
|
||||
BackBones
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ResNet31OCR
|
||||
MiniVGG
|
||||
NRTRModalityTransform
|
||||
ShallowCNN
|
||||
ResNetABI
|
||||
ResNet
|
||||
MobileNetV2
|
||||
|
||||
|
||||
.. _recencoders:
|
||||
|
||||
Encoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SAREncoder
|
||||
NRTREncoder
|
||||
BaseEncoder
|
||||
ChannelReductionEncoder
|
||||
SATRNEncoder
|
||||
ABIEncoder
|
||||
|
||||
.. _recdecoders:
|
||||
|
||||
Decoders
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseDecoder
|
||||
ABILanguageDecoder
|
||||
ABIVisionDecoder
|
||||
ABIFuser
|
||||
CRNNDecoder
|
||||
ParallelSARDecoder
|
||||
SequentialSARDecoder
|
||||
ParallelSARDecoderWithBS
|
||||
NRTRDecoder
|
||||
SequenceAttentionDecoder
|
||||
PositionAttentionDecoder
|
||||
RobustScannerFuser
|
||||
MasterDecoder
|
||||
|
||||
.. _recmodulelosses:
|
||||
|
||||
Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextRecogModuleLoss
|
||||
CEModuleLoss
|
||||
CTCModuleLoss
|
||||
ABIModuleLoss
|
||||
|
||||
.. _recpostprocessors:
|
||||
|
||||
Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseTextRecogPostprocessor
|
||||
AttentionPostprocessor
|
||||
CTCPostProcessor
|
||||
|
||||
.. _reclayers:
|
||||
|
||||
Layers
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BidirectionalLSTM
|
||||
Adaptive2DPositionalEncoding
|
||||
BasicBlock
|
||||
Bottleneck
|
||||
RobustScannerFusionLayer
|
||||
DotProductAttentionLayer
|
||||
PositionAwareLayer
|
||||
SATRNEncoderLayer
|
||||
|
||||
|
||||
.. module:: mmocr.models.kie
|
||||
models.kie
|
||||
---------------------------------------------
|
||||
.. currentmodule:: mmocr.models.kie
|
||||
|
||||
.. _kieextractors:
|
||||
|
||||
Extractors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGR
|
||||
|
||||
.. _kieheads:
|
||||
|
||||
Heads
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGRHead
|
||||
|
||||
.. _kiemodulelosses:
|
||||
|
||||
Module Losses
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGRModuleLoss
|
||||
|
||||
.. _kiepostprocessors:
|
||||
|
||||
Postprocessors
|
||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
SDMGRPostProcessor
|
|
@ -0,0 +1,15 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.structures
|
||||
===================================
|
||||
|
||||
.. currentmodule:: mmocr.structures
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
TextDetDataSample
|
||||
TextRecogDataSample
|
||||
KIEDataSample
|
|
@ -0,0 +1,106 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.datasets
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.datasets.transforms
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.datasets.transforms
|
||||
|
||||
Loading
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
LoadImageFromFile
|
||||
LoadImageFromLMDB
|
||||
LoadOCRAnnotations
|
||||
LoadKIEAnnotations
|
||||
|
||||
|
||||
TextDet Transforms
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BoundedScaleAspectJitter
|
||||
FixInvalidPolygon
|
||||
RandomFlip
|
||||
SourceImagePad
|
||||
ShortScaleAspectJitter
|
||||
TextDetRandomCrop
|
||||
TextDetRandomCropFlip
|
||||
|
||||
|
||||
TextRecog Transforms
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
PyramidRescale
|
||||
PadToWidth
|
||||
RescaleToHeight
|
||||
|
||||
|
||||
OCR Transforms
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
RandomCrop
|
||||
RandomRotate
|
||||
Resize
|
||||
|
||||
|
||||
|
||||
Formatting
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
PackTextDetInputs
|
||||
PackTextRecogInputs
|
||||
PackKIEInputs
|
||||
|
||||
|
||||
Transform Wrapper
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
ImgAugWrapper
|
||||
TorchVisionWrapper
|
||||
|
||||
|
||||
Adapter
|
||||
---------------------------------------------
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
MMDet2MMOCR
|
||||
MMOCR2MMDet
|
|
@ -0,0 +1,101 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.utils
|
||||
===================================
|
||||
|
||||
.. contents:: mmocr.utils
|
||||
:depth: 2
|
||||
:local:
|
||||
:backlinks: top
|
||||
|
||||
.. currentmodule:: mmocr.utils
|
||||
|
||||
Image Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
crop_img
|
||||
warp_img
|
||||
|
||||
|
||||
Box Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
bbox2poly
|
||||
bbox_center_distance
|
||||
bbox_diag_distance
|
||||
bezier2polygon
|
||||
is_on_same_line
|
||||
rescale_bboxes
|
||||
|
||||
stitch_boxes_into_lines
|
||||
|
||||
|
||||
Point Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
point_distance
|
||||
points_center
|
||||
|
||||
Polygon Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
boundary_iou
|
||||
crop_polygon
|
||||
is_poly_inside_rect
|
||||
offset_polygon
|
||||
poly2bbox
|
||||
poly2shapely
|
||||
poly_intersection
|
||||
poly_iou
|
||||
poly_make_valid
|
||||
poly_union
|
||||
polys2shapely
|
||||
rescale_polygon
|
||||
rescale_polygons
|
||||
shapely2poly
|
||||
sort_points
|
||||
sort_vertex
|
||||
sort_vertex8
|
||||
|
||||
|
||||
Mask Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
fill_hole
|
||||
|
||||
|
||||
Misc Utils
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
equal_len
|
||||
is_2dlist
|
||||
is_3dlist
|
||||
is_none_or_type
|
||||
is_type_list
|
||||
|
||||
|
||||
Setup Env
|
||||
---------------------------------------------
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
|
||||
register_all_modules
|
|
@ -0,0 +1,18 @@
|
|||
.. role:: hidden
|
||||
:class: hidden-section
|
||||
|
||||
mmocr.visualization
|
||||
===================================
|
||||
|
||||
.. currentmodule:: mmocr.visualization
|
||||
|
||||
.. autosummary::
|
||||
:toctree: generated
|
||||
:nosignatures:
|
||||
:template: classtemplate.rst
|
||||
|
||||
BaseLocalVisualizer
|
||||
TextDetLocalVisualizer
|
||||
TextRecogLocalVisualizer
|
||||
TextSpottingLocalVisualizer
|
||||
KIELocalVisualizer
|
|
@ -38,14 +38,21 @@ release = __version__
|
|||
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
||||
# ones.
|
||||
extensions = [
|
||||
'sphinx.ext.autodoc', 'sphinx.ext.napoleon', 'sphinx.ext.viewcode',
|
||||
'sphinx_markdown_tables', 'sphinx_copybutton', 'myst_parser',
|
||||
'sphinx.ext.intersphinx', 'sphinx.ext.autodoc.typehints'
|
||||
'sphinx.ext.autodoc',
|
||||
'sphinx.ext.napoleon',
|
||||
'sphinx.ext.viewcode',
|
||||
'sphinx_markdown_tables',
|
||||
'sphinx_copybutton',
|
||||
'myst_parser',
|
||||
'sphinx.ext.intersphinx',
|
||||
'sphinx.ext.autodoc.typehints',
|
||||
'sphinx.ext.autosummary',
|
||||
'sphinx.ext.autosectionlabel',
|
||||
]
|
||||
autodoc_typehints = 'description'
|
||||
|
||||
autodoc_mock_imports = ['mmcv._ext']
|
||||
|
||||
autosummary_generate = True # Turn on sphinx.ext.autosummary
|
||||
# Ignore >>> when copying code
|
||||
copybutton_prompt_text = r'>>> |\.\.\. '
|
||||
copybutton_prompt_is_regexp = True
|
||||
|
|
|
@ -0,0 +1,2 @@
|
|||
[html writers]
|
||||
table_style: colwidths-auto
|
|
@ -74,10 +74,17 @@
|
|||
notes/faq.md
|
||||
|
||||
.. toctree::
|
||||
:maxdepth: 1
|
||||
:maxdepth: 2
|
||||
:caption: API 文档
|
||||
|
||||
api.rst
|
||||
mmocr.structures <api/structures>
|
||||
mmocr.datasets <api/datasets>
|
||||
mmocr.transforms <api/transforms>
|
||||
mmocr.models <api/models>
|
||||
mmocr.evaluation <api/evaluation>
|
||||
mmocr.visualization <api/visualization>
|
||||
mmocr.engine <api/engine>
|
||||
mmocr.utils <api/utils>
|
||||
|
||||
.. toctree::
|
||||
:caption: 切换语言
|
||||
|
|
|
@ -3,6 +3,7 @@ from .backbones import * # NOQA
|
|||
from .data_preprocessors import * # NOQA
|
||||
from .decoders import * # NOQA
|
||||
from .encoders import * # NOQA
|
||||
from .layers import * # NOQA
|
||||
from .module_losses import * # NOQA
|
||||
from .plugins import * # NOQA
|
||||
from .postprocessors import * # NOQA
|
||||
|
|
|
@ -227,6 +227,7 @@ def poly_union(
|
|||
return_poly: bool = False
|
||||
) -> Tuple[float, Optional[Union[Polygon, MultiPolygon]]]:
|
||||
"""Calculate the union area between two polygons.
|
||||
|
||||
Args:
|
||||
poly_a (Polygon): Polygon a.
|
||||
poly_b (Polygon): Polygon b.
|
||||
|
|
Loading…
Reference in New Issue