Commit Graph

298 Commits (b55bf8ec1b5b67b7ddcab149b1f197cb4b677521)
 

Author SHA1 Message Date
Semyon Bevzyuk be995821f1
Fix postprocessing_masks. (#186) 2021-11-09 10:24:59 +08:00
del-zhenwu 80da064274
[Doc] Add openvino in doc (#176)
Signed-off-by: del-zhenwu <zhenxiang0708@163.com>

Co-authored-by: del-zhenwu <zhenxiang0708@163.com>
2021-11-08 16:09:18 +08:00
hanrui1sensetime ceae222a8a
[Docs] add mmseg.md (#174)
* add mmseg.md

* Align with pr #171

* left alignment of 1st and last column
2021-11-08 16:08:41 +08:00
RunningLeon cd51f12f32
[Feature]: Support yolov3 (#167)
* support yolov3 with ort and trt

* add ncnn compare

* fix yolo_head ncnn rewriter

* align perforance with ort trt for yolov3

* update doc

* add test for compare with equal,less, greater

* change namespace

* reformat cpp

* fix lint

* fix lint

* add unit test for yolov3 head

* remove compare op

* update doc

* update table format in docs

* update comments

* update

Co-authored-by: hanrui1sensetime <hanrui1@sensetime.com>
2021-11-08 16:07:58 +08:00
RunningLeon 2ffc657665
[Docs]: Add mmcls support doc (#171)
* add doc

* update

* update

* update table format

* update name

* update

* resolve comments

* remove unnecessary files

* update mmedit

* update

* resolve comments
2021-11-08 15:37:43 +08:00
Semyon Bevzyuk ca93007035
[Enhancement]: Support FoveaBox and ATSS from mmdetection for OpenVINO and ONNX Runtime (#160)
* Add FoveaHead and AtssHead.

* Update docs.

* Fix typos and docstrings.

* Fixes.

* Fix img_metas type in docstring.
2021-11-05 17:45:49 +08:00
AllentDan 12eec39340
[Fix] fix trt_multi_level_roi_align plugin of tensorrt in T4 platform (#170)
* fix trt_multi_level_roi_align for tensorrt in T4 platform

* fix typo

* resolve comments
2021-11-04 15:53:48 +08:00
q.yao 4e168ee1c7
Update tensorrt install info (#165) 2021-11-03 10:55:50 +08:00
Semyon Bevzyuk c52b24c67f
[Enhancement]: Added support for masks in OpenVINO. (#148)
* Fix include and lib paths for onnxruntime.

* Fixes for SSD export test

* Add onnx2openvino and OpenVINODetector. Test models: ssd, retinanet, fcos, fsaf.

* Add support for two-stage models: faster_rcnn, cascade_rcnn

* Add doc

* Add strip_doc_string for openvino.

* Fix openvino preprocess.

* Add OpenVINO to test_wrapper.py.

* Fix

* Add openvino_execute.

* Removed preprocessing.

* Fix onnxruntime cmake.

* Rewrote postprocessing and forward, added docstrings and fixes.

* Added device type change to OpenVINOWrapper.

* Update forward_of_single_roi_extractor_dynamic_openvino and fix doc.

* Update docs.

* Add support for masks (Mask RCNN).

* Add masks to CascadeRoIHead.simple_test.

* Added masks to test_OpenVINODetector.

* Added test_cascade_roi_head_with_mask.

* Update docs.

* Fix segm_results shape.

* Fix TopK in NMS and add test_multiclass_nms_with_keep_top_k.

* Removed unnecessary functions.

* Fix.

* Fix test_multiclass_nms_with_keep_top_k.

* Updated test_OpenVINODetector.
2021-11-03 10:27:48 +08:00
VVsssssk d3e26b68a2
fix docs bug (#166) 2021-11-02 19:12:53 +08:00
Yifan Zhou 6e4a32b746
[Doc]: How to add unit tests to rewritten models of codebases (#143)
* add english doc

* update index

* Resolve some comments

* Resolve comments

* Add Chinese doc

* Resolve comment
2021-11-02 10:33:20 +08:00
q.yao daee76ec99
[Enhancement] Optional export postprocess of mask (#161)
* Optional export postprocess of mask

* optional deploy_cfg

* delete print
2021-11-01 12:58:54 +08:00
q.yao ea3078aa56
Update custom ops namespace (#158)
* Update custom ops namespace

* rename register, rename generated library name

* rename domain to mmcv
2021-11-01 10:48:21 +08:00
VVsssssk 985bb6ad34
[Doc]How to write config (#139)
* add ncnn test exporter in test_ops.py

* add ncnn test exporter in utils.py

* add onnxruntime and tensorrt ops test

* fix blank line

* fix comment
add nms ops test

* remove nms test

* add test sample
add dockerstring

* remove nms test

* fix grid_sample
add type hind

* fix problem

* fix dockerstring

* add nms batch_nms multi_level_roi_align

* add test data

* fix problem

* rm pkl file dependent

* rm file

* add docstring

* remove multi_level_dependce

* add mmseg module unittest

* add mmseg test

* add mmseg model unit test

* fix blankline

* rename file

* add syncbn2bn unit test

* add apis/export

* lint

* lint

* ??

* delete#

* fix problems

* add mmcv unit test

* add docs about how to create config file

* fix :

* add zh docs about how to create config

* add full example

* fix comment

* add note

* fix problem

* fix catalog

* fix catalog`

* fix catalog

* fix docs

* fix cn docs

* fix lint

* fix docs

* fix space

* add mmocr link

* fix problem

* fix new

Co-authored-by: SingleZombie <singlezombie@163.com>
2021-10-29 18:04:11 +08:00
q.yao ef88d20241
lock version of mmdet (#159) 2021-10-29 10:59:16 +08:00
Yifan Zhou 31446de905
[Doc]: MMEdit doc (#153)
* Add doc

* Remove spaces

* sovle comments

* Resolve comments
2021-10-28 14:33:40 +08:00
AllentDan 5fdd75fba1
Add tensorrt int8 and fp16 configs for all the rest codebases (#152)
* add configs for all codebases except mmocr and fixed some bugs

* add ocr det

* add fp16 and int8 config for text recog
2021-10-27 15:59:02 +08:00
Yifan Zhou 227bebaade
[Enhancement]: Rename files in mmdeploy/core/rewriters (#157)
* Rename files

* lint

* update docstring
2021-10-27 15:12:00 +08:00
VVsssssk 415f70900a
[Docs]Mmdet docs (#150)
* add docs

* fix docs
2021-10-27 15:04:20 +08:00
q.yao c8b78f6c9b
Add citation (#151)
* Add citation

* fix typo
2021-10-27 15:03:40 +08:00
q.yao 6c420dcd05
Remove useless files (#156) 2021-10-27 14:50:12 +08:00
AllentDan a563a03570
add a demo for rewrite (#145)
* add a demo for rewrite

* remove register symbolics

* place two image in one line

* width = 300

* use table to show two images

* fix typo
2021-10-27 11:06:42 +08:00
RunningLeon 0b46c505ee
[Docstring] Update docstring and its config (#142)
* update

* fix lint

* add config for interrogate

* remove config

* solve comments
2021-10-27 10:44:54 +08:00
AllentDan 77131ea071
[Feature] Add exporting SARNet to onnxruntime backends. (#134)
* save codes

* save codes

* support sar exporting to onnxruntime and tensorrt

* use 4G max gpu space

* support sequential sar

* remove trt config for sar

* add sar unit tests

* add sar unit tests

* resolve conflicts

* remove torch.add rewrite in unit tests
2021-10-26 15:42:06 +08:00
q.yao aa9c770b2c
[Docs] TensorRT docs (#136)
* Update TensorRT docs

* add tensorrt ops document

* reply comment

* update

* update document

* update
2021-10-26 15:41:31 +08:00
q.yao b5797c9e6c
Update c++14 (#149) 2021-10-26 10:54:45 +08:00
Yifan Zhou 398bf2b386
[Refactor]: Refactor mmdeploy/core (#140)
* refactor function rewriter

* Pass unit test

* Fix test

* Fix test

* lint

* refactor function rewriter

* Pass unit test

* Fix test

* Fix test

* lint

* support openvino

* update

1. All type hints of cfg are set to Dict
2. Check if kwargs exist when calling patch_model
3. Complement tests
4. key name 'object' is set to '_object'

* lint

* Update docstring

* Fix tests

* Improve test
2021-10-26 10:30:14 +08:00
AllentDan 35b7341766
fix mmocr (#147) 2021-10-25 19:09:28 +08:00
VVsssssk a357ffa924
[Docs]Add docs about How to convert model (#132)
* add ncnn test exporter in test_ops.py

* add ncnn test exporter in utils.py

* add onnxruntime and tensorrt ops test

* fix blank line

* fix comment
add nms ops test

* remove nms test

* add test sample
add dockerstring

* remove nms test

* fix grid_sample
add type hind

* fix problem

* fix dockerstring

* add nms batch_nms multi_level_roi_align

* add test data

* fix problem

* rm pkl file dependent

* rm file

* add docstring

* remove multi_level_dependce

* add mmseg module unittest

* add mmseg test

* add mmseg model unit test

* fix blankline

* rename file

* add syncbn2bn unit test

* add apis/export

* lint

* lint

* ??

* delete#

* fix problems

* add mmcv unit test

* add docs about how to convert model

* fix docs convert model

* add list

* rm mmcv test

* add mmocr model in list
fix decription

* fix docs

* fix docs

* refactor docs

* fix model list

* add docs about how to create config file

* fix how to convert model

* remove other docs

* add cn docs

* fix args description

* fix space

* fix about evaluate model

* fix link problems

* fix cn docs

Co-authored-by: SingleZombie <singlezombie@163.com>
2021-10-25 17:25:45 +08:00
Zaida Zhou 097a0281d4
Fix tutorial link not found (#144)
* fix tutorial link not found

* fix typo
2021-10-25 16:37:33 +08:00
Semyon Bevzyuk ba7ae81d3e
[Unittest]: Test for CascadeRoIHead (#141)
* Fix include and lib paths for onnxruntime.

* Fixes for SSD export test

* Add onnx2openvino and OpenVINODetector. Test models: ssd, retinanet, fcos, fsaf.

* Add support for two-stage models: faster_rcnn, cascade_rcnn

* Add doc

* Add strip_doc_string for openvino.

* Fix openvino preprocess.

* Add OpenVINO to test_wrapper.py.

* Fix

* Add openvino_execute.

* Removed preprocessing.

* Fix onnxruntime cmake.

* Rewrote postprocessing and forward, added docstrings and fixes.

* Added device type change to OpenVINOWrapper.

* Update forward_of_single_roi_extractor_dynamic_openvino and fix doc.

* Update docs.

* Add OpenVINODetector and onn2openvino tests.

* Add input_info to onnx2openvino.

* Add TestOpenVINOExporter and test_single_roi_extractor.

* Moved get_input_shape_from_cfg to openvino_utils.py and added test.

* Added test_cascade_roi_head.

* Add backend.check_env() to tests.

* Add OpenVINO to get_rewrite_outputs and to some tests in test_mmdet_models.

* Moved test_single_roi_extractor to test_mmdet_models.

* Removed TestOpenVINOExporter.

* Added test_cascade_roi_head.

* Fix onnxruntime outputs type.
2021-10-25 15:13:09 +08:00
hanrui1sensetime 9e227b228b
[UnitTest] mmocr unittest (#130)
* WIP test_mmocr 8 out of 20

* test_mmocr_export

* test mmocr apis

* add test data

* add mmocr model unittest 5 passed 1 failed

* finish mmocr unittest

* fix lint

* fix yapf

* fix isort

* fix flake8

* fix docformatter

* fix docformatter

* try to fix unittest after merge master

* Change test.py for backend.DEFAULT

* fix flake8

* fix ut

* fix yapf

* fix ut build

* fix yapf

* fix mmocr_export ut

* fix mmocr_apis ort not cuda

* remove explicit .forward

* remove backendwrapper

* simplify the crnn and dbnet config

* simplify instance_test.json

* add another case of decoder

* increase coverage of test_mmocr_models base_recognizer

* improve coverage

* improve encode_decoder coverage

* reply for grimoire codereview

* what if not check cuda?

* remove image data

* reply to runningleon code review

* fix fpnc

* fix lint

* try to fix CI UT error

* fix fpnc with and wo custom ops

* fix yapf

* skip fpnc when cuda is not ready in ci

* reply for code review

* reply for code review

* fix yapf

* reply for code review

* fix yapf

* fix conflict

* remove unmatched data path

* remove unnecessary comments
2021-10-25 10:15:57 +08:00
Semyon Bevzyuk c5a87fb1bc
[Enhancement]: OpenVINO deployment support for some models (#117)
* Fix include and lib paths for onnxruntime.

* Fixes for SSD export test

* Add onnx2openvino and OpenVINODetector. Test models: ssd, retinanet, fcos, fsaf.

* Add support for two-stage models: faster_rcnn, cascade_rcnn

* Add doc

* Add strip_doc_string for openvino.

* Fix openvino preprocess.

* Add OpenVINO to test_wrapper.py.

* Fix

* Add openvino_execute.

* Removed preprocessing.

* Fix onnxruntime cmake.

* Rewrote postprocessing and forward, added docstrings and fixes.

* Added device type change to OpenVINOWrapper.

* Update forward_of_single_roi_extractor_dynamic_openvino and fix doc.

* Update docs.

* Add OpenVINODetector and onn2openvino tests.

* Add input_info to onnx2openvino.

* Add TestOpenVINOExporter and test_single_roi_extractor.

* Moved get_input_shape_from_cfg to openvino_utils.py and added test.

* Added test_cascade_roi_head.

* Add backend.check_env() to tests.

* Add OpenVINO to get_rewrite_outputs and to some tests in test_mmdet_models.

* Moved test_single_roi_extractor to test_mmdet_models.

* Removed TestOpenVINOExporter.
2021-10-21 16:07:35 +08:00
Yifan Zhou 11e9876c3f
[Doc]: How to evaluate a model (#137)
* add doc

* update argument list

* lint

* Resolve comments

* Add link

* Resolve comments

* resolve comments
2021-10-20 18:23:50 +08:00
Yifan Zhou e240c1569f
[Unittest]: Test mmcls (#135)
* Add tests

* lint

* add data

* Remove redundant code
2021-10-19 20:30:51 +08:00
RunningLeon a7111eddb6
[Doc]: onnxruntime (#131)
* add ort doc

* update

* update

* update
2021-10-19 20:30:40 +08:00
RunningLeon 4c1f62f3cb
Remove GPU CI (#138)
* remove config of gpu

* remove empty line
2021-10-19 20:29:19 +08:00
VVsssssk fd75d57175
[Unittest]: Add MMSegmentation test (#125)
* add ncnn test exporter in test_ops.py

* add ncnn test exporter in utils.py

* add onnxruntime and tensorrt ops test

* fix blank line

* fix comment
add nms ops test

* remove nms test

* add test sample
add dockerstring

* remove nms test

* fix grid_sample
add type hind

* fix problem

* fix dockerstring

* add nms batch_nms multi_level_roi_align

* add test data

* fix problem

* rm pkl file dependent

* rm file

* add docstring

* remove multi_level_dependce

* add mmseg module unittest

* add mmseg test

* add mmseg model unit test

* fix blankline

* rename file

* add syncbn2bn unit test

* add apis/export

* lint

* lint

* ??

* delete#

* fix ncnn check

* fix problems

* fix problems

* fix dim problems

* resolve comments

* Fix SwitchBackendWrapper

* fix assert problems

* fix assert

* Remove comment

* merge master

Co-authored-by: SingleZombie <singlezombie@163.com>
2021-10-19 15:25:06 +08:00
Yifan Zhou 6f36717a72
[Unittest]: Test mmdeploy.pytorch (#133)
* add some tests

* Fix topk bug

* Fix bug in test

* Add remaining tests

* Remvoe debug code

* Delete redundant code

* Remove redundant code
2021-10-19 13:14:33 +08:00
VVsssssk 0f1cda0d3e
[Unittest]Add mmcv unit test (#128)
* add ncnn test exporter in test_ops.py

* add ncnn test exporter in utils.py

* add onnxruntime and tensorrt ops test

* fix blank line

* fix comment
add nms ops test

* remove nms test

* add test sample
add dockerstring

* remove nms test

* fix grid_sample
add type hind

* fix problem

* fix dockerstring

* add nms batch_nms multi_level_roi_align

* add test data

* fix problem

* rm pkl file dependent

* rm file

* add docstring

* remove multi_level_dependce

* add mmseg module unittest

* add mmseg test

* add mmseg model unit test

* fix blankline

* rename file

* add syncbn2bn unit test

* add apis/export

* lint

* lint

* ??

* delete#

* fix ncnn check

* fix problems

* fix problems

* add mmcv unit test

* add mmcv unit test

* modify scores

* fix format

* fix scores to rand

* remove blank line

Co-authored-by: SingleZombie <singlezombie@163.com>
2021-10-19 11:43:35 +08:00
q.yao fef9d9e651
[Docs]: Add how_to_support_new_model document (#123)
* Add how_to_support_new_model document

* update follow comments

* fix for comment

* rename
2021-10-18 11:08:27 +08:00
Yifan Zhou 26cf2bdf05
[Enhancement]: Clarify the return value of get_rewrite_outputs (#129)
* Modify function and its call

* fix typo
2021-10-15 16:18:32 +08:00
q.yao 2bd67527d5
[Docs]: Add readme zn-cn (#126)
* add readme zn-cn

* update punctuation
2021-10-15 11:52:53 +08:00
Yifan Zhou 10c4ef4203
[Unittest]: MMEdit unittest (#124)
* add mmedit test

* Solve unittest bug

* lint

* Remove debug code

* add data

* Refine code

* Fix ci

* Fix ci

* follow changes in mmdet test

* try to remove pytest skip

* remove redundant code

* rename

* Fix type hint

* Fix lint

* Refine SwitchBackendWrapper. Fix type hint

* update docstring
2021-10-15 10:25:48 +08:00
hanrui1sensetime 07cb78bb7c
[Unittest] add ncnn unittest expand and fix expand.cpp bugs. (#118)
* add ncnn unittest expand

* rollback utils.py

* remove figures
2021-10-14 10:24:14 +08:00
AllentDan d4828c7836
[Unittests] MMDet unittests (#112)
* add mmdet unittests

* remove redundant img meta info

* import wrapper from backend util

* force add wrapper

* use smaller nuance

* add seed everything

* add create input part and some inference part unittests

* fix lint

* skip ppl

* remove pyppl

* add dataset files

* import ncnn_ext inside ncnn warpper

* use cpu device to create input

* add pssd and ptsd unittests

* clear mmdet unittests

* wrap function to enable rewrite

* refine codes and resolve comments

* move mmdet inside test func

* remove redundant line

* test visualize in mmdeploy.apis

* use less memory

* resolve comments

* fix ci

* move pytest.skip inside test function and use 3 channel input
2021-10-13 17:24:11 +08:00
lvhan028 6fdf6b8616
apply cmake-format and refactor cmake scripts of building onnx and te… (#99)
* apply cmake-format and refactor cmake scripts of building onnx and tensorrt ops

* add static target

* suppress 'CMAKE_CUDA_ARCHITECTURES' warning when cmake with version 18 or later is used

* fix typo
2021-10-13 16:42:11 +08:00
hanrui1sensetime 1ed6bc0fb5
refactor ncnn ops unittest (#121) 2021-10-12 14:24:56 +08:00
hanrui1sensetime 46e0a3abc6
[Documentation] add ncnn backend docs (#122)
* add ncnn backend docs

* remove fix version

* reply for code review
2021-10-12 14:24:33 +08:00
RunningLeon 997f8dd9a9
add pylint score (#119)
* add pylint score

* add sc file

* Update build.yml

* Update build.yml

* Update build.yml

* auto load config file
2021-10-11 14:52:19 +08:00