Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable NonMaxSuppression-5 operation and various transformations #2450

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
277 commits
Select commit Hold shift + click to select a range
64ce75a
Some code style fixes.
vgavrilo Sep 29, 2020
74307ef
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Sep 29, 2020
88081f1
Started to write the method v5::NonMaxSuppression::evaluate().
vgavrilo Sep 29, 2020
9fcc842
Started to write nGraph reference implementation of NMS-5.
vgavrilo Sep 29, 2020
cb03dd6
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Sep 30, 2020
e610ce1
Some additions.
vgavrilo Sep 30, 2020
8461e57
Written preprocessing of boxes data.
vgavrilo Sep 30, 2020
4e0b656
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Sep 30, 2020
06b2edd
Started to write the function non_max_suppression() that calculates N…
vgavrilo Sep 30, 2020
06da1dd
Written postprocessing of the evaluate().
vgavrilo Sep 30, 2020
0b6ca39
Small fixes.
vgavrilo Sep 30, 2020
78b946d
Small fix.
vgavrilo Sep 30, 2020
14db60d
Added include for ngraph/shape.hpp.
vgavrilo Sep 30, 2020
951815a
Written the function intersectionOverUnion.
vgavrilo Oct 1, 2020
4992e48
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 1, 2020
8dd9b56
Some additions.
vgavrilo Oct 1, 2020
28076b4
Small fix.
vgavrilo Oct 1, 2020
f13d8b2
Continued to write the function non_max_suppression().
vgavrilo Oct 1, 2020
a1cc0f8
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 1, 2020
8287813
Small fixes.
vgavrilo Oct 1, 2020
8097591
Small fixes.
vgavrilo Oct 1, 2020
3a1b8ea
Some changes.
vgavrilo Oct 1, 2020
49f775d
Some additions.
vgavrilo Oct 1, 2020
4ff9f60
Some replacements size_t by int64_t.
vgavrilo Oct 2, 2020
04bab62
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 2, 2020
a6872da
Added casts to float in the construction of selected_score variable.
vgavrilo Oct 2, 2020
f64fced
Code style fixes.
vgavrilo Oct 2, 2020
2a29253
Written draft of NMS-5 nGraph reference implementation.
vgavrilo Oct 2, 2020
71a0888
Code style fixes.
vgavrilo Oct 2, 2020
5caeef7
Started to write tests for void op::v5::NonMaxSuppression::validate_a…
vgavrilo Oct 2, 2020
751b32c
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 2, 2020
01200aa
Added tests for scalars/nonscalars.
vgavrilo Oct 2, 2020
0eb5f40
Fixes in the test type_prop.nms_v5_output_shape.
vgavrilo Oct 2, 2020
ec034a2
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 2, 2020
b98be7f
Fixes in tests nms_v5_output_shape_2 and nms_v5_output_shape.
vgavrilo Oct 2, 2020
063c26b
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 5, 2020
1eda5ab
Written tests for validate_and_infer_types() of NMS-5.
vgavrilo Oct 5, 2020
0206db3
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 5, 2020
b3a6493
Code style fixes.
vgavrilo Oct 5, 2020
2ad0066
Now NMS-5 evaluate() can have outputs with calculated shapes.
vgavrilo Oct 5, 2020
136b6b7
Small fixes.
vgavrilo Oct 5, 2020
8a476c0
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 5, 2020
fe5a254
Corrected tests for NMS-5 validate_and_infer_type().
vgavrilo Oct 5, 2020
62c8fed
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 5, 2020
17dab01
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 6, 2020
1d06566
Code style fixes.
vgavrilo Oct 6, 2020
fed50cc
Started to write inner version of NMS-5 with static output shapes.
vgavrilo Oct 6, 2020
3830f51
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 6, 2020
924061b
Written draft of the inner operation NonMaxSuppressionIE3.
vgavrilo Oct 6, 2020
17df08d
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 6, 2020
8a57122
Started to write conversion of op::v5::NonMaxSuppression into NonMaxS…
vgavrilo Oct 6, 2020
44da98e
Small changes.
vgavrilo Oct 6, 2020
515361b
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 6, 2020
b112a2f
Some additions.
vgavrilo Oct 6, 2020
285ce50
Small fixes.
vgavrilo Oct 6, 2020
8063e01
Fixed typo.
vgavrilo Oct 7, 2020
e0f729f
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 7, 2020
c2db747
Fixed typos.
vgavrilo Oct 7, 2020
eb861a9
Written draft of the transformation ConvertNMS5ToLegacyMatcher that c…
vgavrilo Oct 7, 2020
88e1796
Written header file for the transformations from NMS-1, NMS-3, NMS-4 …
vgavrilo Oct 7, 2020
e662ec4
Started to write conversion of NMS-4 to NMS-5.
vgavrilo Oct 7, 2020
d8d0a19
Added include for ngraph/opsets/opset4.hpp.
vgavrilo Oct 7, 2020
f6d5ea0
Started to write conversion of NMS-3 to NMS-5.
vgavrilo Oct 7, 2020
4deba83
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 7, 2020
f2adb31
Small fixes.
vgavrilo Oct 7, 2020
17d14bc
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 7, 2020
8fa5661
Written draft of the conversion of NMS-3 into NMS-5.
vgavrilo Oct 7, 2020
57e4042
Fixed typo.
vgavrilo Oct 7, 2020
515dbb7
Started to write conversion of NMS-1 to NMS-5.
vgavrilo Oct 7, 2020
a0b0a3f
Written draft of the conversion NMS-1 to NMS-5.
vgavrilo Oct 7, 2020
56b52dd
Started to write tests for the conversion nGraph NMS-5 to inner NMS.
vgavrilo Oct 7, 2020
c2fb745
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 7, 2020
00e5c17
Started to write the test ConvertNMS5ToNMSIEStatic.
vgavrilo Oct 8, 2020
8f1be2c
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 8, 2020
97e6809
Written tests for conversion of nGraph NMS-5 to inner NMSIE3.
vgavrilo Oct 8, 2020
cb3eec1
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 8, 2020
ca75796
Started to write tests for conversion of previous NMS to nGraph NMS-5.
vgavrilo Oct 8, 2020
f561bc8
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 8, 2020
4221e15
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 8, 2020
deb6ff0
Written tests for conversion of old nGraph NMS to NMS-5.
vgavrilo Oct 9, 2020
cea396d
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 9, 2020
2a41688
Started to write tests for opset5::NonMaxSuppression::evaluate().
vgavrilo Oct 9, 2020
70769b6
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 9, 2020
c0aea2d
Some additions.
vgavrilo Oct 9, 2020
6944c1a
Small fix.
vgavrilo Oct 9, 2020
e865ab0
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 9, 2020
9494d73
Written tests for op::v5::NonMaxSuppression::evaluate().
vgavrilo Oct 13, 2020
4a18293
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 13, 2020
64aef64
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 14, 2020
54e89f5
Used NGRAPH_RTTI_DECLARATION for NonMaxSuppressionIE3.
vgavrilo Oct 14, 2020
61051a7
Used NGRAPH_RTTI_DECLARATION for NMS-5.
vgavrilo Oct 14, 2020
3e97da4
All static local constants and functions for NMS-5 were moved into no…
vgavrilo Oct 14, 2020
898eaf5
Some code style fixes.
vgavrilo Oct 14, 2020
7be0b58
Resolved merge conflicts.
vgavrilo Oct 14, 2020
5530ad0
Moved some file.
vgavrilo Oct 14, 2020
81afc9e
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 14, 2020
0acd1b8
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 14, 2020
5e412e5
Small fix.
vgavrilo Oct 14, 2020
8ec8adb
Code style fix.
vgavrilo Oct 14, 2020
d9d761d
Now NMS-5 supports all floating types in inputs 0 and 1.
vgavrilo Oct 14, 2020
ca4a399
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 14, 2020
83a0eea
Moved some files.
vgavrilo Oct 14, 2020
8428e20
Fixed include directive in the file convert_nms_5_to_legacy.cpp with …
vgavrilo Oct 14, 2020
571a7fd
Small changes.
vgavrilo Oct 14, 2020
3e68c6e
Resolved merge conflicts.
vgavrilo Oct 14, 2020
730cd6d
Deleted conversion NMS-3 -> legacy.
vgavrilo Oct 14, 2020
32337fc
Small changes.
vgavrilo Oct 14, 2020
24a6a2f
Fix in op::v5::NonMaxSuppression::evaluate: output shape [1] instead …
vgavrilo Oct 14, 2020
34a3730
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 15, 2020
c0f9697
Code style fixes.
vgavrilo Oct 15, 2020
ad6ea78
Deleted conversion of NMS-4 into legacy NMS.
vgavrilo Oct 15, 2020
0952f96
Deleted redundant ifs.
vgavrilo Oct 15, 2020
cfd7db4
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 15, 2020
44b6d09
Added NMS-5 to Python API.
vgavrilo Oct 15, 2020
cca2675
Code style fix.
vgavrilo Oct 15, 2020
d26b5c2
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 15, 2020
c2e181a
Small change.
vgavrilo Oct 15, 2020
7185197
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 15, 2020
27b2cd0
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 16, 2020
7597f30
Fixed element type for constants in the conversion of NMS-5 to NMSIE3.
vgavrilo Oct 16, 2020
debdf36
Deleted support of f64 in NMS-5.
vgavrilo Oct 16, 2020
3d9d2e4
Added checks for input element types for inputs #0, #1, #3, #4, #5.
vgavrilo Oct 16, 2020
e6cbf47
Small change.
vgavrilo Oct 16, 2020
8344cd1
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 16, 2020
e004a33
Now get_floats throws an exception for unsupported types.
vgavrilo Oct 16, 2020
ddea6e2
Now nGraph NMS-5 supports 0D and 1D tensors in inputs #2, #3, #4, #5.
vgavrilo Oct 16, 2020
c09b791
Small fix in test_non_max_suppression.
vgavrilo Oct 16, 2020
ab57157
Deleted using namespace std
vgavrilo Oct 16, 2020
53190d9
Fixes in test_non_max_suppression().
vgavrilo Oct 16, 2020
2e23b0a
Small fixes.
vgavrilo Oct 16, 2020
6885888
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 16, 2020
facc508
Added 'import PartialShape' in test_reduction.py.
vgavrilo Oct 16, 2020
4e27e35
Deleted creating fake inputs in the ctor of op::v5::NonMaxSuppression.
vgavrilo Oct 16, 2020
d00e892
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 16, 2020
8249034
Deleted creating fake inputs in op::v5::NonMaxSuppression::clone_with…
vgavrilo Oct 16, 2020
fcd2d00
Corrections in int64_t op::v5::NonMaxSuppression::max_boxes_output_fr…
vgavrilo Oct 16, 2020
635babd
Corrected functions float op::v5::NonMaxSuppression::soft_nms_sigma_f…
vgavrilo Oct 16, 2020
a11c13d
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 16, 2020
e1b4ee0
Small fixes.
vgavrilo Oct 16, 2020
3f14ed9
Deleted commented code.
vgavrilo Oct 16, 2020
6cc4fc9
Fixes in nms_v5_scalar_inputs_check.
vgavrilo Oct 16, 2020
7da307f
Some changes.
vgavrilo Oct 19, 2020
4ad9c8a
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 19, 2020
40adcbb
Small fixes.
vgavrilo Oct 19, 2020
83b14a8
Code style fixes.
vgavrilo Oct 19, 2020
f7da96d
Small changes.
vgavrilo Oct 19, 2020
743e87b
Small changes.
vgavrilo Oct 19, 2020
aacd4e9
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 19, 2020
db12b8a
Small fix.
vgavrilo Oct 19, 2020
eb04c97
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 19, 2020
b38e916
Deleted commented code.
vgavrilo Oct 19, 2020
fdbf03c
Some refactoring in ConvertNMS4ToNMS5 ctor.
vgavrilo Oct 19, 2020
ddc84b3
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 19, 2020
032e98b
Small fix.
vgavrilo Oct 19, 2020
0d739a9
Common part of conversions NMS-1 -> NMS-5, NMS-3 -> NMS-5, NMS-4 -> N…
vgavrilo Oct 19, 2020
7660244
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 20, 2020
525481b
Now conversions NMS-1 -> NMS-5, NMS-3 -> NMS-5, NMS-4 -> NMS-5 suppor…
vgavrilo Oct 20, 2020
398c2e0
Now transformations NMS-1 -> NMS-5, NMS-3 -> NMS-5, NMS-4 -> NMS-5 ar…
vgavrilo Oct 20, 2020
e208625
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 20, 2020
35c93ba
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 20, 2020
d122555
Now the transformation ConvertNMS5ToLegacyMatcher supports NMS-5 with…
vgavrilo Oct 20, 2020
a61629e
The transformation ConvertNMS5ToLegacyMatcher was rewritten using Res…
vgavrilo Oct 21, 2020
ac1f0c7
Resolved merge conflicts.
vgavrilo Oct 21, 2020
37b7b11
Started to rewrite tests for the transformation ConvertNMS5ToLegacyMa…
vgavrilo Oct 21, 2020
8fcf046
Some fixes.
vgavrilo Oct 21, 2020
33fe2f0
Small fixes.
vgavrilo Oct 21, 2020
eaba19f
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 21, 2020
3fbcb28
Corrected tests for the transformation NMS-5 -> NMSIE3.
vgavrilo Oct 21, 2020
a7383fc
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 21, 2020
707666a
Small formatting fix.
vgavrilo Oct 22, 2020
cdb77fa
Now methods max_boxes_output_from_input(), iou_threshold_from_input()…
vgavrilo Oct 22, 2020
3ab28d3
Started to move op::v5::NonMaxSuppression::evaluate() into ngraph/tes…
vgavrilo Oct 22, 2020
a0a562e
Added NMS-5 to ngraph/test/runtime/interpreter/int_executable.
vgavrilo Oct 22, 2020
6761c74
Small fixes.
vgavrilo Oct 22, 2020
02fb546
Code style fixes.
vgavrilo Oct 22, 2020
5ce0820
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 22, 2020
95a235f
Written draft test nonmaxsuppression_center_point_box_format_backend …
vgavrilo Oct 22, 2020
7a91c7a
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 22, 2020
13ee76e
Small fix.
vgavrilo Oct 22, 2020
c4f4edf
Written draft tests of NonMaxSuppression in ngraph/test/runtime.
vgavrilo Oct 22, 2020
33e15ce
Some changes.
vgavrilo Oct 23, 2020
dfe0849
Resolved merge conflicts.
vgavrilo Oct 23, 2020
b98c59a
Small changes.
vgavrilo Oct 23, 2020
355040d
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 23, 2020
7cc7aac
Disabled IE_CPU tests for NMS-5.
vgavrilo Oct 23, 2020
45d1ff7
Deleted op_eval tests for NMS-5.
vgavrilo Oct 23, 2020
304b54c
Deleted evaluate() method of NMS-5.
vgavrilo Oct 23, 2020
0fb6307
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 23, 2020
67e5140
Resolved merge conflicts.
vgavrilo Oct 23, 2020
977e7a9
Now all nGraph functions in tests of the transformation NMS-5 -> NMSI…
vgavrilo Oct 23, 2020
690e6ed
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 23, 2020
cdc5d68
Now preprocessing and postprocessing of the calculation of NMS-5 in r…
vgavrilo Oct 23, 2020
795f00f
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 23, 2020
ab5a374
Code style fixes.
vgavrilo Oct 23, 2020
0b690a4
Some fixes in tests for the transformation NMS-5 -> NMSIE3.
vgavrilo Oct 23, 2020
2119633
Replaced precision i64 -> i32 for some constants in tests for the tra…
vgavrilo Oct 23, 2020
11bd9e6
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 23, 2020
7b3a64c
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 24, 2020
5cbdf1f
Written creating CNNLayer for NMS-5.
vgavrilo Oct 24, 2020
c2f5ab2
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 24, 2020
edd5ec6
Merge branch 'vgavrilo/update-ie-ir-reader-for-nms-5' of https://gith…
vgavrilo Oct 25, 2020
c19e54f
Added creating CNNLayer for NonMaxSuppressionIE3.
vgavrilo Oct 25, 2020
49517d1
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 25, 2020
e192102
Merge branch 'vgavrilo/update-ie-ir-reader-for-nms-5' of https://gith…
vgavrilo Oct 26, 2020
d9232f0
some changes.
vgavrilo Oct 26, 2020
a01d608
Now conversions NMS-1, NMS-3, NMS-4 -> NMS-5 and NMS-5 -> NMSIE3 gen…
vgavrilo Oct 27, 2020
cbae8cf
Fixed ctor in MKLDNN NonMaxSuppressionImpl: validation of number of o…
vgavrilo Oct 27, 2020
3c4536b
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 27, 2020
14b7b92
Merge branch 'vgavrilo/update-ie-ir-reader-for-nms-5' of https://gith…
vgavrilo Oct 27, 2020
70ffa57
Added conversion of output_type for NMS-5.
vgavrilo Oct 27, 2020
730ec8a
Fixes in the transformation NMS5 -> NMSIE3.
vgavrilo Oct 27, 2020
f41affc
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 27, 2020
45da4c7
Fixes in the conversion of NMS-5 to NMSIE3.
vgavrilo Oct 28, 2020
b7f3de0
Fixes in MKLDNN NMS ctor.
vgavrilo Oct 28, 2020
230ed5f
Small fix.
vgavrilo Oct 28, 2020
29eca21
Fixed tests for the transformation NMS5 -> NMSIE3.
vgavrilo Oct 28, 2020
98b402f
Fixed tests for conversions NMS-1, NMS-3, NMS-4 -> NMS-5.
vgavrilo Oct 28, 2020
d3d7faa
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 28, 2020
fbba3a3
Small fixes in MKLDNN NMS ctor.
vgavrilo Oct 29, 2020
4fc8955
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 29, 2020
259ba7f
Rewritten create_layer() functions for NMS-5 and NMSIE3 as addSpecifi…
vgavrilo Oct 29, 2020
658a6b2
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 29, 2020
b18dcf8
Resolved merge conflict.
vgavrilo Oct 30, 2020
13df494
Disabled tests for IE IR reader for NMS-4.
vgavrilo Oct 30, 2020
28f970f
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Oct 30, 2020
d9af6a8
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 2, 2020
2af2c2c
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 3, 2020
d82f3e1
Deleted debug code.
vgavrilo Nov 3, 2020
28f1cb2
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 3, 2020
007b895
Added comment about disabling tests IE_CPU.nonmaxsuppression.
vgavrilo Nov 3, 2020
2d7a634
Written IE IR Reader test for NMS-4.
vgavrilo Nov 3, 2020
9c6a5a9
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 3, 2020
c6476e2
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 5, 2020
0e1e135
Deleted function float_from_constant_node.
vgavrilo Nov 5, 2020
12bf087
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 5, 2020
c10979b
Small fixes.
vgavrilo Nov 5, 2020
34c47a9
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 5, 2020
1e10629
Deleted functions function_from_model and construct_weights.
vgavrilo Nov 5, 2020
a11cd97
Small fix.
vgavrilo Nov 5, 2020
b75f54b
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 5, 2020
c86a7cd
Replaced push_back with emplace_back in the conversion of NMS-5 to le…
vgavrilo Nov 5, 2020
8a1f6a8
Small changes.
vgavrilo Nov 5, 2020
4e4fdee
Some fixes.
vgavrilo Nov 5, 2020
a490b80
Resolved merge conflicts.
vgavrilo Nov 6, 2020
dddf4dc
Refactored reference implementation of NMS-5.
vgavrilo Nov 6, 2020
8b4d5d7
Merge remote-tracking branch 'upstream/master' into vgavrilo/update-i…
vgavrilo Nov 6, 2020
11863f1
Moved structure NMSAttributes to unnamed namespace.
vgavrilo Nov 6, 2020
db454e9
Code style fixes.
vgavrilo Nov 6, 2020
279c2d9
Small fix.
vgavrilo Nov 6, 2020
32f13d6
Resolved merge conflict.
vgavrilo Nov 6, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions inference-engine/src/legacy_api/include/legacy/ie_layers.h
Original file line number Diff line number Diff line change
Expand Up @@ -2064,6 +2064,10 @@ class INFERENCE_ENGINE_INTERNAL_CNNLAYER_CLASS(NonMaxSuppressionLayer): public C
* classes
*/
bool sort_result_descending = true;
/**
* @brief Output type for first and third inputs
*/
std::string output_type = "I64";
/**
* @brief Creates a new NonMaxSuppressionLayer instance.
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,15 @@ class INFERENCE_ENGINE_API_CLASS(NonMaxSuppressionIE3) : public Op {
public:
NGRAPH_RTTI_DECLARATION;

NonMaxSuppressionIE3(const Output<Node>& boxes,
const Output<Node>& scores,
const Output<Node>& max_output_boxes_per_class,
const Output<Node>& iou_threshold,
const Output<Node>& score_threshold,
int center_point_box,
bool sort_result_descending,
const ngraph::element::Type& output_type = ngraph::element::i64);

NonMaxSuppressionIE3(const Output<Node>& boxes,
const Output<Node>& scores,
const Output<Node>& max_output_boxes_per_class,
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -14,18 +14,20 @@
namespace ngraph {
namespace pass {

class TRANSFORMATIONS_API ConvertNMS1ToNMS3;
class INFERENCE_ENGINE_API_CLASS(ConvertNMS5ToLegacyMatcher);

} // namespace pass
} // namespace ngraph

class ngraph::pass::ConvertNMS1ToNMS3: public ngraph::pass::GraphRewrite {
/*
* Description:
* Convert NMS-5 directly to inner NMS.
*/


class ngraph::pass::ConvertNMS5ToLegacyMatcher: public ngraph::pass::MatcherPass {
public:
NGRAPH_RTTI_DECLARATION;
ConvertNMS1ToNMS3() : GraphRewrite() {
convert_nms1_to_nms3();
}

private:
void convert_nms1_to_nms3();
ConvertNMS5ToLegacyMatcher();
};

Original file line number Diff line number Diff line change
Expand Up @@ -653,6 +653,83 @@ InferenceEngine::details::CNNLayerCreator::CNNLayerCreator(const std::shared_ptr

});

addSpecificCreator({"NonMaxSuppressionIE3"}, [](const std::shared_ptr<::ngraph::Node>& node,
const std::map<std::string, std::string>& params) -> CNNLayerPtr {
LayerParams attrs = {node->get_friendly_name(), "NonMaxSuppression",
details::convertPrecision(node->get_output_element_type(0))};

auto castedLayer = ::ngraph::as_type_ptr<::ngraph::op::NonMaxSuppressionIE3>(node);
IE_ASSERT(castedLayer) << " Operation " << node->description() << " with name "
<< node->get_friendly_name() << " cannot be casted to ngraph::op::NonMaxSuppressionIE3";

auto res = std::make_shared<InferenceEngine::NonMaxSuppressionLayer>(attrs);
res->params = params;

res->params["center_point_box"] = castedLayer->m_center_point_box ? "true" : "false";
res->params["sort_result_descending"] = castedLayer->m_sort_result_descending ? "true" : "false";

auto output_type = details::convertPrecision(castedLayer->m_output_type);
std::string output_type_str;
switch (output_type) {
case Precision::I32:
output_type_str = "I32";
break;
case Precision::I64:
output_type_str = "I64";
break;
default:
THROW_IE_EXCEPTION << "Unsupported output type";
}
res->params["output_type"] = output_type_str;

return res;
});

addSpecificCreator({"NonMaxSuppression"}, [](const std::shared_ptr<::ngraph::Node>& node,
const std::map<std::string, std::string>& params) -> CNNLayerPtr {
LayerParams attrs = {node->get_friendly_name(), "NonMaxSuppression",
details::convertPrecision(node->get_output_element_type(0))};

auto castedLayer = ::ngraph::as_type_ptr<::ngraph::op::v5::NonMaxSuppression>(node);
IE_ASSERT(castedLayer) << " Operation " << node->description() << " with name "
<< node->get_friendly_name() << " cannot be casted to ngraph::op::v5::NonMaxSuppression";

auto res = std::make_shared<InferenceEngine::NonMaxSuppressionLayer>(attrs);
res->params = params;

auto box_encoding = castedLayer->get_box_encoding();
switch (box_encoding) {
case ngraph::op::v5::NonMaxSuppression::BoxEncodingType::CORNER:
res->params["center_point_box"] = "false";
break;
case ngraph::op::v5::NonMaxSuppression::BoxEncodingType::CENTER:
res->params["center_point_box"] = "true";
break;
default:
THROW_IE_EXCEPTION << "Unsupported box encoding for NonMaxSuppression op";
break;
}

auto output_type = details::convertPrecision(castedLayer->get_output_type());
std::string output_type_str;
switch (output_type) {
case Precision::I32:
output_type_str = "I32";
break;
case Precision::I64:
output_type_str = "I64";
break;
default:
THROW_IE_EXCEPTION << "Unsupported output type";
}
res->params["output_type"] = output_type_str;

bool sort_result_descending = castedLayer->get_sort_result_descending();
res->params["sort_result_descending"] = sort_result_descending ? "true" : "false";

return res;
});

addSpecificCreator({"NonMaxSuppressionIE"}, [](const std::shared_ptr<::ngraph::Node>& node,
const std::map<std::string, std::string>& params) -> CNNLayerPtr {
LayerParams attrs = {node->get_friendly_name(), "NonMaxSuppression", details::convertPrecision(node->get_output_element_type(0))};
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1181,6 +1181,7 @@ void NMSValidator::parseParams(CNNLayer* layer) {

casted->center_point_box = layer->GetParamAsBool("center_point_box", false);
casted->sort_result_descending = layer->GetParamAsBool("sort_result_descending", true);
casted->output_type = layer->GetParamAsString("output_type", "I64");
}

#define REG_LAYER_VALIDATOR_FOR_TYPE(__validator, __type) _validators[#__type] = std::make_shared<__validator>(#__type)
Expand Down
22 changes: 20 additions & 2 deletions inference-engine/src/legacy_api/src/ngraph_ops/nms_ie.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,20 @@ void op::NonMaxSuppressionIE2::validate_and_infer_types() {
set_output_type(0, nms->output(0).get_element_type(), nms->output(0).get_partial_shape());
}

NGRAPH_RTTI_DEFINITION(op::NonMaxSuppressionIE3, "NonMaxSuppressionIE", 3);
NGRAPH_RTTI_DEFINITION(op::NonMaxSuppressionIE3, "NonMaxSuppressionIE3", 3);

op::NonMaxSuppressionIE3::NonMaxSuppressionIE3(const Output<Node>& boxes,
const Output<Node>& scores,
const Output<Node>& max_output_boxes_per_class,
const Output<Node>& iou_threshold,
const Output<Node>& score_threshold,
int center_point_box,
bool sort_result_descending,
const ngraph::element::Type& output_type)
: Op({boxes, scores, max_output_boxes_per_class, iou_threshold, score_threshold}),
m_center_point_box(center_point_box), m_sort_result_descending(sort_result_descending), m_output_type(output_type) {
constructor_validate_and_infer_types();
}

op::NonMaxSuppressionIE3::NonMaxSuppressionIE3(const Output<Node>& boxes,
const Output<Node>& scores,
Expand Down Expand Up @@ -139,8 +152,13 @@ static constexpr size_t max_output_boxes_per_class_port = 2;
int64_t op::NonMaxSuppressionIE3::max_boxes_output_from_input() const {
int64_t max_output_boxes{0};

size_t num_of_inputs = inputs().size();
if (num_of_inputs < 3) {
return 0;
}

const auto max_output_boxes_input =
as_type_ptr<op::Constant>(input_value(2).get_node_shared_ptr());
as_type_ptr<op::Constant>(input_value(max_output_boxes_per_class_port).get_node_shared_ptr());
max_output_boxes = max_output_boxes_input->cast_vector<int64_t>().at(0);

return max_output_boxes;
Expand Down

This file was deleted.

Loading