Commit Graph

159 Commits

Author SHA1 Message Date
Vladislav Vinogradov
8331c397cd [IE][NGRAPH][BUILD] Enable UNITY build for more targets (#2592)
* Avoid symbols clash due to source merging.
* Tested on Ubuntu 20.04 with GCC 9.3.0.
2020-10-13 17:35:55 +03:00
Mateusz Tabaka
24b2c41f3a Tests and docs for registering custom ONNX operators (#2416)
* Add tests, examples and documentation changes for custom ONNX operators registration mechanism

* Change snippet paths

* fix CoreThreadingTests.ReadNetwork - data race in ops_bridge

* Make TemplateExtension::Operation externally visible

* changes after review

* apply code format

* use std::int64_t

* forward declare get_attribute_value specializations

* introduce unregister_operator in onnx_importer

* onnx_custom_op - lock mem first then take a buffer

* func tests - create template_extension via make_so_pointer

* fix build with NGRAPH_ONNX_IMPORT_ENABLE=OFF

* remove exports from Operation and Extension

* Move multithreaded AddExtension test to different directory to it can be excluded when NGRAPH_ONNX_IMPORT_ENABLE=OFF

* Dont include Extension tests if ENABLE_MKL_DNN=OFF

* fix excluding onnx_reader tests

* include extension tests only if mkl is enabled

* add comment on empty blob

* use register_operator conditionally in template_extension

* fix docs after review

* create static library from onnx_custom_op

* add additional test for unregister_operator

* move model example after register step

* revert changes to unit tests

* update ngraphConfig.cmake.in header

* add headers to onnx_custom_op

* changes to docs CMakeLists

* remove redundant onnx_importer dependency

* remove extension directory from func tests

* make onnx_importer a component of ngraph package

* docs fixes

* update header of ngraph/cmake/share/ngraphConfig.cmake.in with ngraph_onnx_importer_FOUND
2020-10-12 07:36:19 +03:00
Katarzyna Mitrus
00faee86e0 Update ONNX importer LSTM to use v5 LSTMSequence (#2511) 2020-10-09 15:24:10 +02:00
Gleb Kazantaev
2e49b4e4d8 Fine-Grain Transformation pipeline tuning (#2547)
* Initial version of transformation callback refactoring

* Improved fine-grain tuning for transformation pipeline

* Check disabled matchers in GraphRewrite

* Avoid deprecated classes inside PassConfig

* Enabled DepthToSpace fusion by default

* Removed doulbe search in map

* Moved back pass_config.hpp; Added doxygen documentation for new class and methods

* Added doxygen comment for Manager and GraphRewrite new mthods
2020-10-09 15:33:19 +03:00
Gleb Kazantaev
3f55733b43 Updated ConstantFolding pass to propagate friendly name (#2572)
* Fixed concat output name when decomposing shape_of in CF

* Added friendly_name propagation for CF pass

* Propagate runtime info inside ConstantFolding pass

* Fixed rt info merge strategy to avoid cases when merge is not implemented but attributes number is equal to 1
2020-10-08 09:16:28 +03:00
Liubov Batanina
7f78dd797e [IE Tests] Added NormalizeL2 tests (#2327)
* Added NormalizeL2 tests

* Added NormalizeL2 reference

* Add nGraph tests

* Fix tests

* Added NormalizeL2 builder
2020-10-08 07:23:25 +03:00
Bartosz Lesniewski
8f95e22a5c CTCGreedyDecoder reference implementation (#2284) 2020-10-07 13:44:56 +02:00
Tomasz Dołbniak
14416405cc Re-enable more unit tests (Resize & Interpolate) (#2331) 2020-10-06 10:53:02 +02:00
Mateusz Bencer
7784b97bbc Relax shape inference for Split:v1 (#2444)
* Relaxed shape inference for Split

* added unit tests

* review remarks
2020-10-01 20:29:19 +03:00
Mateusz Tabaka
fd80873fca Add support for custom ONNX GroupNorm operator (#2267) 2020-09-30 16:17:15 +02:00
helmutg
f858b0c46f drop unnecessary cmake dependency on ext_gtest (#2389)
ngraph_test_util links libgtest, which depends on ext_gtest already.

Co-authored-by: Helmut Grohne <helmut.grohne@intenta.de>
2020-09-30 16:01:11 +03:00
Mateusz Bencer
3e2a131441 Added support of external data for ONNX Importer (#2303) 2020-09-28 11:08:36 +02:00
Katarzyna Mitrus
8f843c620a [ONNX] Update ONNX importer to use RNN/GRU Sequence ops (#2035) 2020-09-23 10:11:34 +02:00
Bartosz Lesniewski
9af49a7f95 Reference ROIAlign-3 implementation (#2128) 2020-09-21 14:04:39 +02:00
Ivan Tikhonov
61a7cdde23 Introduce opset5, include GRU/RNN/LSTM Sequences to opset5 (#2265)
* introduce new opset5, include GRU/RNN/LSTM Sequences to opset5

* resolve review remarks
2020-09-18 21:26:21 +03:00
Ilya Lavrenov
147a508a51 fixes for UWP (#2255)
* UWP fixes

* Commented code for compilation with UWP

* Current state: compiled for DESKTOP_APP

* Fixes

* Added toolchain

* Enabled ONNX imported for Windows Store

* Updated toolchain

* Fixes

* Disable ONNX in case of UWP

* Fix for Windows Driver

* Applied style check

* Dynamic loading of GetDLLDirectory symbols

* Clean-up in the toolchain

* Updated mkldnn plugin cmake
2020-09-18 17:13:27 +03:00
Tomasz Dołbniak
a0da3d360c Accept ONNX Constants with empty tensors (#2287) 2020-09-18 10:08:29 +02:00
Piotr Szmelczynski
1337997134 Test refactor (#2225) 2020-09-16 15:33:02 +02:00
Ilya Churaev
e3174fa752 nGraph some KW fixes (#2102)
* Removed redundant methods

* Fixed KW for linux
2020-09-15 14:03:07 +03:00
Vladislav Volkov
ba254d7669 Fix for static PartialShape detection algorithm (#2106) 2020-09-11 06:15:24 +03:00
Mateusz Tabaka
926be83568 Add support for custom onnx operators: DetectionOutput, Normalize and… (#2064) 2020-09-10 11:27:12 +02:00
Michał Karzyński
fe4d720b69 Temporarily disable ONNX Loop operator for the 2021.1 release (#2110) 2020-09-09 12:07:02 +02:00
Ivan Tikhonov
063c7ef6b9 GRU/RNN/LSTM sequence ops, reference implementations, single layer tests (#1594)
* gru/rnn sequences

* update gru/rnn sequences ops, add unit tests

* enable sequence transformations for cpu plugin

* ngraph codestyle

* update tensor iterator to rnn/gru/lstm sequence transformations, add unit tests

* ngraph codestyle

* add visitors for ngraph ie ops, fix a bug with incorrect axis, fix ngraph to ngraph ie conversion

* update GRUSequence/GRUSequenceIE according to plugin format

* fix ngraph ie implementations according to plugins restricrictions

* fix naming issue

* adapt unit tests to accordance to new changes

* strict checks, additional unit tests

* add descriptions for transformations, fix unit tests

* enable ti to sequnece and unroll transformations in plugins for testing

* disable tensor iterator ngraph reader tests

* delete unnecessary cmake file

* fix includes

* clean up, resolve review comments

* move ti to sequence transformation to ti folder

* validate_and_infer_types() implementation

* input parameter validation for LSTM, GRU and RNN

* style-check applied

* Add LSTMSequence dynamic shape validation and test props for RNNCell, GRUCell, LSTMCell and LSTMSequence.

* recurrent_sequence.hpp moved to ngraph/core/include/ngraph/op/util/

* style check applied

* removed unused variable from LSTMSequence::validate_and_infer_types

* Add missing newline mark at the end of file.

* Add supression macro for FusedOp deprecation.

* Add element type initialization

* transpose,rnn cell reference implementations

* Apply PR review remarks

* reference implementations for cells op, single layer tests, align lstm cell/sequence according to the spec

* lstm/gru/rnn cell decompostion transformations

* ngraph codestyle

* clean up

* ngraph code style

* change inheritance of Cells, fix build

* fix build

* fix build again

* remove Peepholes from LSTMSeq, fix copy_runtime_info in transformations

* Rewrite tests to use gtest exception assertions.

* resolve tests issues

* ngraph codestyle

* add missed files

* fix typeprop tests

* fix lstm sequence checks

* fix arm build

* fix arm again

* delete unnecessary file

* add convert weghts format function, enable lstm test, resolve review comments

* add ngraph builders

* ngraph codestyle

* fix unit tests

* revert transpose reference implementation

* move ti to sequences transformation to another branch, resolve review comments

* resolve review comments

* revert fix in ie_layer_validators

* revert LSTM Cell v0, add LSTMCell v1, update transformation lstm_cell_to_cell_ie

* v1 version of LSTMCell op

* LSTMSequence v1 operation, exclude LSTMSeq from opset4

* fix python api tests

* resolve review comments, tests for decomposition transformations, switch lstm cell to opset4 in mo

* references impl for RNN/GRU/LSTM Sequences, single layer tests, bidirectional transformation

* fix unit tests

* process dynamic ranks of rnn/gru/lstm ops

* remove sequences specifications from opset4

* resolve review comments

* fix validate_and_infer_types of GRU/RNN sequences

Co-authored-by: Szymon Durawa <szymon.durawa@intel.com>
2020-09-08 10:31:44 +03:00
Maksim Kutakov
2c7f06e08f [IE TESTS] GatherTree single layer test has been created. (#2006)
* [IE TESTS] GatherTree op ref function has been created.

* [IE TESTS] Added GatherTree single layer test

* [IE TESTS] Fixed code styles.

* [IE TESTS] GatherTree test FP32 precion was enabled.

* [IE TESTS] Refactoring of Builder::makeConstatn procedure

The refactoring is aimed at managing the range of random data for the constants initialization procedure.

* [IE TESTS] GatherTree test was extended with constants

* [IE TESTS] GatherTree ref rewritten to non-templated function.

* [IE TESTS] GatherTree test inp shape indx enum removed.

* Revert "[IE TESTS] Refactoring of Builder::makeConstatn procedure"

This reverts commit 2648172e00ccca266d39e8775b890b8a8395f57c.

* [IE TESTS] makeConstant was augmented with random data range parameters.

* [IE TESTS] GatherTree test was rewritten using makeConstant function.

* [IE TESTS] GaterTree test call templated makeConstant

* [IE TESTS] GaterTree test code style fix
2020-09-07 17:17:14 +03:00
Tomasz Dołbniak
52ebe68cc7 v1::AvgPooling type prop unit tests (#2013) 2020-09-07 16:05:19 +02:00
Jozef Daniecki
8e9b733534 HostTensor2Vector (#2027)
* Add host_tesnor_2_vector() implementation and unit tests. One reference OP refactored to use it.

* Ngraph assertion message refactored.

Co-authored-by: Tomasz Dołbniak <tomasz.dolbniak@intel.com>

* Fix style.

Co-authored-by: Tomasz Dołbniak <tomasz.dolbniak@intel.com>
2020-09-04 16:02:14 +03:00
Ivan Tikhonov
2f5a28d44f LSTMCell/Sequence v1, reference implementations and decompose transformations for LSTM/GRU/RNN Cells (#2000)
* validate_and_infer_types() implementation

* input parameter validation for LSTM, GRU and RNN

* style-check applied

* Add LSTMSequence dynamic shape validation and test props for RNNCell, GRUCell, LSTMCell and LSTMSequence.

* recurrent_sequence.hpp moved to ngraph/core/include/ngraph/op/util/

* style check applied

* removed unused variable from LSTMSequence::validate_and_infer_types

* Add missing newline mark at the end of file.

* Add supression macro for FusedOp deprecation.

* Add element type initialization

* transpose,rnn cell reference implementations

* Apply PR review remarks

* reference implementations for cells op, single layer tests, align lstm cell/sequence according to the spec

* lstm/gru/rnn cell decompostion transformations

* ngraph codestyle

* clean up

* ngraph code style

* change inheritance of Cells, fix build

* fix build

* fix build again

* remove Peepholes from LSTMSeq, fix copy_runtime_info in transformations

* Rewrite tests to use gtest exception assertions.

* resolve tests issues

* ngraph codestyle

* add missed files

* fix typeprop tests

* fix lstm sequence checks

* fix arm build

* fix arm again

* delete unnecessary file

* add convert weghts format function, enable lstm test, resolve review comments

* add ngraph builders

* ngraph codestyle

* fix unit tests

* revert transpose reference implementation

* revert LSTM Cell v0, add LSTMCell v1, update transformation lstm_cell_to_cell_ie

* v1 version of LSTMCell op

* LSTMSequence v1 operation, exclude LSTMSeq from opset4

* fix python api tests

* resolve review comments, tests for decomposition transformations, switch lstm cell to opset4 in mo

Co-authored-by: Szymon Durawa <szymon.durawa@intel.com>
2020-09-04 09:04:36 +03:00
Ilya Churaev
28eed7708e Removed builders from public API (#2059)
* Removed builders from public API

* Fixed build
2020-09-04 06:06:43 +03:00
Vladimir Gavrilov
e6a36123db Reverted conversion of Resize-10 to Interpolate-4 in ONNX Importer. (#2048)
* Reverted conversion of Resize-10 to Interpolate-4. Now Resize with opset version < 11 generates Interpolate-1 again.

* Corrected tests.
2020-09-03 19:34:35 +03:00
Ilya Churaev
6f83889886 Fixed a case with empty order in transpose op (#2043)
* Fixed a case with empty order in transpose op

* Fixed comments

* Fixed transpose tests

* Fixed tests
2020-09-03 14:50:01 +03:00
Katarzyna Mitrus
54a24b0e40 [ONNX] Enable ScatterND operator in ONNX importer (#1987)
* Enable ONNX scatter_nd

* Tests update
2020-09-01 12:10:03 +03:00
Szymon Durawa
b58e982e6a Dynamic shape cell (#1683)
* validate_and_infer_types() implementation

* input parameter validation for LSTM, GRU and RNN

* style-check applied

* Add LSTMSequence dynamic shape validation and test props for RNNCell, GRUCell, LSTMCell and LSTMSequence.

* recurrent_sequence.hpp moved to ngraph/core/include/ngraph/op/util/

* style check applied

* removed unused variable from LSTMSequence::validate_and_infer_types

* Add missing newline mark at the end of file.

* Add supression macro for FusedOp deprecation.

* Add element type initialization

* Apply PR review remarks

* Rewrite tests to use gtest exception assertions.
2020-09-01 12:01:20 +03:00
Vladimir Gavrilov
7a74792ac4 Intepolate-4 nGraph operation (#1412)
* Fixed prototype of evaluate method.

* Rewritten Interpolate-4 ctors (added argument output_shape). Corrected tests.

* Fixed typo.

* Fixed number of args of make_shared in op::v4::Interpolate::clone_with_new_inputs.

* Fixes in Interpolate-4 tests.

* Now ONNX Upsample-1 is readed as Interpolate-4 with 4 inputs.

* Code style fixes.

* Some fixes in Interpolate-4 layer test.

* Now ONNX Upsample-9 is readed as Interpolate-4 with 4 inputs.

* Small fixes.

* Some changes.

* Fixed processing of 'scales' input in evaluation of Interpolate-4: now 'scales' contains scales only from 'axes'.

* Fixes in documentation.

* Now reference implementation of Interpolate-4 is rewritten for using 3 required inputs.

* Some code style fixes.

* Small fix.

* Started to write tests for method evaluate() of Interpolate-4.

* Continued to write tests for evaluate() of Interpolate-4.

* Some fixes.

* Some additions.

* Written draft of tests for 'cubic' mode with using scales.

* Some changes.

* Started to write tests for 'nearest' mode.

* Started to write tests for 'linear_onnx' mode.

* Some changes.

* Small fixes.

* Added setup of output type.

* Small addition.

* Added debug print into Interpolate-4 evaluate.

* Now in Interpolate-4 evaluation tests 3 inputs of Interpolate are Constants.

* Small changes.

* Added some debug print.

* Added more debug print.

* Some fixes.

* Now 4th argument of runtime::interpolate has type std::vector<int64_t>.

* Added checks for result of calculations.

* Added another expected values vector for the mode 'cubic'.

* Temporarily commented result value checks  for the cubic mode.

* Written tests for 'nearest' mode.

* Some reorganization.

* Written tests for 'linear_onnx' mode.

* Fixed padding loop.

* Fixed docs for 'linear_onnx' mode.

* Written tests for 'cubic' mode.

* Deleted debug print.

* Fixed code style.

* Enabled CPU layer tests for Interpolate-4.

* Reverted changes of this file.

* Now ONNX importer reads Resize-1 as Interpolate-4 with 4 inputs.

* Now ONNX importer reads Resize-11 as Interpolate-4 with 4 inputs.

* Small fixes.

* Fixed docs.

* Added small epsilon in the shape calculation in the function op::v4::Interpolate::infer_using_scales.

* Small fix.

* Reduced size of the template function eval().

* Now the 'nearest' mode is rewritten to CoordinateTransfom instead of NDim* classes

* Now the 'cubic' mode is rewritten to use CoordinateTransformation instead of NDim classes.

* Started to rewrite 'linear' mode using CoordinateTransform.

* Started to write helper class.

* Small fix.

* Small changes.

* Some fix.

* Fixed typo.

* Now the preamble of 'linear_onnx' mode implementation is a method of helper class.

* Now the function clip_coord is the method of helper class, and the mode 'linear' uses CoordinateTransform instead of NDim classes.

* Deleted NDim classes.

* Some fixes.

* Some refactoring.

* Some refactoring: now inner calculation of 'linear' is in helper class.

* Moved reference implementation of Interpolate-4 into library with reference implementations.

* Small fix.

* Deleted commented tests.

* Code stile fixes.

* Deleted redundant type prop tests for Interpolate-4.

* Documentation fixes.

* Disabled IE_CPU tests for ONNX Resize: Interpolate-4 is not implemented in plugins.

* Temporarily disabled some ONNX tests.

* Some refactoring: deleted redundant attributes of InterpolateEval class.

* Small fix.

* Added NGRAPH_RTTI_DECLARATION and NGRAPH_RTTI_DEFINITION.

* Added debug print to 'cubic' mode calculation.

* Some deletions.

* Small fix.

* Fixed typos.

* Added another debug print.

* Now indices_shape is constructed from std::vector<std::size_t>(num_of_axes, 4) again.

* Fixed CMakeLists.txt.

* Small fix.

* Added more debug print.

* Fixed typo.

* Fixed calculation of the first argument of helper.clip_coord in the inner loop of cubic_func.

* Some code style fixes.

* Alphabetically sorted operations of opset4.

* Deleted constant cannot_define_axes.

* Used std::iota instead of loop.

* Renamed structure InfoToCallReference.

* Now void op::v4::Interpolate::validate_and_infer_types() checks an element type of an input tensor.

* Code style fix.

* Changes in reading of ONNX Resize and Upsample: we generate Interpolate-4 without 'axes' input.

* Now bodies of functions evaluate_interpolate_v4() and inline bool evaluate() are moved in the method bool op::v4::Interpolate::evaluate.

* Fixes in example of the documentation of Interpolate-4.

* Fixed typos.

* Small fix.

* Some fixes.

* Deleted some type aliases.

* Uncommented a test for 'cubic' mode.

* Small code style fix in bool op::v4::Interpolate::evaluate.

* Uncommented more test for Interpolate-4 reference implementation.

* Added more debug print.

* Some changes.

* Uncommented all tests for Interpolate-4 evaluate().

* Deleted debug print.

* Deleted 'simple' mode from the map nearest_mode_map.

* Code style fixes.

* Disabled some CPU tests.

* Some fixes.

* Small fixes.

* Some fixes.

* Fixed typo.

* Fixed typo.

* Small change.

* Fixed some typos.

* Fixed some typos.

* Fix in operator() of the class GetOriginalCoordinate.

* Disabled some CPU tests.

* Small changes.

* Deleted template function from resize.cpp.

* Code style fixes.

* Refactored the method op::v4::Interpolate::evaluate.

* Added documentation for infer_using_scales() and infer_using_shapes().

* Added documentation for classes GetNearestPixel and GetOriginalCoordinate.

* Small fixes.

* Some code style fixes.

* Small fixes.

* Some changes.

* Added NGRAPH_SUPPRESS_DEPRECATED_START and NGRAPH_SUPPRESS_DEPRECATED_END for using v0::InterpolateAttrs; and using v0::Interpolate;

* Code style fix.

* Enabled ONNX import only tests for Resize-10, Upsample-8, Upsample-9.

* Fixed element type for scales_const. Fixed targetShapes and pads in single layer tests.

* Small changes.

* Added conversion from NGRAPH to CNNLayer.

* Added documentation for the class InterpolateEval.

* Now 'nearest' mode has special tests in cpu single layer tests.

* Small changes.

* Fixes in cpu single layer tests.

* Temporarily commented Interpolate-4 in ConvertFunctionToCNNNetworkTests.

* Added some docs.

* Enabled some tests for Resize-11.

* Added test.

* Corrected expected values in the resize_downsample_scales_align_corners case.

* Added more test for the 'cubic' mode.

* Added more test for linear_onnx mode.

* Deleted debug print for linear_onnx mode.

* Deleted debug prints. Added yet another test for 'nearest' mode.

* Fixes for import of ONNX Resize-10 and Upsamples.

* Applyed Evgeny Lazarev fix for Interpolate-4 infer function.

* Code style fixes.

* Some tests were deleted from unit_test.manifest file for INTERPRETER.

* Deleted test for downscale Resize-10: results of infer are correct, but comparison is not.

* Enabled test INTERPRETER.onnx_empty_initializers_handling.

* Some fixes.

* Added the method run_with_tolerance_as_fp() to the class TestCase and the method compare_results_with_tolerance_as_fp() to the class TestCaseEngine.

* Small fix.

* Small fix.

* Added yet another type_prop test.

* Disabled CPU test IE_CPU.onnx_empty_initializers_handling.

* Code style fixes.

* Enabled some ONNX tests.

* Some changes.

* Code style fix.

* Enabled test INTERPRETER.onnx_model_round.

* Disabled tests with behavior as behavior of INTERPRETER.onnx_resize11_scales_down_linear.

* Changed tolerance for test onnx_empty_initializers_handling.

* Changed tolerance in the test onnx_resize11_sizes_linear (otherwise this test is failed in MacOS). Disabled test INTERPRETER.onnx_resize11_sizes_nearest_asymmetric_floor, because this test failed in MacOS only.
2020-09-01 06:57:34 +03:00
Ilya Churaev
71c5fad517 Removed NGRAPH_IE_ENABLE flag because it is always ON if unit tests are enabled (#2003) 2020-09-01 06:03:59 +03:00
Gabriele Galiero Casay
deeb0577f2 Dynamic shape support for builder collapse (#1971) 2020-08-31 18:26:36 +02:00
Evgeny Lazarev
210398674d Multiple fixes related to tickets 37105 and 37615 (#1979)
* Multiple fixes.

1. Fixes SpaceToBatch transformation to not crash if inputs are not Constant
2. Fixed eliminate_squueze, eliminate_unsqueeze to not crash when input has dynamic rank
3. Added reference implementation for the FloorMod operation

* Code style fixes

* Update floor_mod.hpp

Removed unnecessary function
2020-08-31 10:41:18 +03:00
Katarzyna Mitrus
410559d497 [ONNX] Update ONNX importer to use SotfPlus-4 (#1959)
* Use SoftPlus-4 in ONNX importer

* Tests update
2020-08-27 15:55:04 +03:00
Mateusz Tabaka
a6076a1fd6 Introduce Quantize-Dequantize to FakeQuantize transformation (#1849)
* Introduce Quantize-Dequantize to FakeQuantize transformation

* Revert changes in DequantizeLinear

* apply code format

* Changes after review:

- description for transformation
- remove NGRAPH_CHECK and move some checks from callback to predicates in pattern
- check if out_low/high are broadcastable for FQ's first input
- fix params to copy_runtime_info

* Add type_matches and type_matches_any predicates

* Use get_single_value

* Changes after review:

- add brief description of transformation
- use get_pattern_value_map instead of get_pattern_map
- change opset1 to opset4
- fix params to copy_runtime_info

* Check result of dynamic_pointer_cast
2020-08-26 11:51:51 +03:00
Anton Chetverikov
84c7b048db SoftPlus operation implementation (#1365) 2020-08-25 19:36:39 +03:00
Adam Osewski
393e9295cd Reference implementation for ScatterUpdate (#1678)
* Reference implementation for ScatterUpdate and use of it in evaluate.

* Review comments. Clarify comments.

* Update file directory.

* Replace scatter_update reference implementation in ngraph/core/reference/

* Remove template code from ScatterUpdate reference implementation

* Apply review requests

Co-authored-by: mitruska <katarzyna.mitrus@intel.com>
2020-08-25 06:12:39 +03:00
Tomasz Dołbniak
4013649fe8 v0::Pad operator removal (#1912)
* v0::Pad operator removal

* Obsolete test removal
2020-08-24 19:03:01 +03:00
Ivan Tikhonov
c74643f6b6 Fix Assign, Matmul ops for correct work with keep_shape_ops feature for Kaldi models (#1885)
* fix assign and matmul ops

* fix unit test

* static shapes by default for kaldi
2020-08-24 14:11:01 +03:00
Mateusz Tabaka
d7db4974f3 Reduce number of ops needed to create InstanceNorm (#1896)
* Reduce number of ops needed to create InstanceNorm

InstanceNorm in onnx importer creates the same subgraph for Mean twice - once for Variance and once for actual Mean.
This change makes InstanceNorm to use single Mean which is shared by numerator and Variance.

Also enables IE_CPU.onnx_model_instance_normalization test case

* Revert changes to .gitignore
2020-08-24 12:26:15 +03:00
Tomasz Dołbniak
067d29a3f0 Accept empty initializers from ONNX models (#1776)
* Accept empty initializers from ONNX models

* Create dummy constants instead of null nodes

* Code formatting

* Test the empty initializers handling in onnx importer
2020-08-21 15:15:27 +03:00
Ewa Tusień
54b9b7ae6c Remove Structural Attributes from Proposal op. (#1853) 2020-08-20 12:31:43 +03:00
Ilya Churaev
d25bb6314a Deprecate nGraph v0 ops and builders (#1856)
* Deprecate nGraph v0 ops

* Fixed build

* Added deprecated defines to fix windows
2020-08-20 12:27:14 +03:00
Gleb Kazantaev
301d6b50e3 Moved AlgebraicSimplification and NopElimination passes to IE (#1859)
* Moved AlgebraicSimplification and NopElimination passes to IE

* Fixed headerfiles
2020-08-19 18:55:11 +03:00
Katarzyna Mitrus
ceb8a25c94 Enable HSwish - ngraph op, fusion/decomposition and reference implementation (#1770)
* Add HSwish operator to nGraph

* Add HSwishFusion transformation

* Update check_constant function

* Add reference implementation for HSwish

* Enable reference implemenation in HSwish evaluate

* Add op_eval test

* HSwish fusion transformation test

* Add HSwishFusionWithoutRelu transformation

* Add more hswish fusion tests

* Register HSwishFusion pass in common_optimizations

* Update HSwish reference implementation

* Add HSwishFusion with Relu and Multiply

* Add HSwishDecomposition transformation pass

* Add HSwishDecomposition test

* Add HSwish op to ngraph python API

* Update HSwish fusion transformations

* Remove HSwishFusion from common optimizations

* Update hswish python API

* Add bf16 to evaluate hswish

* Update hswish python API

* Move hswish reference implementation

* UnaryElementwiseArithmetic inheritance

* Enable HSwish callback for clDNN

* Register HSwishDecomposition pass in ConvertOpSet1ToLegacy

* Enable HSwishFusion pass in common optimizations

* Use NGRAPH_RTTI_DECLARATION

* Moved python hswish test to the test_ops_unary
2020-08-19 08:04:00 +03:00
Mateusz Bencer
a63c8d9537 Optimize Concat operation (#1812)
* 1d case optimization

* code refactor

* concat optimization

* removed using template for concat

* unit tests to concat constant folding

* synchro with current master
2020-08-18 18:28:57 +03:00
Ilya Churaev
04475bc1b2 Add arithmetic operators for bfloat16 (#1831) 2020-08-18 13:49:30 +03:00