-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Doc] Refine MMSegmentation documentation (#2668)
- Loading branch information
Showing
31 changed files
with
294 additions
and
1,085 deletions.
There are no files selected for viewing
2 changes: 1 addition & 1 deletion
2
docs/en/advanced_guides/add_dataset.md → docs/en/advanced_guides/add_datasets.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Add New Datasets | ||
# \[WIP\] Add New Datasets | ||
|
||
## Customize datasets by reorganizing data | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# Add New Metrics |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Adding New Data Transforms | ||
|
||
## Customization data transformation | ||
|
||
The customized data transformation must inherited from `BaseTransform` and implement `transform` function. | ||
Here we use a simple flipping transformation as example: | ||
|
||
```python | ||
import random | ||
import mmcv | ||
from mmcv.transforms import BaseTransform, TRANSFORMS | ||
|
||
@TRANSFORMS.register_module() | ||
class MyFlip(BaseTransform): | ||
def __init__(self, direction: str): | ||
super().__init__() | ||
self.direction = direction | ||
|
||
def transform(self, results: dict) -> dict: | ||
img = results['img'] | ||
results['img'] = mmcv.imflip(img, direction=self.direction) | ||
return results | ||
``` | ||
|
||
Moreover, import the new class. | ||
|
||
```python | ||
from .my_pipeline import MyFlip | ||
``` | ||
|
||
Thus, we can instantiate a `MyFlip` object and use it to process the data dict. | ||
|
||
```python | ||
import numpy as np | ||
|
||
transform = MyFlip(direction='horizontal') | ||
data_dict = {'img': np.random.rand(224, 224, 3)} | ||
data_dict = transform(data_dict) | ||
processed_img = data_dict['img'] | ||
``` | ||
|
||
Or, we can use `MyFlip` transformation in data pipeline in our config file. | ||
|
||
```python | ||
pipeline = [ | ||
... | ||
dict(type='MyFlip', direction='horizontal'), | ||
... | ||
] | ||
``` | ||
|
||
Note that if you want to use `MyFlip` in config, you must ensure the file containing `MyFlip` is imported during runtime. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Training Tricks | ||
# \[WIP\] Training Tricks | ||
|
||
MMSegmentation support following training tricks out of box. | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,102 @@ | ||
# Model Zoo Statistics | ||
|
||
- Number of papers: 47 | ||
|
||
- ALGORITHM: 36 | ||
- BACKBONE: 11 | ||
|
||
- Number of checkpoints: 612 | ||
|
||
- \[ALGORITHM\] [ANN](https:/open-mmlab/mmsegmentation/blob/master/configs/ann) (16 ckpts) | ||
|
||
- \[ALGORITHM\] [APCNet](https:/open-mmlab/mmsegmentation/blob/master/configs/apcnet) (12 ckpts) | ||
|
||
- \[BACKBONE\] [BEiT](https:/open-mmlab/mmsegmentation/blob/master/configs/beit) (2 ckpts) | ||
|
||
- \[ALGORITHM\] [BiSeNetV1](https:/open-mmlab/mmsegmentation/blob/master/configs/bisenetv1) (11 ckpts) | ||
|
||
- \[ALGORITHM\] [BiSeNetV2](https:/open-mmlab/mmsegmentation/blob/master/configs/bisenetv2) (4 ckpts) | ||
|
||
- \[ALGORITHM\] [CCNet](https:/open-mmlab/mmsegmentation/blob/master/configs/ccnet) (16 ckpts) | ||
|
||
- \[ALGORITHM\] [CGNet](https:/open-mmlab/mmsegmentation/blob/master/configs/cgnet) (2 ckpts) | ||
|
||
- \[BACKBONE\] [ConvNeXt](https:/open-mmlab/mmsegmentation/blob/master/configs/convnext) (6 ckpts) | ||
|
||
- \[ALGORITHM\] [DANet](https:/open-mmlab/mmsegmentation/blob/master/configs/danet) (16 ckpts) | ||
|
||
- \[ALGORITHM\] [DeepLabV3](https:/open-mmlab/mmsegmentation/blob/master/configs/deeplabv3) (41 ckpts) | ||
|
||
- \[ALGORITHM\] [DeepLabV3+](https:/open-mmlab/mmsegmentation/blob/master/configs/deeplabv3plus) (42 ckpts) | ||
|
||
- \[ALGORITHM\] [DMNet](https:/open-mmlab/mmsegmentation/blob/master/configs/dmnet) (12 ckpts) | ||
|
||
- \[ALGORITHM\] [DNLNet](https:/open-mmlab/mmsegmentation/blob/master/configs/dnlnet) (12 ckpts) | ||
|
||
- \[ALGORITHM\] [DPT](https:/open-mmlab/mmsegmentation/blob/master/configs/dpt) (1 ckpts) | ||
|
||
- \[ALGORITHM\] [EMANet](https:/open-mmlab/mmsegmentation/blob/master/configs/emanet) (4 ckpts) | ||
|
||
- \[ALGORITHM\] [EncNet](https:/open-mmlab/mmsegmentation/blob/master/configs/encnet) (12 ckpts) | ||
|
||
- \[ALGORITHM\] [ERFNet](https:/open-mmlab/mmsegmentation/blob/master/configs/erfnet) (1 ckpts) | ||
|
||
- \[ALGORITHM\] [FastFCN](https:/open-mmlab/mmsegmentation/blob/master/configs/fastfcn) (12 ckpts) | ||
|
||
- \[ALGORITHM\] [Fast-SCNN](https:/open-mmlab/mmsegmentation/blob/master/configs/fastscnn) (1 ckpts) | ||
|
||
- \[ALGORITHM\] [FCN](https:/open-mmlab/mmsegmentation/blob/master/configs/fcn) (41 ckpts) | ||
|
||
- \[ALGORITHM\] [GCNet](https:/open-mmlab/mmsegmentation/blob/master/configs/gcnet) (16 ckpts) | ||
|
||
- \[BACKBONE\] [HRNet](https:/open-mmlab/mmsegmentation/blob/master/configs/hrnet) (37 ckpts) | ||
|
||
- \[ALGORITHM\] [ICNet](https:/open-mmlab/mmsegmentation/blob/master/configs/icnet) (12 ckpts) | ||
|
||
- \[ALGORITHM\] [ISANet](https:/open-mmlab/mmsegmentation/blob/master/configs/isanet) (16 ckpts) | ||
|
||
- \[ALGORITHM\] [K-Net](https:/open-mmlab/mmsegmentation/blob/master/configs/knet) (7 ckpts) | ||
|
||
- \[BACKBONE\] [MAE](https:/open-mmlab/mmsegmentation/blob/master/configs/mae) (1 ckpts) | ||
|
||
- \[ALGORITHM\] [Mask2Former](https:/open-mmlab/mmsegmentation/blob/master/configs/mask2former) (13 ckpts) | ||
|
||
- \[ALGORITHM\] [MaskFormer](https:/open-mmlab/mmsegmentation/blob/master/configs/maskformer) (4 ckpts) | ||
|
||
- \[BACKBONE\] [MobileNetV2](https:/open-mmlab/mmsegmentation/blob/master/configs/mobilenet_v2) (8 ckpts) | ||
|
||
- \[BACKBONE\] [MobileNetV3](https:/open-mmlab/mmsegmentation/blob/master/configs/mobilenet_v3) (4 ckpts) | ||
|
||
- \[ALGORITHM\] [NonLocal Net](https:/open-mmlab/mmsegmentation/blob/master/configs/nonlocal_net) (16 ckpts) | ||
|
||
- \[ALGORITHM\] [OCRNet](https:/open-mmlab/mmsegmentation/blob/master/configs/ocrnet) (24 ckpts) | ||
|
||
- \[ALGORITHM\] [PointRend](https:/open-mmlab/mmsegmentation/blob/master/configs/point_rend) (4 ckpts) | ||
|
||
- \[BACKBONE\] [PoolFormer](https:/open-mmlab/mmsegmentation/blob/master/configs/poolformer) (5 ckpts) | ||
|
||
- \[ALGORITHM\] [PSANet](https:/open-mmlab/mmsegmentation/blob/master/configs/psanet) (16 ckpts) | ||
|
||
- \[ALGORITHM\] [PSPNet](https:/open-mmlab/mmsegmentation/blob/master/configs/pspnet) (54 ckpts) | ||
|
||
- \[BACKBONE\] [ResNeSt](https:/open-mmlab/mmsegmentation/blob/master/configs/resnest) (8 ckpts) | ||
|
||
- \[ALGORITHM\] [SegFormer](https:/open-mmlab/mmsegmentation/blob/master/configs/segformer) (13 ckpts) | ||
|
||
- \[ALGORITHM\] [Segmenter](https:/open-mmlab/mmsegmentation/blob/master/configs/segmenter) (5 ckpts) | ||
|
||
- \[ALGORITHM\] [Semantic FPN](https:/open-mmlab/mmsegmentation/blob/master/configs/sem_fpn) (4 ckpts) | ||
|
||
- \[ALGORITHM\] [SETR](https:/open-mmlab/mmsegmentation/blob/master/configs/setr) (7 ckpts) | ||
|
||
- \[ALGORITHM\] [STDC](https:/open-mmlab/mmsegmentation/blob/master/configs/stdc) (4 ckpts) | ||
|
||
- \[BACKBONE\] [Swin Transformer](https:/open-mmlab/mmsegmentation/blob/master/configs/swin) (6 ckpts) | ||
|
||
- \[BACKBONE\] [Twins](https:/open-mmlab/mmsegmentation/blob/master/configs/twins) (12 ckpts) | ||
|
||
- \[ALGORITHM\] [UNet](https:/open-mmlab/mmsegmentation/blob/master/configs/unet) (25 ckpts) | ||
|
||
- \[ALGORITHM\] [UPerNet](https:/open-mmlab/mmsegmentation/blob/master/configs/upernet) (16 ckpts) | ||
|
||
- \[BACKBONE\] [Vision Transformer](https:/open-mmlab/mmsegmentation/blob/master/configs/vit) (11 ckpts) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# 自定义数据集(待更新) | ||
# 新增自定义数据集(待更新) | ||
|
||
## 通过重新组织数据来定制数据集 | ||
|
||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
# 新增评测指标 (待更新) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# 新增模块(待更新) | ||
|
||
中文版文档支持中,请先阅读[英文版本](../../en/advanced_guides/add_models.md) |
Oops, something went wrong.