aboutsummaryrefslogtreecommitdiff
path: root/src/armnn/NetworkUtils.cpp
AgeCommit message (Collapse)Author
2024-03-13IVGCVSW-7853 Assert audit and removalDeclan-ARM
* src/armnn * src/armnn/layers Signed-off-by: Declan-ARM <decmce01@arm.com> Change-Id: Ic78cbbb59e90fbb15f893205a358c45264243721
2022-11-16IVGCVSW-7214 Disable BF16-Turbo-Mode and remove conversion layersRyan OShea
- Remove Bf16ToFp32 Conversion Layer - Remove Fp32ToBf16 Conversion Layer - Remove B16 Conversion tests * Throw exception if m_ReduceFp32ToBf16 optimzer option is set to true * Provide comments to enable fast math in order to use bf16 * Update docs to inform users to enable fast math for bf16 Execute Network Changes * Require bf16_turbo_mode to also have fast_math_enabled set to true - Remove setting m_ReduceFp32ToBf16 optimizer option Signed-off-by: Ryan OShea <ryan.oshea3@arm.com> Change-Id: Ibaa6da9d29c96a1ce32ff5196b0847fde9f04a1c
2022-10-19MLCE-545 INT8 TFLite model execution abnormalKeith Davis
* Add functionality to print output tensors to file in tempdir * UnitTests Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: Idfb4c186544187db1fecdfca11c662540f645439
2022-07-27IVGCVSW-6978: RedirectMembersToConstantInputs does not work with ↵Francis Murtagh
Fp32NetworkToBf16Converter * Fuse FP32ToBF16Layers with Constant Layer so Conv2d/FullyConnected can have their weights redirected. * If BF16 Unsupported in Conv2d || FullyConnected revert fused Constant Layer to FP32 Change-Id: If523c708a822659d64597d9ae39cca1c2f84b76f Signed-off-by: Francis Murtagh <francis.murtagh@arm.com>
2022-05-16IVGCVSW-6124 ConstTensorsAsInput: Conv2d - FrontEndKeith Davis
* Update Front-end and Tools. * Updated Serializer, Deserializer and unit tests to reflect this. * Updated TfLiteDelegate, TfLiteParser and OnnxParser. * Updated Ref. * Fixed resulting Neon / CL tests * Unified optimizers for conv2d ops * Optimizer Fix - Fp32ToBf16 * Partial implementation for ACL backends to fix VTS failures !android-nn-driver:7477 Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: I5fb18877f7ee32643e15a9818945356274bb401b
2021-02-19Give unique names to debug layersRob Hughes
Debug layers are given names based on the layer they take their input from. If a layer has multiple outputs then one debug layer will be attached to each output. Therefore all these debug layers would have identical names making them hard to distinguish when debugging. This patch includes the output slot index which the debug layer takes its input from when creating the name. Change-Id: I09eaa8a7edad9bfdf678b4778cf740340013126c Signed-off-by: Rob Hughes <robert.hughes@arm.com>
2020-04-06IVGCVSW-4485 Remove Boost assertNarumol Prangnawarat
* Change boost assert to armnn assert * Change include file to armnn assert * Fix ARMNN_ASSERT_MSG issue with multiple conditions * Change BOOST_ASSERT to BOOST_TEST where appropriate * Remove unused include statements Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I5d0fa3a37b7c1c921216de68f0073aa34702c9ff
2020-03-26IVGCVSW-4597 Modify BF16 optimizer to Convert only inputs and weights ofNarumol Prangnawarat
Convolution2d and FullyConnected layers * Add InsertConvertFp32ToBf16LayersBefore * Add ConvertWeight to ConvertFp32NetworkToBf16Impl for Conv2d and FullyConnected * Allow different input and output when input is BF16 and output is FP32 Conv2d and FullyConnected layers * Unit tests Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: Ic8f92ff28edcae08a72a3114a28f50c4619f919b
2020-03-20IVGCVSW-4520 Implement BFloat16 OptimizerNarumol Prangnawarat
* Add ReduceFp32ToBf16 to OptimizerOptions * Add ConvertFp32NetworkToBf16 * Add utility functions to insert conversion layers * Add constant conversion BF16 <-> FP32 * Unit tests Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: Iaff77e20c721400b052cb37eb9ef6fe16d7abaff
2019-11-15IVGCVSW-4119 Fix FP16 to FP32 fallback mechanism in optimizer to work with ↵Aron Virginas-Tar
Dequantize * Check for output data type as well as input data type when determining whether we should attempt to fall back to FP32 if FP16 is not supported * Override output type for Dequantize in IsLayerSupported() instead of input type * Updated original input type from FP16 to FP32 in InsertConvertFp32ToFp16LayersAfter() Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Ic6477fd17cea5a91bd8bf9ae0cf836520897d5b7
2019-10-31GitHub #292 Move BackendRegistry.hpp to the public APIMatteo Martincigh
* Moved to BackendRegistry.hpp include/armnn * Updated makefiles and sources accordingly Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com> Change-Id: I4d83abb581d523218a880c879fcf30c9611f7fd7
2019-07-30IVGCVSW-3581 Fix AddCopyLayers and associated testsMatthew Bentham
Take a copy of the MemoryStrategies for a layer before inserting new connections. Use the copy when looking up the original MemoryStrategies during the graph transformation. Fix the unit tests for AddCopyLayers to have cases where copies are needed. Fix the validation for clarity and correctness - was previously comparing Layers by pointer when it should have been by name (as it was comparing with a cloned graph). Change-Id: Ie282dc11913e977b8151ce1ad8bfba5e11617d40 Signed-off-by: Matthew Bentham <Matthew.Bentham@arm.com>
2019-04-30IVGCVSW-2405 Rename SubGraph to SubgraphViewDerek Lamberti
Change-Id: Ie50aeccf053c20c3a01a75042bbc3acd824375af Signed-off-by: Derek Lamberti <derek.lamberti@arm.com> Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
2019-03-26IVGCVSW-2881 Remove DebugDescriptorNattapat Chaimanowong
* Also update Debug layer to use layer guid information Change-Id: I9ec1f639299c3f855b670ff031a0e88d685cfc6b Signed-off-by: Nattapat Chaimanowong <nattapat.chaimanowong@arm.com>
2019-02-25IVGCVSW-2762 Fix missing layer name and output slot index in DebugLayer outputAron Virginas-Tar
Change-Id: Idda9c8ba244c74d931105ced90c38a12d48df48a Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com>
2019-01-30IVGCVSW-2458 Refactor the Optimize function (Network.cpp) so thatMatteo Martincigh
subgraphs are optimized by the backends * Added a new method OptimizeSubGraph to the backend interface * Refactored the Optimize function so that the backend-specific optimization is performed by the backend itself (through the new OptimizeSubGraph interface method) * Added a new ApplyBackendOptimizations function to apply the new changes * Added some new convenient constructors to the SubGraph class * Added AddLayer method and a pointer to the parent graph to the SubGraph class * Updated the sub-graph unit tests to match the changes * Added SelectSubGraphs and ReplaceSubGraphConnections overloads that work with sub-graphs * Removed unused code and minor refactoring where necessary Change-Id: I46181794c6a9e3b10558944f804e06a8f693a6d0
2019-01-15IVGCVSW-2454 Merge together the pluggable backends work (was in aMatteo Martincigh
separate branch) and master * Brings in all the changes done for the pluggable backends * Added sub-graph support and tests * Added precompiled layer support and tests * Moved BackendSettings to a separate file * Removed the backend-specific code * Ported DebugLayer and associated functionality * Included fixes to make those changes work with master Change-Id: Id7028fa7917527b844628d5aff5732e3d94c0488
2018-12-11IVGCVSW-1434 Add debug mode to Optimizerkeidav01
* Modified optimizer to support debug mode via DebugLayer Change-Id: Ic8f313778e55540c182cf99876c44a0823be04c6
2018-11-22Refactor inlined utility functions in NetworkUtilsAron Virginas-Tar
Change-Id: I26fb13717f64c942b2648702c52be18be856042d