From 37eaefb0f39f35ea962c85bec7e2505411869d81 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Fri, 18 Feb 2022 18:41:20 +0800 Subject: [PATCH 01/10] fix ocrnet cascade decoder --- mmdeploy/codebase/mmseg/models/segmentors/encoder_decoder.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/mmdeploy/codebase/mmseg/models/segmentors/encoder_decoder.py b/mmdeploy/codebase/mmseg/models/segmentors/encoder_decoder.py index b50778e461..bca614ae86 100644 --- a/mmdeploy/codebase/mmseg/models/segmentors/encoder_decoder.py +++ b/mmdeploy/codebase/mmseg/models/segmentors/encoder_decoder.py @@ -24,8 +24,7 @@ def encoder_decoder__simple_test(ctx, self, img, img_meta, **kwargs): Returns: torch.Tensor: Output segmentation map pf shape [N, 1, H, W]. """ - x = self.extract_feat(img) - seg_logit = self._decode_head_forward_test(x, img_meta) + seg_logit = self.encode_decode(img, img_meta) seg_logit = resize( input=seg_logit, size=img_meta['img_shape'], From 5ee9a9ca95e21425425cd0e7e10f220036ae33d6 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Fri, 18 Feb 2022 19:21:15 +0800 Subject: [PATCH 02/10] update mmseg support models --- docs/en/codebases/mmseg.md | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/docs/en/codebases/mmseg.md b/docs/en/codebases/mmseg.md index 30bbba2082..709825c391 100644 --- a/docs/en/codebases/mmseg.md +++ b/docs/en/codebases/mmseg.md @@ -16,6 +16,31 @@ Please refer to [get_started.md](https://github.com/open-mmlab/mmsegmentation/bl | DeepLabV3+ | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/deeplabv3plus) | | Fast-SCNN[*](#static_shape) | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/fastscnn) | | UNet[*](#static_shape) | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/unet) | +| ANN | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| APCNet | Y | Y | N | Y | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| BiSeNetV1 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| BiSeNetV2 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| CCNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| CGNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| DMNet | Y | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| DNLNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| EMANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| EncNet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| ERFNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| FastFCN | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| GCNet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| ICNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| ISANet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| NonLocal Net | Y | N | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| OCRNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| PointRend | Y | N | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| PSANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| SegFormer | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| Semantic FPN | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| STDC1 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| STDC2 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | +| UPerNet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | + ### Reminder From c1064a94dcd5ce735b740d3e5e32920cef8ad8d9 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Tue, 22 Feb 2022 20:00:41 +0800 Subject: [PATCH 03/10] update mmseg configs --- configs/mmseg/segmentation_ncnn_static.py | 3 --- .../segmentation_onnxruntime_static-1024x2048.py | 3 +++ ...y => segmentation_onnxruntime_static-512x512.py} | 2 +- .../mmseg/segmentation_openvino_static-512x512.py | 4 ++++ .../segmentation_tensorrt-fp16_static-512x512.py | 13 +++++++++++++ .../mmseg/segmentation_tensorrt_static-512x512.py | 13 +++++++++++++ 6 files changed, 34 insertions(+), 4 deletions(-) delete mode 100644 configs/mmseg/segmentation_ncnn_static.py create mode 100644 configs/mmseg/segmentation_onnxruntime_static-1024x2048.py rename configs/mmseg/{segmentation_onnxruntime_static.py => segmentation_onnxruntime_static-512x512.py} (63%) create mode 100644 configs/mmseg/segmentation_openvino_static-512x512.py create mode 100644 configs/mmseg/segmentation_tensorrt-fp16_static-512x512.py create mode 100644 configs/mmseg/segmentation_tensorrt_static-512x512.py diff --git a/configs/mmseg/segmentation_ncnn_static.py b/configs/mmseg/segmentation_ncnn_static.py deleted file mode 100644 index 985542b5bf..0000000000 --- a/configs/mmseg/segmentation_ncnn_static.py +++ /dev/null @@ -1,3 +0,0 @@ -_base_ = ['./segmentation_static.py', '../_base_/backends/ncnn.py'] - -onnx_config = dict(input_shape=None) diff --git a/configs/mmseg/segmentation_onnxruntime_static-1024x2048.py b/configs/mmseg/segmentation_onnxruntime_static-1024x2048.py new file mode 100644 index 0000000000..2587a015f4 --- /dev/null +++ b/configs/mmseg/segmentation_onnxruntime_static-1024x2048.py @@ -0,0 +1,3 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/onnxruntime.py'] + +onnx_config = dict(input_shape=[2048, 1024]) diff --git a/configs/mmseg/segmentation_onnxruntime_static.py b/configs/mmseg/segmentation_onnxruntime_static-512x512.py similarity index 63% rename from configs/mmseg/segmentation_onnxruntime_static.py rename to configs/mmseg/segmentation_onnxruntime_static-512x512.py index 802eb08a4d..03d919d7b0 100644 --- a/configs/mmseg/segmentation_onnxruntime_static.py +++ b/configs/mmseg/segmentation_onnxruntime_static-512x512.py @@ -1,3 +1,3 @@ _base_ = ['./segmentation_static.py', '../_base_/backends/onnxruntime.py'] -onnx_config = dict(input_shape=None) +onnx_config = dict(input_shape=[512, 512]) diff --git a/configs/mmseg/segmentation_openvino_static-512x512.py b/configs/mmseg/segmentation_openvino_static-512x512.py new file mode 100644 index 0000000000..29d7582758 --- /dev/null +++ b/configs/mmseg/segmentation_openvino_static-512x512.py @@ -0,0 +1,4 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/openvino.py'] + +backend_config = dict( + model_inputs=[dict(opt_shapes=dict(input=[1, 3, 512, 512]))]) diff --git a/configs/mmseg/segmentation_tensorrt-fp16_static-512x512.py b/configs/mmseg/segmentation_tensorrt-fp16_static-512x512.py new file mode 100644 index 0000000000..f6d0d8bb5f --- /dev/null +++ b/configs/mmseg/segmentation_tensorrt-fp16_static-512x512.py @@ -0,0 +1,13 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/tensorrt-fp16.py'] + +onnx_config = dict(input_shape=[512, 512]) +backend_config = dict( + common_config=dict(max_workspace_size=1 << 30), + model_inputs=[ + dict( + input_shapes=dict( + input=dict( + min_shape=[1, 3, 512, 512], + opt_shape=[1, 3, 512, 512], + max_shape=[1, 3, 512, 512]))) + ]) diff --git a/configs/mmseg/segmentation_tensorrt_static-512x512.py b/configs/mmseg/segmentation_tensorrt_static-512x512.py new file mode 100644 index 0000000000..1fa5ef6695 --- /dev/null +++ b/configs/mmseg/segmentation_tensorrt_static-512x512.py @@ -0,0 +1,13 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/tensorrt.py'] + +onnx_config = dict(input_shape=[512, 512]) +backend_config = dict( + common_config=dict(max_workspace_size=1 << 30), + model_inputs=[ + dict( + input_shapes=dict( + input=dict( + min_shape=[1, 3, 512, 512], + opt_shape=[1, 3, 512, 512], + max_shape=[1, 3, 512, 512]))) + ]) From c9c44a55908123023eaf26ef07025d7413d3e5ba Mon Sep 17 00:00:00 2001 From: maningsheng Date: Tue, 22 Feb 2022 20:06:34 +0800 Subject: [PATCH 04/10] support emanet and icnet --- .../mmseg/models/decode_heads/__init__.py | 3 +- .../mmseg/models/decode_heads/ema_head.py | 45 +++++++++++++++++++ .../mmseg/models/decode_heads/psp_head.py | 11 +++++ 3 files changed, 58 insertions(+), 1 deletion(-) create mode 100644 mmdeploy/codebase/mmseg/models/decode_heads/ema_head.py diff --git a/mmdeploy/codebase/mmseg/models/decode_heads/__init__.py b/mmdeploy/codebase/mmseg/models/decode_heads/__init__.py index 5d505fa8bc..e893f20460 100644 --- a/mmdeploy/codebase/mmseg/models/decode_heads/__init__.py +++ b/mmdeploy/codebase/mmseg/models/decode_heads/__init__.py @@ -1,5 +1,6 @@ # Copyright (c) OpenMMLab. All rights reserved. from .aspp_head import aspp_head__forward +from .ema_head import ema_module__forward from .psp_head import ppm__forward -__all__ = ['aspp_head__forward', 'ppm__forward'] +__all__ = ['aspp_head__forward', 'ppm__forward', 'ema_module__forward'] diff --git a/mmdeploy/codebase/mmseg/models/decode_heads/ema_head.py b/mmdeploy/codebase/mmseg/models/decode_heads/ema_head.py new file mode 100644 index 0000000000..5d839691b7 --- /dev/null +++ b/mmdeploy/codebase/mmseg/models/decode_heads/ema_head.py @@ -0,0 +1,45 @@ +# Copyright (c) OpenMMLab. All rights reserved. +import torch +import torch.nn.functional as F + +from mmdeploy.core import FUNCTION_REWRITER + + +@FUNCTION_REWRITER.register_rewriter( + func_name='mmseg.models.decode_heads.ema_head.EMAModule.forward') +def ema_module__forward(ctx, self, feats): + """Rewrite `forward` for default backend. + + Replace torch.einsum with other operations. + + Args: + ctx (ContextCaller): The context with additional information. + self: The instance of the original class. + feats (Tensor): Input feature. + + Returns: + torch.Tensor: Output feature. + """ + batch_size, channels, height, width = feats.size() + # [batch_size, channels, height*width] + feats = feats.view(batch_size, channels, height * width) + # [batch_size, channels, num_bases] + bases = self.bases.repeat(batch_size, 1, 1) + + with torch.no_grad(): + for i in range(self.num_stages): + # [batch_size, height*width, num_bases] + attention = torch.bmm(feats.transpose(1, 2), bases) + # attention = torch.einsum('bcn,bck->bnk', feats, bases) + attention = F.softmax(attention, dim=2) + # l1 norm + attention_normed = F.normalize(attention, dim=1, p=1) + # [batch_size, channels, num_bases] + bases = torch.bmm(feats, attention_normed) + # bases = torch.einsum('bcn,bnk->bck', feats, attention_normed) + # l2 norm + bases = F.normalize(bases, dim=1, p=2) + feats_recon = torch.bmm(bases, attention.transpose(1, 2)) + # feats_recon = torch.einsum('bck,bnk->bcn', bases, attention) + feats_recon = feats_recon.view(batch_size, channels, height, width) + return feats_recon diff --git a/mmdeploy/codebase/mmseg/models/decode_heads/psp_head.py b/mmdeploy/codebase/mmseg/models/decode_heads/psp_head.py index 81e10ad160..c792237029 100644 --- a/mmdeploy/codebase/mmseg/models/decode_heads/psp_head.py +++ b/mmdeploy/codebase/mmseg/models/decode_heads/psp_head.py @@ -1,4 +1,6 @@ # Copyright (c) OpenMMLab. All rights reserved. + +import torch.nn as nn from mmseg.ops import resize from mmdeploy.core import FUNCTION_REWRITER @@ -30,6 +32,15 @@ def ppm__forward(ctx, self, x): ppm_outs = [] for ppm in self: + if isinstance(ppm[0], nn.AdaptiveAvgPool2d) and \ + ppm[0].output_size != 1: + assert not is_dynamic_flag, 'AdaptiveAvgPool2d is not \ + supported with dynamic shape in backends' + + # replace AdaptiveAvgPool2d with AvgPool2d explicitly + output_size = 2 * [ppm[0].output_size] + k = [int(size[i] / output_size[i]) for i in range(0, len(size))] + ppm[0] = nn.AvgPool2d(k, stride=k, padding=0, ceil_mode=False) ppm_out = ppm(x) upsampled_ppm_out = resize( ppm_out, From 15c7c41623424f2551318cf81eee9cafef198cbe Mon Sep 17 00:00:00 2001 From: maningsheng Date: Tue, 22 Feb 2022 20:07:08 +0800 Subject: [PATCH 05/10] set max K of TopK for tensorrt --- mmdeploy/pytorch/functions/topk.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/mmdeploy/pytorch/functions/topk.py b/mmdeploy/pytorch/functions/topk.py index be05fe93e0..64a416b28c 100644 --- a/mmdeploy/pytorch/functions/topk.py +++ b/mmdeploy/pytorch/functions/topk.py @@ -4,6 +4,7 @@ import torch from mmdeploy.core import FUNCTION_REWRITER +from mmdeploy.utils import get_root_logger @FUNCTION_REWRITER.register_rewriter(func_name='torch.topk', backend='default') @@ -47,7 +48,8 @@ def topk__tensorrt(ctx, TensorRT does not support topk with dynamic k. This function cast k to constant integer. """ - + # https://docs.nvidia.com/deeplearning/tensorrt/developer-guide/index.html#topKsetup + MAX_TOPK_K = 3840 if dim is None: dim = int(input.ndim - 1) size = input.shape[dim] @@ -55,4 +57,11 @@ def topk__tensorrt(ctx, k = size if not isinstance(k, int): k = int(k) + if k > MAX_TOPK_K: + logger = get_root_logger() + logger.warning( + f'Maximum K of TopK in TensorRT is {MAX_TOPK_K}, but given {k}.' + f' Note that k will be set to {MAX_TOPK_K}.') + k = MAX_TOPK_K + return ctx.origin_func(input, k, dim=dim, largest=largest, sorted=sorted) From 8ad51be41aa4801e7210236422f034e932f37e14 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Wed, 23 Feb 2022 10:53:03 +0800 Subject: [PATCH 06/10] update supported models for mmseg in docs --- docs/en/benchmark.md | 216 ++++++++++++++++++++++++++++++++++++ docs/en/codebases/mmseg.md | 52 ++++----- docs/en/supported_models.md | 21 ++++ docs/zh_cn/benchmark.md | 216 ++++++++++++++++++++++++++++++++++++ 4 files changed, 480 insertions(+), 25 deletions(-) diff --git a/docs/en/benchmark.md b/docs/en/benchmark.md index 8a5035de5e..31b26e2742 100644 --- a/docs/en/benchmark.md +++ b/docs/en/benchmark.md @@ -1409,6 +1409,222 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut - $MMSEG_DIR/configs/unet/fcn_unet_s5-d16_4x4_512x1024_160k_cityscapes.py + + ANN + Cityscapes + mIoU + 77.40 + - + 77.32 + 77.32 + - + - + $MMSEG_DIR/configs/ann/ann_r50-d8_512x1024_40k_cityscapes.py + + + APCNet + Cityscapes + mIoU + 77.40 + - + 77.32 + 77.32 + - + - + $MMSEG_DIR/configs/apcnet/apcnet_r50-d8_512x1024_40k_cityscapes.py + + + BiSeNetV1 + Cityscapes + mIoU + 74.44 + - + 74.44 + 74.43 + - + - + $MMSEG_DIR/configs/bisenetv1/bisenetv1_r18-d32_4x4_1024x1024_160k_cityscapes.py + + + BiSeNetV2 + Cityscapes + mIoU + 73.21 + - + 73.21 + 73.21 + - + - + $MMSEG_DIR/configs/bisenetv2/bisenetv2_fcn_4x4_1024x1024_160k_cityscapes.py + + + CGNet + Cityscapes + mIoU + 68.25 + - + 68.27 + 68.27 + - + - + $MMSEG_DIR/configs/cgnet/cgnet_512x1024_60k_cityscapes.py + + + EMANet + Cityscapes + mIoU + 77.59 + - + 77.59 + 77.6 + - + - + $MMSEG_DIR/configs/emanet/emanet_r50-d8_512x1024_80k_cityscapes.py + + + EncNet + Cityscapes + mIoU + 75.67 + - + 75.66 + 75.66 + - + - + $MMSEG_DIR/configs/encnet/encnet_r50-d8_512x1024_40k_cityscapes.py + + + ERFNet + Cityscapes + mIoU + 71.08 + - + 71.08 + 71.07 + - + - + $MMSEG_DIR/configs/erfnet/erfnet_fcn_4x4_512x1024_160k_cityscapes.py + + + FastFCN + Cityscapes + mIoU + 79.12 + - + 79.12 + 79.12 + - + - + $MMSEG_DIR/configs/fastfcn/fastfcn_r50-d32_jpu_aspp_512x1024_80k_cityscapes.py + + + GCNet + Cityscapes + mIoU + 77.69 + - + 77.69 + 77.69 + - + - + $MMSEG_DIR/configs/gcnet/gcnet_r50-d8_512x1024_40k_cityscapes.py + + + ICNet + Cityscapes + mIoU + 76.29 + - + 76.36 + 76.36 + - + - + $MMSEG_DIR/configs/icnet/icnet_r18-d8_832x832_80k_cityscapes.py + + + ISANet + Cityscapes + mIoU + 78.49 + - + 78.49 + 78.49 + - + - + $MMSEG_DIR/configs/isanet/isanet_r50-d8_512x1024_40k_cityscapes.py + + + OCRNet + Cityscapes + mIoU + 74.30 + - + 73.66 + 73.67 + - + - + $MMSEG_DIR/configs/ocrnet/ocrnet_hr18s_512x1024_40k_cityscapes.py + + + PointRend + Cityscapes + mIoU + 76.47 + - + 76.41 + 76.42 + - + - + $MMSEG_DIR/configs/point_rend/pointrend_r50_512x1024_80k_cityscapes.py + + + Semantic FPN + Cityscapes + mIoU + 74.52 + - + 74.52 + 74.52 + - + - + $MMSEG_DIR/configs/sem_fpn/fpn_r50_512x1024_80k_cityscapes.py + + + STDC + Cityscapes + mIoU + 75.10 + - + 75.10 + 75.10 + - + - + $MMSEG_DIR/configs/stdc/stdc1_in1k-pre_512x1024_80k_cityscapes.py + + + STDC + Cityscapes + mIoU + 77.17 + - + 77.17 + 77.17 + - + - + $MMSEG_DIR/configs/stdc/stdc2_in1k-pre_512x1024_80k_cityscapes.py + + + UPerNet + Cityscapes + mIoU + 77.10 + - + 77.19 + 77.18 + - + - + $MMSEG_DIR/configs/upernet/upernet_r50_512x1024_40k_cityscapes.py + diff --git a/docs/en/codebases/mmseg.md b/docs/en/codebases/mmseg.md index 709825c391..ff950c065c 100644 --- a/docs/en/codebases/mmseg.md +++ b/docs/en/codebases/mmseg.md @@ -16,31 +16,33 @@ Please refer to [get_started.md](https://github.com/open-mmlab/mmsegmentation/bl | DeepLabV3+ | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/deeplabv3plus) | | Fast-SCNN[*](#static_shape) | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/fastscnn) | | UNet[*](#static_shape) | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/unet) | -| ANN | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| APCNet | Y | Y | N | Y | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| BiSeNetV1 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| BiSeNetV2 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| CCNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| CGNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| DMNet | Y | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| DNLNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| EMANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| EncNet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| ERFNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| FastFCN | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| GCNet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| ICNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| ISANet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| NonLocal Net | Y | N | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| OCRNet | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| PointRend | Y | N | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| PSANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| SegFormer | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| Semantic FPN | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| STDC1 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| STDC2 | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | -| UPerNet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/) | - +| ANN[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ann) | +| APCNet | Y | Y | Y | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/apcnet) | +| BiSeNetV1 | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/bisenetv1) | +| BiSeNetV2 | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/bisenetv2) | +| CGNet | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/cgnet) | +| DMNet | Y | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dmnet) | +| DNLNet | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dnlnet) | +| EMANet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/emanet) | +| EncNet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/encnet) | +| ERFNet | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/erfnet) | +| FastFCN | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/fastfcn) | +| GCNet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/gcnet) | +| ICNet[*](#static_shape) | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/icnet) | +| ISANet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/isanet) | +| NonLocal Net | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/nonlocal_net) | +| OCRNet | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ocrnet) | +| PointRend | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/point_rend) | +| Semantic FPN | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/sem_fpn) | +| STDC | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/stdc) | +| UPerNet[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/upernet) | +| DANet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/danet) | +| CCNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ccnet) | +| PSANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/psanet) | +| SegFormer | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segformer) | +| DPT | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dpt) | +| Segmenter | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segmenter) | +| SETR | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/setr) | ### Reminder diff --git a/docs/en/supported_models.md b/docs/en/supported_models.md index 8f13fe93df..32a44b1da8 100644 --- a/docs/en/supported_models.md +++ b/docs/en/supported_models.md @@ -29,6 +29,27 @@ The table below lists the models that are guaranteed to be exportable to other b | DeepLabV3+ | MMSegmentation | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/deeplabv3plus) | | Fast-SCNN[*static](#note) | MMSegmentation | Y | Y | N | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/fastscnn) | | UNet[*static](#note) | MMSegmentation | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/unet) | +| ANN[*](#note) | MMSegmentation | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ann) | +| APCNet | MMSegmentation | Y | Y | Y | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/apcnet) | +| BiSeNetV1 | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/bisenetv1) | +| BiSeNetV2 | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/bisenetv2) | +| CGNet | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/cgnet) | +| DMNet | MMSegmentation | Y | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dmnet) | +| DNLNet | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dnlnet) | +| EMANet | MMSegmentation | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/emanet) | +| EncNet | MMSegmentation | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/encnet) | +| ERFNet | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/erfnet) | +| FastFCN | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/fastfcn) | +| GCNet | MMSegmentation | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/gcnet) | +| ICNet[*](#note) | MMSegmentation | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/icnet) | +| ISANet | MMSegmentation | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/isanet) | +| NonLocal Net | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/nonlocal_net) | +| OCRNet | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ocrnet) | +| PointRend | MMSegmentation | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/point_rend) | +| Semantic FPN | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/sem_fpn) | +| STDC | MMSegmentation | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/stdc) | +| UPerNet[*](#note) | MMSegmentation | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/upernet) | +| DANet | MMSegmentation | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/danet) | | SRCNN | MMEditing | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmediting/tree/master/configs/restorers/srcnn) | | ESRGAN | MMEditing | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmediting/tree/master/configs/restorers/esrgan) | | SRGAN | MMEditing | Y | Y | Y | Y | Y | [config](https://github.com/open-mmlab/mmediting/tree/master/configs/restorers/srresnet_srgan) | diff --git a/docs/zh_cn/benchmark.md b/docs/zh_cn/benchmark.md index e1a12af880..6ba3ababc0 100644 --- a/docs/zh_cn/benchmark.md +++ b/docs/zh_cn/benchmark.md @@ -1410,6 +1410,222 @@ GPU: ncnn, TensorRT, PPLNN - $MMSEG_DIR/configs/unet/fcn_unet_s5-d16_4x4_512x1024_160k_cityscapes.py + + ANN + Cityscapes + mIoU + 77.40 + - + 77.32 + 77.32 + - + - + $MMSEG_DIR/configs/ann/ann_r50-d8_512x1024_40k_cityscapes.py + + + APCNet + Cityscapes + mIoU + 77.40 + - + 77.32 + 77.32 + - + - + $MMSEG_DIR/configs/apcnet/apcnet_r50-d8_512x1024_40k_cityscapes.py + + + BiSeNetV1 + Cityscapes + mIoU + 74.44 + - + 74.44 + 74.43 + - + - + $MMSEG_DIR/configs/bisenetv1/bisenetv1_r18-d32_4x4_1024x1024_160k_cityscapes.py + + + BiSeNetV2 + Cityscapes + mIoU + 73.21 + - + 73.21 + 73.21 + - + - + $MMSEG_DIR/configs/bisenetv2/bisenetv2_fcn_4x4_1024x1024_160k_cityscapes.py + + + CGNet + Cityscapes + mIoU + 68.25 + - + 68.27 + 68.27 + - + - + $MMSEG_DIR/configs/cgnet/cgnet_512x1024_60k_cityscapes.py + + + EMANet + Cityscapes + mIoU + 77.59 + - + 77.59 + 77.6 + - + - + $MMSEG_DIR/configs/emanet/emanet_r50-d8_512x1024_80k_cityscapes.py + + + EncNet + Cityscapes + mIoU + 75.67 + - + 75.66 + 75.66 + - + - + $MMSEG_DIR/configs/encnet/encnet_r50-d8_512x1024_40k_cityscapes.py + + + ERFNet + Cityscapes + mIoU + 71.08 + - + 71.08 + 71.07 + - + - + $MMSEG_DIR/configs/erfnet/erfnet_fcn_4x4_512x1024_160k_cityscapes.py + + + FastFCN + Cityscapes + mIoU + 79.12 + - + 79.12 + 79.12 + - + - + $MMSEG_DIR/configs/fastfcn/fastfcn_r50-d32_jpu_aspp_512x1024_80k_cityscapes.py + + + GCNet + Cityscapes + mIoU + 77.69 + - + 77.69 + 77.69 + - + - + $MMSEG_DIR/configs/gcnet/gcnet_r50-d8_512x1024_40k_cityscapes.py + + + ICNet + Cityscapes + mIoU + 76.29 + - + 76.36 + 76.36 + - + - + $MMSEG_DIR/configs/icnet/icnet_r18-d8_832x832_80k_cityscapes.py + + + ISANet + Cityscapes + mIoU + 78.49 + - + 78.49 + 78.49 + - + - + $MMSEG_DIR/configs/isanet/isanet_r50-d8_512x1024_40k_cityscapes.py + + + OCRNet + Cityscapes + mIoU + 74.30 + - + 73.66 + 73.67 + - + - + $MMSEG_DIR/configs/ocrnet/ocrnet_hr18s_512x1024_40k_cityscapes.py + + + PointRend + Cityscapes + mIoU + 76.47 + - + 76.41 + 76.42 + - + - + $MMSEG_DIR/configs/point_rend/pointrend_r50_512x1024_80k_cityscapes.py + + + Semantic FPN + Cityscapes + mIoU + 74.52 + - + 74.52 + 74.52 + - + - + $MMSEG_DIR/configs/sem_fpn/fpn_r50_512x1024_80k_cityscapes.py + + + STDC + Cityscapes + mIoU + 75.10 + - + 75.10 + 75.10 + - + - + $MMSEG_DIR/configs/stdc/stdc1_in1k-pre_512x1024_80k_cityscapes.py + + + STDC + Cityscapes + mIoU + 77.17 + - + 77.17 + 77.17 + - + - + $MMSEG_DIR/configs/stdc/stdc2_in1k-pre_512x1024_80k_cityscapes.py + + + UPerNet + Cityscapes + mIoU + 77.10 + - + 77.19 + 77.18 + - + - + $MMSEG_DIR/configs/upernet/upernet_r50_512x1024_40k_cityscapes.py + From dec446980d30c44e8da31a680ba1ef2dfd951ab0 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Wed, 23 Feb 2022 11:05:25 +0800 Subject: [PATCH 07/10] add test for emamodule --- .../test_mmseg/test_mmseg_models.py | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) diff --git a/tests/test_codebase/test_mmseg/test_mmseg_models.py b/tests/test_codebase/test_mmseg/test_mmseg_models.py index 71dbf86187..a29abb898f 100644 --- a/tests/test_codebase/test_mmseg/test_mmseg_models.py +++ b/tests/test_codebase/test_mmseg/test_mmseg_models.py @@ -232,3 +232,32 @@ def test_psphead_forward(backend): rewrite_outputs = rewrite_outputs.to(model_outputs).reshape( model_outputs.shape) assert torch.allclose(rewrite_outputs, model_outputs, rtol=1, atol=1) + + +@pytest.mark.parametrize('backend', [Backend.ONNXRUNTIME]) +def test_emamodule_forward(backend): + check_backend(backend) + from mmseg.models.decode_heads.ema_head import EMAModule + head = EMAModule(8, 2, 2, 1.0).eval() + + deploy_cfg = mmcv.Config( + dict( + backend_config=dict(type=backend.value), + onnx_config=dict( + output_names=['result'], input_shape=(1, 8, 16, 16)), + codebase_config=dict(type='mmseg', task='Segmentation'))) + feats = torch.randn(1, 8, 16, 16) + model_inputs = {'feats': feats} + with torch.no_grad(): + model_outputs = get_model_outputs(head, 'forward', model_inputs) + wrapped_model = WrapModel(head, 'forward') + rewrite_outputs, is_backend_output = get_rewrite_outputs( + wrapped_model=wrapped_model, + model_inputs=model_inputs, + deploy_cfg=deploy_cfg) + if is_backend_output: + rewrite_outputs = rewrite_outputs[0] + rewrite_outputs = rewrite_outputs.to(model_outputs).reshape( + model_outputs.shape) + assert torch.allclose( + rewrite_outputs, model_outputs, rtol=1e-03, atol=1e-05) From 4bb98bdf125fd5d185e1b94f16d0a8b5bd438d44 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Wed, 23 Feb 2022 15:26:43 +0800 Subject: [PATCH 08/10] add configs and update docs --- .../segmentation_tensorrt-fp16_static-1024x1024.py | 13 +++++++++++++ .../segmentation_tensorrt-int8_static-1024x1024.py | 13 +++++++++++++ .../segmentation_tensorrt-int8_static-512x512.py | 13 +++++++++++++ .../mmseg/segmentation_tensorrt_static-1024x1024.py | 13 +++++++++++++ docs/en/codebases/mmseg.md | 4 ++-- 5 files changed, 54 insertions(+), 2 deletions(-) create mode 100644 configs/mmseg/segmentation_tensorrt-fp16_static-1024x1024.py create mode 100644 configs/mmseg/segmentation_tensorrt-int8_static-1024x1024.py create mode 100644 configs/mmseg/segmentation_tensorrt-int8_static-512x512.py create mode 100644 configs/mmseg/segmentation_tensorrt_static-1024x1024.py diff --git a/configs/mmseg/segmentation_tensorrt-fp16_static-1024x1024.py b/configs/mmseg/segmentation_tensorrt-fp16_static-1024x1024.py new file mode 100644 index 0000000000..dc887a10d5 --- /dev/null +++ b/configs/mmseg/segmentation_tensorrt-fp16_static-1024x1024.py @@ -0,0 +1,13 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/tensorrt-fp16.py'] + +onnx_config = dict(input_shape=[1024, 1024]) +backend_config = dict( + common_config=dict(max_workspace_size=1 << 30), + model_inputs=[ + dict( + input_shapes=dict( + input=dict( + min_shape=[1, 3, 1024, 1024], + opt_shape=[1, 3, 1024, 1024], + max_shape=[1, 3, 1024, 1024]))) + ]) diff --git a/configs/mmseg/segmentation_tensorrt-int8_static-1024x1024.py b/configs/mmseg/segmentation_tensorrt-int8_static-1024x1024.py new file mode 100644 index 0000000000..b68ac61872 --- /dev/null +++ b/configs/mmseg/segmentation_tensorrt-int8_static-1024x1024.py @@ -0,0 +1,13 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/tensorrt-int8.py'] + +onnx_config = dict(input_shape=[1024, 1024]) +backend_config = dict( + common_config=dict(max_workspace_size=1 << 30), + model_inputs=[ + dict( + input_shapes=dict( + input=dict( + min_shape=[1, 3, 1024, 1024], + opt_shape=[1, 3, 1024, 1024], + max_shape=[1, 3, 1024, 1024]))) + ]) diff --git a/configs/mmseg/segmentation_tensorrt-int8_static-512x512.py b/configs/mmseg/segmentation_tensorrt-int8_static-512x512.py new file mode 100644 index 0000000000..125c9c1196 --- /dev/null +++ b/configs/mmseg/segmentation_tensorrt-int8_static-512x512.py @@ -0,0 +1,13 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/tensorrt-int8.py'] + +onnx_config = dict(input_shape=[512, 512]) +backend_config = dict( + common_config=dict(max_workspace_size=1 << 30), + model_inputs=[ + dict( + input_shapes=dict( + input=dict( + min_shape=[1, 3, 512, 512], + opt_shape=[1, 3, 512, 512], + max_shape=[1, 3, 512, 512]))) + ]) diff --git a/configs/mmseg/segmentation_tensorrt_static-1024x1024.py b/configs/mmseg/segmentation_tensorrt_static-1024x1024.py new file mode 100644 index 0000000000..949eec7579 --- /dev/null +++ b/configs/mmseg/segmentation_tensorrt_static-1024x1024.py @@ -0,0 +1,13 @@ +_base_ = ['./segmentation_static.py', '../_base_/backends/tensorrt.py'] + +onnx_config = dict(input_shape=[1024, 1024]) +backend_config = dict( + common_config=dict(max_workspace_size=1 << 30), + model_inputs=[ + dict( + input_shapes=dict( + input=dict( + min_shape=[1, 3, 1024, 1024], + opt_shape=[1, 3, 1024, 1024], + max_shape=[1, 3, 1024, 1024]))) + ]) diff --git a/docs/en/codebases/mmseg.md b/docs/en/codebases/mmseg.md index ff950c065c..650e027ea8 100644 --- a/docs/en/codebases/mmseg.md +++ b/docs/en/codebases/mmseg.md @@ -37,11 +37,11 @@ Please refer to [get_started.md](https://github.com/open-mmlab/mmsegmentation/bl | STDC | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/stdc) | | UPerNet[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/upernet) | | DANet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/danet) | +| Segmenter[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segmenter) | +| SegFormer[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segformer) | | CCNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ccnet) | | PSANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/psanet) | -| SegFormer | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segformer) | | DPT | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dpt) | -| Segmenter | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segmenter) | | SETR | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/setr) | ### Reminder From 7cab11adca2d70e080b8e1b3edb89ef4bd357654 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Fri, 25 Feb 2022 15:04:03 +0800 Subject: [PATCH 09/10] Update docs --- docs/en/codebases/mmseg.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/en/codebases/mmseg.md b/docs/en/codebases/mmseg.md index 650e027ea8..a2b6859cac 100644 --- a/docs/en/codebases/mmseg.md +++ b/docs/en/codebases/mmseg.md @@ -36,13 +36,13 @@ Please refer to [get_started.md](https://github.com/open-mmlab/mmsegmentation/bl | Semantic FPN | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/sem_fpn) | | STDC | Y | Y | Y | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/stdc) | | UPerNet[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/upernet) | -| DANet | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/danet) | +| DANet | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/danet) | | Segmenter[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segmenter) | -| SegFormer[*](#static_shape) | Y | Y | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segformer) | +| SegFormer[*](#static_shape) | Y | Y | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/segformer) | +| SETR | Y | N | N | N | Y | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/setr) | | CCNet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/ccnet) | | PSANet | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/psanet) | | DPT | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/dpt) | -| SETR | N | N | N | N | N | [config](https://github.com/open-mmlab/mmsegmentation/tree/master/configs/setr) | ### Reminder From 830c95215263e64cd0bbf84771b5e849ed906c14 Mon Sep 17 00:00:00 2001 From: maningsheng Date: Tue, 8 Mar 2022 16:43:05 +0800 Subject: [PATCH 10/10] update benchmark --- docs/en/benchmark.md | 18 ++++++++++++++++++ docs/zh_cn/benchmark.md | 18 ++++++++++++++++++ 2 files changed, 36 insertions(+) diff --git a/docs/en/benchmark.md b/docs/en/benchmark.md index 60331d7bf4..71268c0d8d 100644 --- a/docs/en/benchmark.md +++ b/docs/en/benchmark.md @@ -1486,6 +1486,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 77.40 - + - 77.32 77.32 - @@ -1498,6 +1499,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 77.40 - + - 77.32 77.32 - @@ -1510,6 +1512,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 74.44 - + - 74.44 74.43 - @@ -1522,6 +1525,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 73.21 - + - 73.21 73.21 - @@ -1534,6 +1538,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 68.25 - + - 68.27 68.27 - @@ -1546,6 +1551,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 77.59 - + - 77.59 77.6 - @@ -1558,6 +1564,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 75.67 - + - 75.66 75.66 - @@ -1570,6 +1577,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 71.08 - + - 71.08 71.07 - @@ -1582,6 +1590,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 79.12 - + - 79.12 79.12 - @@ -1594,6 +1603,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 77.69 - + - 77.69 77.69 - @@ -1606,6 +1616,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 76.29 - + - 76.36 76.36 - @@ -1618,6 +1629,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 78.49 - + - 78.49 78.49 - @@ -1630,6 +1642,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 74.30 - + - 73.66 73.67 - @@ -1642,6 +1655,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 76.47 - + - 76.41 76.42 - @@ -1654,6 +1668,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 74.52 - + - 74.52 74.52 - @@ -1666,6 +1681,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 75.10 - + - 75.10 75.10 - @@ -1678,6 +1694,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 77.17 - + - 77.17 77.17 - @@ -1690,6 +1707,7 @@ Users can directly test the performance through [how_to_evaluate_a_model.md](tut mIoU 77.10 - + - 77.19 77.18 - diff --git a/docs/zh_cn/benchmark.md b/docs/zh_cn/benchmark.md index 52afc8d1b8..ffece64617 100644 --- a/docs/zh_cn/benchmark.md +++ b/docs/zh_cn/benchmark.md @@ -1474,6 +1474,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 77.40 - + - 77.32 77.32 - @@ -1486,6 +1487,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 77.40 - + - 77.32 77.32 - @@ -1498,6 +1500,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 74.44 - + - 74.44 74.43 - @@ -1510,6 +1513,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 73.21 - + - 73.21 73.21 - @@ -1522,6 +1526,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 68.25 - + - 68.27 68.27 - @@ -1534,6 +1539,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 77.59 - + - 77.59 77.6 - @@ -1546,6 +1552,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 75.67 - + - 75.66 75.66 - @@ -1558,6 +1565,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 71.08 - + - 71.08 71.07 - @@ -1570,6 +1578,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 79.12 - + - 79.12 79.12 - @@ -1582,6 +1591,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 77.69 - + - 77.69 77.69 - @@ -1594,6 +1604,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 76.29 - + - 76.36 76.36 - @@ -1606,6 +1617,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 78.49 - + - 78.49 78.49 - @@ -1618,6 +1630,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 74.30 - + - 73.66 73.67 - @@ -1630,6 +1643,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 76.47 - + - 76.41 76.42 - @@ -1642,6 +1656,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 74.52 - + - 74.52 74.52 - @@ -1654,6 +1669,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 75.10 - + - 75.10 75.10 - @@ -1666,6 +1682,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 77.17 - + - 77.17 77.17 - @@ -1678,6 +1695,7 @@ GPU: ncnn, TensorRT, PPLNN mIoU 77.10 - + - 77.19 77.18 -