aboutsummaryrefslogtreecommitdiff
path: root/CMakeLists.txt
AgeCommit message (Collapse)Author
2021-08-04IVGCVSW-5980 JSON profiling outputKeith Davis
* Add new ProfilingDetails class to construct operator details string * Add new macro which helps append layer details to ostream * Add ProfilingEnabled to NetworkProperties so that profiling can be realised when loading the network * Add further optional info to WorkloadInfo specific to convolutions * Generalise some JsonPrinter functions into JsonUtils for reusability * Remove explicit enabling of profiling within InferenceModel as it is done when loading network * Add ProfilingDetails macros to ConvolutionWorkloads for validation Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: Ie84bc7dc667e72e6bcb635544f9ead7af1765690
2021-07-22MLCE-530 Add front end support for UnidirectionalSequenceLstm on ArmNNNarumol Prangnawarat
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I57bcbdec3eb0155f41af0fe7d6abf9bac2ec86eb
2021-07-22IVGCVSW-6077 Add the Custom Memory Allocator interface definitionDavid Monahan
* Added ICustomAllocator.hpp to include/armnn/backends/ * Added the ability to specify an ICustomAllocator to the CreationOptions Signed-off-by: David Monahan <david.monahan@arm.com> Change-Id: I820e468b691aa032c9bd2c1e1257dc9d02f981d9
2021-07-21IVGCVSW-6176 Add support for shape_signature in the tflite parserFinn Williams
* tflite shape_signatures will now be the preferred way to detect dynamic tensors * add test utility to the parser that converts a model's tensors to dynamic * by default tests will run a dynamic version of the model in addition to the original * fix dynamic shape inference of unpack operator * reactivate and fix quantize test * add shape inference to expand dims Signed-off-by: Finn Williams <Finn.Williams@arm.com> Change-Id: If11ba19d813cd3590707583dff1e4eb0e6412a1d
2021-07-21NNXSW-3081 Move Filesystem.hpp and Threads.hpp to public includeRob Hughes
!android-nn-driver:5966 Change-Id: Ice0b4d2872bb0e09bfc0763034a206c3a8f24af4 Signed-off-by: Rob Hughes <robert.hughes@arm.com>
2021-07-21Added comparison operators to TfLiteParserBruno Goncalves
E.g. Equal, NotEqual, Greater, GreaterOrEqual, Less and LessOrEqual Signed-off-by: Bruno Goncalves <bruno.slackware@gmail.com> Change-Id: Id56ef3cc19cc5c5daa19354010c9f25766e5fd00
2021-07-15IVGCVSW-5965: Remove the boost library from Arm NN build files.Sadik Armagan
* Remove all references to boost from the ArmNN build files: * Caught one remaining include in TensorTest.cpp. Signed-off-by: Colm Donelan <Colm.Donelan@arm.com> Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: Ib8c8014cf471aa0024c977ccb23ebf96b0236aca
2021-07-01IVGCVSW-6075 Add ParseExpandDims to TfliteParserTeresa Charlin
* Add ExpandDims tests in tfliteparser * Add support for negative axis to squeeze Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Signed-off-by: Finn Williams <Finn.Williams@arm.com> Change-Id: I604c9b4ac6514895e9e3d4d85c2937e797d288e0
2021-06-30IVGCVSW-6161 ConstTensorsAsInput: Optimizer - Redirect ConstTensor layer membersMatthew Sloyan
* Optimization that searches for layers with ConstantLayers as inputs. * The layer member variables are then redirected to these ConstantLayers. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: I24a2bf0e8575b808343e0bbe3897b344e94796ad
2021-06-30IVGCVSW-6114 Create multiple LoadedNetworks from one OptimizedNetworkMike Kelly
* Added IOptimizedNetwork constructor that takes another IOptimizedNetwork and a ModelOptions. * Changed PreCompiledLayer to use shared_ptr rather than unique_ptr to store the PreCompiledObject (no interface changes). * Added unit tests to ensure that PreCompiledLayer::Clone() clones the pointer to the PreCompiledObject correctly. Signed-off-by: Mike Kelly <mike.kelly@arm.com> Change-Id: I3ef56055e0d189ffce9e651882d34da16c70a240
2021-06-23IVGCVSW-6062 Rework the async threadpoolFinn Williams
!android-nn-driver:5802 * Extract the threadpool from LoadedNetwork/Runtime * Refactor the threadpool to be handle multiple networks * Trim IAsyncExecutionCallback and add an InferenceId to AsyncExecutionCallback * Add AsyncCallbackManager class Signed-off-by: Finn Williams <Finn.Williams@arm.com> Change-Id: I36aa2ad29c16bc10ee0706adfeb6b27f60012afb
2021-06-18IVGCVSW-5810 Create a skeleton armnnTestUtils libraryMatthew Sloyan
* Moved useful test utilities to new static library. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: Ib800e0737bc5f78399cffa501483b4d26356215c
2021-06-18MLCE-510 Add CpuRef Shape Operator to ArmNNKeith Davis
* Add TfLiteParser and delegate support Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: Id3219ba7cc7128b5e73de2c7d8d076a40dcce9c5
2021-06-16MLCE-510 Add CpuRef Shape Operator to ArmNNKeith Davis
* Add front end * Add reference workload * Serialization/Deserialization * Add unit tests * Update ArmNN Versioning Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: I6fcb1fa341d6f08dea4003b13544e6e9f53fefd3
2021-06-16IVGCVSW-5826 Change weights layout for depthwise to [1,H,W,I*M]Jan Eilers
* This change is necessary because tflite uses a [1,H,W,I*M] format and uses the I*M dimension for per axis quantization. Our previous layout [M,I,H,W] can't handle the correlating quantization scales. * Updates Onnx-, TfLiteParser and TfliteDelegate * Updates the CpuRef, CpuAcc and GpuAcc backends * Adjusts unit tests * Adds test to ensure models with old layout can still be read and executed * Adds conversion function to previous layout [1,H,W,I*M] --> [M,I,H,W] which can be used by backend developers !android-nn-driver:5553 Signed-off-by: Jan Eilers <jan.eilers@arm.com> Change-Id: Ifef23368b8c3702cf315a5838d214f7dc13c0152
2021-06-16IVGCVSW-5835 Move the src/profiling/LabelsAndEventClasses class to ↵Nikhil Raj
profiling/common Signed-off-by: Nikhil Raj <nikhil.raj@arm.com> Change-Id: I83de0fe9c83ec7e698817095ce5cfe3319c36ea6
2021-06-11IVGCVSW-5963 'Move unit tests to new framework'Sadik Armagan
* Used doctest in ArmNN unit tests Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: Ia9cf5fc72775878885c5f864abf2c56b3a935f1a
2021-06-08IVGCVSW-5834 Move the IProfilingGuidGenerator and ProfilingGuidGenerator ↵Nikhil Raj
into profiling common Signed-off-by: Nikhil Raj <nikhil.raj@arm.com> Change-Id: I0d672cc782cc2de66a88acf0d83fcd40208ace95
2021-05-25IVGCVSW-3649 Add TfLite parser support for Prelu layerNarumol Prangnawarat
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I3dedcc86efe1a67c709d9da636953e2fc400107b
2021-05-24IVGCVSW-6069 Add Unit Test for Pad + DepthwiseConv and Pad + ConvTeresa Charlin
*All fold pad test are now in a separate file Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: Ic0b0436f6b0194404f9a3f1553e2f69524b63580
2021-05-20MLCE-418 Reduce layer does not support multiple axesMatthew Sloyan
* Added backend specific optimization to chain new reduces layers for each axis to simulate behaviour of a layer with multiple axes. * Added function to calculate reduced output shape. * Added unit tests. * Includes rework to fix IVGCVSW-5987. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: I154b3698b5e6756b05b2a0b5a3f0896184efce72
2021-05-18IVGCVSW-5964 Removing some remaining boost utility usages from tests.Colm Donelan
* Adding a basic PredicateResult class to replace boost::test_tools::predicate_result * Replacing all uses of boost::test_tools::predicate_result with the new armnn::PredicateResult class * Replacing use of boost::test_tools::output_test_stream output with std::ostringstream in ProfilerTests.cpp Signed-off-by: Colm Donelan <Colm.Donelan@arm.com> Change-Id: I75cdbbff98d984e26e4a50c125386b2988516fad
2021-05-13Github #330 Missing items on installationFrancis Murtagh
* Allow installation of ArmnnConverter Signed-off-by: Francis Murtagh <francis.murtagh@arm.com> Change-Id: I9deccb23b969c78d3e79b3a948498d2ec6fe6a5f
2021-05-07Revert "MLCE-418 Reduce layer does not support multiple axes"Matthew Sloyan
This reverts commit d905decd256558bbee165e636ce4242ac3b9c917. Reason for revert: LargeGraph_TENSOR_FLOAT32/FLOAT16 CTS tests failures Change-Id: Ie69826549e73775825f45134375b5b2c41aebd01
2021-05-06IVGCVSW-5813 Add Async Queue to IRuntimeKeith Davis
Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: Icc0d131c8ee2e9748e2f14762a75962b39c10f9d
2021-05-06MLCE-418 Reduce layer does not support multiple axesMatthew Sloyan
* Added backend specific optimization to chain new reduces layers for each axis to simulate behaviour of a layer with multiple axes. * Added function to calculate reduced output shape. * Added unit tests. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: I180b0b111b7bcf3d0c283f1db0b82d5f17757682
2021-05-06IVGCVSW-5410 Move ILayerSupport.hpp to backends folderFrancis Murtagh
* ILayerSupport is a backend interface, and so in order to prevent false positives in ABI Compliance Checker move it to backends folder. * Front end users should use ABI stable GetILayerSupportByBackendId which takes advantage of LayerSupportHandle Signed-off-by: Francis Murtagh <francis.murtagh@arm.com> Change-Id: Ie119451c5d55f114525dc79b6f3474b2df7e3418 !android-nn-driver:5516
2021-04-27IVGCVSW-5721 Remove the Tensorflow Parser from ArmNNNikhil Raj
Signed-off-by: Nikhil Raj <nikhil.raj@arm.com> Change-Id: Ida37d3ee3a1af0c75aa905199bd861726c646846
2021-04-27IVGCVSW-5719 Remove QuantizerKevin May
Signed-off-by: Kevin May <kevin.may@arm.com> Change-Id: I8a29df03afdd6f1cc8413b219e179272cd2d51cf
2021-04-21Fold PAD into Pooling2d if possibleDiego Lopez Recas
Some models would add a PAD layer before a pooling when they can't express their padding configuration as SAME or VALID. ArmNN can potentially merge the two merge the two because pooling layers are described with explicit padding. The merge is possible if the extra padding is neutral in the combined pooling operation. A merged operation can only fuse paddings in the dimensions that accept explicit padding in a pooling operation, i.e. the spatial dimensions. Signed-off-by: Diego Lopez Recas <diego.lopez.recas@gmail.com> Signed-off-by: Colm Donelan <Colm.Donelan@arm.com> Change-Id: Icd54718dcd9e797c923456b7fa6e0213e288e668
2021-04-16IVGCVSW-5720 Remove the Caffe Parser from ArmNNNikhil Raj
Signed-off-by: Nikhil Raj <nikhil.raj@arm.com> Change-Id: Ib00be204f549efa9aa5971ecf65c2dec4a10b10f
2021-04-15IVGCVSW-5829 Segfault in tflite-parser, int8 modelsMatthew Sloyan
* Updated ParseSplit TfLiteParser function to read correct axis data. * Improved validation in ParseSplit and ParseSplitV function. * Added TensorFlow BOOL support to TfLiteParser. * Added supported ElementWiseUnary operators to TfLiteParser E.g. ABS, LOGICAL_NOT and RSQRT. * Removed ParseExp and ParseNeg function implementation in favour of reusable ParseElementWiseUnary function. * Removed Exp.cpp and Neg.cpp files and moved tests to ElementWiseUnary.cpp. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: Ibce36e3ce4d95755dda88abc2ddde1e07e62c5e2
2021-04-14IVGCVSW-5795 Use ${CMAKE_THREAD_LIBS_INIT} throughout instead of 'pthread'Francis Murtagh
Signed-off-by: Francis Murtagh <francis.murtagh@arm.com> Change-Id: I32a92e0efabefd1e342203a13f11a622a3e25076
2021-04-12IVGCVSW-5410 Add front-end support for CASTmathad01
IVGCVSW-5415 Add TfLiteParser support for CAST * Added front end support for CAST, including support in the Reference workload, Serialization, Deserializtion, Unit tests, and TfLiteParser. Signed-off-by: mathad01 <matthew.haddon@arm.com> Change-Id: Iaf670ca5912a21ed6bc84f7f83a68b42154846bb
2021-04-09IVGCVSW-5804 TfLiteParser fails to correctly parse ArgMinMaxMatthew Sloyan
* Fix for GitHub#523. * Updated ParseArgMinMax function to read correct axis data. * Improved validation in ParseArgMinMax function. * Added ARG_MIN support to TfLiteParser. * Added ArgMinMax unit tests for TfLiteParser. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: Ib4ce1a7c66e210c47859a130c4896aac958f2654
2021-04-09MLCE-328 Serializer/Deserializer does not support Signed64Mike Kelly
* Added support for Signed64 to flatbuffer's schema & updated source tree * Added support for Signed64 to TFLite Delegate * Added support for Signed64 to Serializer * Added support for Signed64 to Deserializer * Added unit test for ArgMinMax to Deserializer * Deprecated m_Output_Type from the ArgMinMaxDescriptor: the output type is solely determined by the DataType of the output Tensor * Fixed issue where RefArgMinMaxWorkload could output data using the wrong DataType * Added Signed64 to RefLayerSupport::IsArgMinMaxSupported as a supported type Signed-off-by: Mike Kelly <mike.kelly@arm.com> Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: Ib622c052a1f8aa3e658262f8bde5a6881a8cbe10
2021-04-08IVGCVSW-5823 Refactor Async Network APIMike Kelly
* Moved IAsyncNetwork into IRuntime. * All LoadedNetworks can be executed Asynchronously. Signed-off-by: Mike Kelly <mike.kelly@arm.com> Change-Id: Ibbc901ab9110dc2f881425b75489bccf9ad54169
2021-03-29IVGCVSW-5790 Merge async prototypeMike Kelly
* Added thread safe execution mechanism for armnn * Removed duplicate function bool Compare(T a, T b, float tolerance) * Added StridedSliceAsyncEndToEndTest * Fixed memory leak Signed-off-by: Mike Kelly <mike.kelly@arm.com> Change-Id: I2d367fc77ee7c01b8953138543e76af5e691211f
2021-03-23Revert "Fold PAD into Pooling2d"Jim Flynn
This reverts commit 51ce7d487c761358de105f82ff90553570aedac0. Reason for revert: https://jira.arm.com/browse/IVGCVSW-5798 LargeGraph_TENSOR_FLOAT32 CTS tests failures Change-Id: Ib031a47f605340b2202ecf074ce96a8b54c51075
2021-03-22Fold PAD into Pooling2dDiego Lopez Recas
Some models would add a PAD layer before a pooling when they can't express their padding configuration as SAME or VALID. Arm NN can merge the two because pooling layers are described with explicit padding. Signed-off-by: Diego Lopez Recas <diego.lopez.recas@gmail.com> Change-Id: Id048186db6a005e0257bfbc1406c3b0dab2cdd58
2021-02-12IVGCVSW-4893 Refactor ILayerVisitor using unified interface strategy.Finn Williams
Signed-off-by: Jan Eilers <jan.eilers@arm.com> Signed-off-by: Finn Williams <Finn.Williams@arm.com> Signed-off-by: Francis Murtagh <francis.murtagh@arm.com> Change-Id: Id7bc8255a8e3f9e5aac65d510bec8a559bf37246
2021-02-09MLCE-347 'REDUCE_MIN, REDUCE_MAX, REDUCE_SUM Support'Sadik Armagan
* Added TfLiteParser support for REDUCE_MIN and REDUCE_MAX operators * Added ACL workloads support for REDUCE_MIN, REDUCE_MAX, and REDUCE_SUM operators * Added TfLite Delegate support for REDUCE_MIN, REDUCE_MAX, and REDUCE_SUM operators Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: I8085d59946bfd4ab78a59a61f899031ae53371a8
2021-02-08IVGCVSW-4901 Add semantic versioning to Parsers and TfLite DelegateMatthew Sloyan
* Added Version.hpp to all Parsers * Added Version.hpp to TfLite Delegate * Updated CMakeLists to use new versions * Added GetVersion method to parsers and TfLite Delegate Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: If29e1e6d9e615f9095ec1c01ad47acfff40b1dd5
2021-02-06ArmnnConfig.cmake install to correct directoryKeith Mok
Signed-off-by: Keith Mok <ek9852@gmail.com> Change-Id: I9b1037275379bdbf452589357576cfa763b7c128
2021-02-03backends/reference: Add ReduceSum operation supportSadik Armagan
This patch addes ReduceSum operation support for reference backend, which computes the sum of elements across dimensions of a tensor. Changelog v1: - Fix file header descriptions. Chagelog v2: - Fix line limit issue. - Fix type conversion issue. Changelog v3: - Remove tabs. - Modify newly added file headers. Changelog v4: - Symbol on header isn't allowed so drop it from newly added file headers. Changelog v5: - Remove tabs, fix the use of brackets and align lines correctly. Changelog v6: - Add serializer and deserializer support. Changelog v7: - Fix build error add missed code. Changelog v8: - Rename ReduceSumDecriptor to ReduceDescriptor - Update m_KeepDims field data type to bool on ReduceDescriptor - Add ReduceOperation field to ReduceDescriptor - Rename ReduceSumLayer to ReduceLayer - Update ReduceLayer to use ReduceDescriptor - Update ReduceLayer::ValidateTensorShapesFromInputs() function - Rename RefReduceSumWokload to RefReduceWorkload - Update workload to use ReduceDescriptor - Update workload to use Decoders and Encoders - Remove ReduceSum.hpp and ReduceSum.cpp - Added Reduce.hpp and Reduce.cpp - Move Mean.cpp (which is implementing REDUCE_MEAN) functionality to Reduce.cpp - Update RefMeanWorkload to call Reduce function with ReduceOperation::Mean argument - Remove Mean.hpp and Mean.cpp - Update the Serializer/Deserializer ArmnnSchema.fbs for ReduceLayer, ReduceDescriptor, and ReduceOperation - Update Serializer and Deserializer for serializing/parsing ReduceLayer - Added TfLiter parser Sum test for REDUCE_SUM operator - Make corresponding changes on front-end and Ref backend to support REDUCE_SUM operator Changelog v9: - Fixed build errors. Change-Id: I8c8e034f3df73f9565b3c18eff51ecca6c542195 Signed-off-by: Inki Dae <inki.dae@samsung.com> Signed-off-by: Sadik Armagan <sadik.armagan@arm.com>
2021-01-22MLCE-335 'DEPTH_TO_SPACE and GATHER operator support in TfLiteParser'Sadik Armagan
* Added GATHER operator support to TfLiteParser * Added DEPTH_TO_SPACE operator support to TfLiteParser Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: Id5d3b54e2d850eb9f19417029efbeb73a3029e69
2021-01-13Fix build breaks on file insensitive systemKeith Mok
Current we use 'A'rmNNQuantizer name for executable and 'a'rmNNQuantizer as library name. Since cmake does not allow same name for executable and library. The old way is to use a captial letter for the executable name. But it will create a problem on system (like macosx) that the file system is case insensitive by default. Since it will create/overwritten file on the same folder during the cmake build which makes build failed when BUILD_ARMNN_QUANTIZER is enabled. Fixed this by using ArmNNQuantizerMain as the executable name during build, then rename it back to ArmNNQuantizer using set_target_property OUTPUT_NAME function. Signed-off-by: Keith Mok <ek9852@gmail.com> Change-Id: I3e0779770c851c0eb6804e300a24836be955d07a
2020-11-30IVGCVSW-5587 Remove Tensorflow requirement from Arm NN TfLite delegateFinn Williams
* Added support for building the delegate with an external armnn path * Replaced potentially troublesome package manager * Explicitly set the privacy levels of delegate libraries * Fixed some error handling in ExecuteNetwork Signed-off-by: Finn Williams <Finn.Williams@arm.com> Change-Id: I2a7abc099796012cbb043c5b319f81778c9f3b56
2020-11-17IVGCVSW-5377 Add ArmNN TfLite delegate to ExecuteNetworkSadik Armagan
* Added package manger to turn internal calls to find_package into a no-op * Changed delegate cmake so it can now be built within armnn Change-Id: I2a7ecb9a3c1ca05474cd1dccd91498f6f6c0b32e Signed-off-by: Finn Williams <Finn.Williams@arm.com> Signed-off-by: Sadik Armagan <sadik.armagan@arm.com>
2020-11-13IVGCVSW-5328-5329 Fuse ActivationMike Kelly
* Added Fused Activation Optimization to both CL and Neon backends. * Added Fused Activation support to all the CL and Neon workloads that support it. * Changed ProfilingTest network to be a Convolution layer followed by an Abs layer rather than an Activation layer. * Added IBackendInternal::OptimizeSubgraphView function that can accept a ModelOptions. * Network will now call OptimizeSubgraphView passing in the ModelOptions. Signed-off-by: Keith Davis <keith.davis@arm.com> Signed-off-by: Mike Kelly <mike.kelly@arm.com> Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: Ib536ac3cbafc7d9b35c139ad9a65b7735262cd9d