aboutsummaryrefslogtreecommitdiff
path: root/src/backends/reference/test/RefEndToEndTests.cpp
AgeCommit message (Collapse)Author
2022-02-07IVGCVSW-6698 EndToEnd tests on ref to ensure allocated data can be reusedDavid Monahan
Signed-off-by: David Monahan <David.Monahan@arm.com> Change-Id: I2cda579d18be765fbc2783d9fd80ff8e5372a8a8
2022-02-03IVGCVSW-6696 Add Forced Import EndToEnd tests to Ref, Neon, and CLDavid Monahan
* Created EndToEnd tests with Misaligned buffers but import is forced * Added the Aligned Tests from a previous patch to avoid merge conflicts * Previous Aligned EndToEnd test for ref has been added to backendsCommon and is now used for neon as well * Added to Ref, Neon, and Gpu Backends * Neon tests only check for copies as reconfigure has not been implemented for the Neon backend yet Signed-off-by: David Monahan <David.Monahan@arm.com> Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I12ddf5780201044834d6d1bbeebce60a4614efd1
2022-01-31IVGCVSW-6552 Add support of aligned host memoryNarumol Prangnawarat
* Add AllocatedData functions to OutputHandler * Enable import aligned memory in ImportInputs * Enable import aligned memory in ImportOutputs * Allow to import input and output if the memory is aligned * Implement Reconfigure function on ClConvolution2dWorkload * End-to-end test on Ref and Cl to ensure that input and output memory are imported when aligned Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I9e5e4c26d1ac2f1d806803ade5f64c6479c51718
2021-11-08IVGCVSW-6420: Constant flag in tensor info is not set correctlyCathal Corbett
!android-nn-driver:6532 !armnn-internal-tests:372451 * Made fix to 2 out of 3 ConstTensor() constructors in Tensor.hpp to throw InvalidArgumentException when TensorInfo isConstant parameter is false. * Added new ConstTensor() constructor in Tensor.cpp to accept vector<>.data() using template<typename MemoryType>. * Fixed runtime->GetOutputTensorInfo()/GetInputTensorInfo() methods and called submethods to return TensorInfo& rather than TensorInfo. * Fixed all failing unit tests for CpuRef/CpuAcc/GpuAcc to ensure any ConstTensor created has it's TensorInfo isConstant set to true. * Added unit tests in TensorTest.cpp to ensure ConstTensor constructors throw InvalidArgumentException when TensorInfo isConstat parameter is false. * Added unit test to ensure an empty ConstTensor constructor will set TensorInfo isConatant to true. * Indentation fixes. * Fix to arm_tensor.i to add isConstant parameter to TensorInfo constructor. Added methods IsConstant() and SetConstant(). * Fix to const_tensor.py to throw ValueError when TensorInfo isConstant is set to false when constructing a ConstTensor. * Fixed PyArmnn unit tests to set TensorInfo isConstant to True when ConstTensor is used. * Added unit tests in test_const_tensor.py to ensure ConstTensor constructors throw ValueError when TensorInfo isConstat parameter is false. Signed-off-by: Cathal Corbett <cathal.corbett@arm.com> Change-Id: I44e440dd0422c366d31bbdbc77ad2b4db0bde148
2021-10-20Add ConstTensorsAsInput support for Conv3dMatthew Sloyan
* Constant weights and biases are now stored as Constant layers. * Updated Serializer, Deserializer and unit tests to reflect this. * Updated TfLiteParser. * Updated Ref backend to handle constant weights and bias as inputs rather than reading from member variables. * Added Conv3d EndToEnd test. * Added NCDHW DataLayout and unit tests. Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: I10cdd354ca5f1c748730f92ffdb36bf810f83c8e
2021-10-14IVGCVSW-6416 AddFullyConnected API crashes without connected weights/bias layersCathal Corbett
* Created method in Graph.cpp/hpp ConstructErrorMessageForUnconnectedInputs() to verify weights and bias are set for FullyConnected layers. * Above method called in Graph.cpp InferTensorInfos() to print a more descriptive message when the weights or bias for a FullyConnectedLayer is not set. * Added try-catch in TestUtils.cpp Connect() to ensure input slot is available when connecting two layers. This ensures we catch the case where bias is is not enabled and we try and set a bias layer. * Added unit tests to check for LayerValidationError when weights or bias is not set on a FullyConnectedLayer. * Added unit test to check for LayerValidationError when bias is not enabled and we try and connect bias to FullyConnected Layer. * Seperated FullyConnected EndToEnd unit test method into two methods. First, performs tests on EndToEnd examples asserting output value. Second, performs tests on error catching. * Added comments to created methods. Signed-off-by: Cathal Corbett <cathal.corbett@arm.com> Change-Id: I5207d8c5ebacfff598556742ccd4f53eef7dee0c
2021-10-08IVGCVSW-6417: Catch AddFullyConnected API error when weights TensorInfo ↵Cathal Corbett
isn't set * Updated code in Graph.cpp InferTensorInfos() to be more descriptive. * Added method VerifyConstantLayerSetTensorInfo() in Graph.cpp/hpp to error when ConstantLayer TensorInfo is not set. * Updated Optimize() in Network.cpp to call VerifyConstantLayerSetTensorInfo(). * Added unit test with ConstantLayer TensorInfo not set to catch error in VerifyConstantLayerSetTensorInfo(). * Added comments around method VerifyConstantLayerSetTensorInfo(). Signed-off-by: Cathal Corbett <cathal.corbett@arm.com> Change-Id: I366596243f7c5823676222e2d0cce1335bc8c325
2021-09-29IVGCVSW-3716 Add EndToEnd Layer test for Channel Shuffle WorkloadTeresa Charlin
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I43d052d020f90c13688901929cd22c715471ef4f
2021-08-06IVGCVSW-6119 ConstTensorsAsInput: FullyConnectedMatthew Sloyan
* Constant weights and biases are now stored as Constant layers. * Updated Serializer, Deserializer and unit tests to reflect this. * Updated TfLiteDelegate, TfLiteParser and OnnxParser. * Updated Schema with IsConstant and ConstantTensorsAsInputs. * Updated Ref backend to handle constant weights and bias as inputs rather than reading from member variables. * Added dynamic or constant input EndToEnd tests. !android-nn-driver:5959 Signed-off-by: Matthew Sloyan <matthew.sloyan@arm.com> Change-Id: Ibf3cf437df1100e4b322b0d303c575c6339f9696
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-05-26IVGCVSW-6009 Integrate threadpool into ExNetKevin May
* Remove concurrent flag from ExecuteNetwork as it is possible to deduce if SimultaneousIterations > 1 * Add void RunAsync() * Refactor some unit tests Change-Id: I7021d4821b0e460470908294cbd9462850e8b361 Signed-off-by: Keith Davis <keith.davis@arm.com> Signed-off-by: Kevin May <kevin.may@arm.com>
2021-05-19IVGCVSW-5964 Removing some obsolete Boost references.Colm Donelan
Signed-off-by: Colm Donelan <Colm.Donelan@arm.com> Change-Id: Ic0a2e62e3808caf89ee429ec184d947a04340248
2021-05-06IVGCVSW-5813 Add Async Queue to IRuntimeKeith Davis
Signed-off-by: Keith Davis <keith.davis@arm.com> Change-Id: Icc0d131c8ee2e9748e2f14762a75962b39c10f9d
2021-04-14IVGCVSW-5787 Add/Update Execute() implementations in RefActivationWorkloadFinn Williams
* Added multithreaded StridedSliceEndToEndTest Signed-off-by: Finn Williams <Finn.Williams@arm.com> Change-Id: I4579db7b5959e0a22256f1bda00238c22e611dec
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-25IVGCVSW-5736 and IVGCVSW-5743 'NonConstWeights: Update front-end and ↵Sadik Armagan
TfLiteDelegate support for FullyConnected Operator' * Added front-end support for non-const weights for FULLY_CONNECTED operator * Added FULLY_CONNECTED end-to-end test * Updated FULLY_CONNECTED operator support in TfLite Arm NN Delegate for non-const weights * Updated the version numbers Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: Iffa5b9aa9297aca4c02d923cce4636c88ac21faa
2020-07-31IVGCVSW-4712 Fill layer datatype adjustmentsTeresa Charlin
* Input layer to be int32 instead of same type as output * Enable float16 end to end tests * Neon and Cl layer support check for backend Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I6bc889077c8da63eeff66bd45730ce5d8783c419
2020-07-30IVGCVSW-4713 Add EndToEnd test for RANKTeresa Charlin
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: Ia8f237a2500986e01843defb75787694a20ba24c
2020-07-28IVGCVSW-4712 Add EndToEnd test for FILLTeresa Charlin
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: Ic89bcbbd580abe1b05bd26748db704e83cf65bea
2020-05-21IVGCVSW-4452 Add QLstm EndToEndTestJames Conroy
* QLstm EndToEndTest added for Ref, NEON and CL. Signed-off-by: James Conroy <james.conroy@arm.com> Change-Id: Icd2c878541f6304d726202a93d71ff3d79f6f054
2020-03-18IVGCVSW-4446 Add HardSwish EndToEnd testsJan Eilers
* adds convert from armnn HardSwish to Acl HardSwish * adds EndToEnd tests for Ref, Cl and Neon Signed-off-by: Jan Eilers <jan.eilers@arm.com> Change-Id: If997dad783ff45d7f061254e7e30bb69d4d4d564
2020-03-18IVGCVSW-4444 Adding Elu end to end testJan Eilers
* implemented activation layer end to end test * adds support for different tolerances in layer tests * added tests for Elu (Ref, Cl, Neon) Signed-off-by: Jan Eilers <jan.eilers@arm.com> Change-Id: I81e28cfb4456e815bae2fb31f5c345134ff2432f
2020-03-13IVGCVSW-4531 Fix for failing strided slice NNT/VTS tests on Android RDavid Monahan
Signed-off-by: David Monahan <david.monahan@arm.com> Change-Id: I7f6932f0d21b5678ab9822b0fc69f589bbbb07e5
2020-01-23IVGCVSW-4259 Add frontend and reference workload for UnaryOperationLayerjosh minor
* Added new layer named ElementwiseUnary * Deprecated existing Abs/Rsqrt layer functions * Updated existing Abs/Rsqrt test infrastructure to use new layer * Added boilerplate for new Exp,Neg,Sqrt elemwise op layers * AbsQuantize test removed pending future commit * Serialization support added !android-nn-driver:2550 Change-Id: Ic595c645925e17b45db568187fd05646daf2e87f Signed-off-by: josh minor <josh.minor@arm.com>
2020-01-13Rename quantized data types to remove ambiguity for signed/unsigned payloadsDerek Lamberti
!android-nn-driver:2572 Change-Id: I8fe52ceb09987b3d05c539409510f535165455cc Signed-off-by: Derek Lamberti <derek.lamberti@arm.com>
2019-11-01IVGCVSW-3698 Add EndToEnd Layer test for ArgMinMaxNarumol Prangnawarat
* Add EndToEnd test implementation for ArgMinMax * Add EndToEnd tests for Ref * Fix output data type of ArgMinMax in WorkloadFactory Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I6d07d25bb96ab21422584284046222257ddee43c
2019-10-21IVGCVSW-3993 Add frontend and reference workload for ComparisonLayerAron Virginas-Tar
* Added frontend for ComparisonLayer * Added RefComparisonWorkload * Deprecated and removed Equal and Greater layers and workloads * Updated tests to ensure backward compatibility Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Id50c880be1b567c531efff919c0c366d0a71cbe9
2019-10-16IVGCVSW-3895 Add EndToEndLayerTest for the Reference Implementation of ↵Sadik Armagan
LOG_SOFTMAX Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: I500f0b819be543dc5829990d363e5d911197c9ec
2019-10-15IVGCVSW-3892 Add EndToEnd Layer test for INSTANCE_NORMALIZATIONSadik Armagan
Signed-off-by: Sadik Armagan <sadik.armagan@arm.com> Change-Id: Ia646446d52a7b597c3021f1e235465a96ce2beed
2019-10-02IVGCVSW-3738 Add end-to-end layer test for DepthToSpaceAron Virginas-Tar
* Added end-to-end layer test implementation for DepthToSpace * Added test to reference, CL and NEON backends for all supported data types and data layouts * Extracted common data permutation code into new utility file and refactored some existing tests to reduce code duplication * Fixed EndToEndLayerTestImpl template to work with Float16 data Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Iaf7a0012c520451052b20c37e36dc05fa8314ff6
2019-09-27IVGCVSW-3689 Support Import of Output Tensors for the Neon BackendFerran Balaguer
Change-Id: I6323c5f68248b54b3ed3b4cb92f1e8bf9c279b8d Signed-off-by: Ferran Balaguer <ferran.balaguer@arm.com>
2019-09-16IVGCVSW-3687 Add INetworkProperties to LoadNetworkDavid Monahan
* Allows users to specify if Import/Export should be used Signed-off-by: David Monahan <david.monahan@arm.com> Change-Id: I64da26a6acbeb91ef72d31b6ccc01bb1447f624d
2019-09-09IVGCVSW-3743 Add end-to-end test for ABS on CpuRefAron Virginas-Tar
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: I807a57af6dc2555a5a422388558a02e958ed610d
2019-08-30IVGCVSW-3381 Break up LayerTests.hpp into more manageable filesAron Virginas-Tar
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Icf39434f09fd340ad664cb3b97b8bee6d9da4838
2019-08-26IVGCVSW-3175 Add Regression Tests for Zero CopyFerran Balaguer
Signed-off-by: Ferran Balaguer <ferran.balaguer@arm.com> Change-Id: I6f16ea0dca359283a3b187e2f046f82a7dc2ff7c
2019-08-20IVGCVSW-3606 Support memory import for Reference backendFerran Balaguer
Signed-off-by: Ferran Balaguer <ferran.balaguer@arm.com> Change-Id: I94bd191f88e0911ad4e4727610e81cd7afa95512
2019-07-19IVGCVSW-3479 Add End to End test for PreluNikhil Raj
Change-Id: I041bdf9e721a4384ea3c2be0184787dd1f4ea08e Signed-off-by: Nikhil Raj <nikhil.raj@arm.com>
2019-07-09IVGCVSW-3391 Add SpaceToDepth CreateWorkload and EndToEnd testsJames Conroy
* Refactored existing EndToEnd tests, moved tests in reference to backendsCommon. * Enabled EndToEnd tests for CL. * Added new Ref/CL CreateWorkload tests. Signed-off-by: James Conroy <james.conroy@arm.com> Change-Id: I0a5e52961a8aca540d43241a3805d19c9c6ff56c
2019-07-01IVGCVSW-3361 Add end-to-end tests for Resize on CpuRefAron Virginas-Tar
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Ie89dc91a2fc0281d58c6f1ccef65ed1228d33ccb
2019-06-27IVGCVSW-3324 Add end-to-end tests for TransposeConvolution2d on CpuRefAron Virginas-Tar
* Added one end-to-end test for all supported data types and data layout * Implemented RefLayerSupport::IsTransposeConvolution2dSupported() * Fixed formula used in TransposeConvolution2dLayer::InferOutputShapes() Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: If1ba3c226ecfa17f7fceffae857f39297c6433f2
2019-06-26IVGCVSW-3347 Add EndToEnd test for BatchToSpaceNdFrancis Murtagh
* Add Simple and complex end to end tests based on tensorflow.org examples Change-Id: Ifa758a48cf5ea09f9be7945859cd37377dbb9465 Signed-off-by: Francis Murtagh <francis.murtagh@arm.com>
2019-06-25IVGCVSW-3250 Extend the Gather workload for QSymm16 supportEllen Norris-Thompson
* Add LayerTests and EndToEndTests for QSymm16 * Updated GatherQueueDescriptor::Validate function * Reimplemented RefLayerSupport::IsGatherSupported Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> Change-Id: I5b4df55d31b5ee3c5563d2df17b412a387c27595
2019-06-24IVGCVSW-3263 - Add End to End tests for SpaceToDepth on RefKeith Davis
Change-Id: I35d1c06b34ca160895f902255a69b87b711275b7 Signed-off-by: Keith Davis <keith.davis@arm.com>
2019-06-04Add support for all data type for input and output layersNarumol Prangnawarat
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I688f4db5f5950877ad88f637cf71c05270fd5338
2019-06-03IVGCVSW-3148 Add end to end test for Dequantize layer to Ref, Cl, NeonNarumol Prangnawarat
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: Iaf9c290c093b7d84949993439568e55433938b4e
2019-05-30IVGCVSW-2771 Add more end to end tests for splitter on Cl, Neon, RefNarumol Prangnawarat
to cover different number of dimensions and split axis Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: Ia9a111c8dcfc08d04b54aa770d1ae5312c6b1c93
2019-05-28IVGCVSW-3119 Rename MergerLayer to ConcatLayerJim Flynn
!android-nn-driver:1210 Change-Id: I940b3b9e421c92bfd55ae996f7bc54ac077f2604 Signed-off-by: Jim Flynn <jim.flynn@arm.com>
2019-05-28IVGCVSW-2771 Add end to end tests for splitter on Cl, Neon, RefNarumol Prangnawarat
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: I44f8f1799f6182721751b1d117c9ada5b91f52e1
2019-02-08IVGCVSW-2559 End to end tests for Detection PostProcessNarumol Prangnawarat
* end to end tests for Detection PostProcess float and uint8 * add anchors to AddDetectionPostProcessLayer * add anchors to VisitDetectionPostProcessLayer * refactor code Change-Id: I3c5a9a4a60b74c2246b4a27692bbf3c235163f90 Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com>
2019-01-24IVGCVSW-2503 Refactor RefElementwiseWorkload around Equal and Greaterkevmay01
* Remove Equal and Greater from RefElementwiseWorkload * Create RefComparisonWorkload and add Equal and Greater * Update ElementwiseFunction for different input/output types * Update TfParser to create Equal/Greater with Boolean output * Update relevant tests to check for Boolean comparison Change-Id: I299b7f2121769c960ac0c6139764a5f3c89c9c32