aboutsummaryrefslogtreecommitdiff
path: root/src/backends/backendsCommon/test/LayerTests.cpp
AgeCommit message (Collapse)Author
2019-08-28IVGCVSW-3656 Rename ARMCOMPUTEREF to ARMNNREFMatteo Martincigh
* Renamed ARMCOMPUTEREF to ARMNNREF (and relative symbols) as the previous name was misleading !android-nn-driver:1822 Change-Id: I912e9f521750b91539e48f8a2fb4de73fb6f7425 Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
2019-08-26IVGCVSW-3575 Fix DepthwiseConvolution VTS Test FailuresKevin May
Failing VTS tests were "NeuralnetworksHidlTest.depthwise_conv2d_*" In depthwise convolution there was a difference in weight tensor channel order between the reference and ACL implementations. This specifically related to NCHW. This commit: * Adds ReorderWeightChannelsForAcl to WorkloadUtils which will correct the weight tensor channel order. * Add unit tests to detect this problem. Signed-off-by: Colm Donelan <Colm.Donelan@arm.com> Change-Id: Icaeac08e14b3d5da9e222ad2f118db55ebb15d09
2019-08-22IVGCVSW-3656 Make the reference backend optionalMatteo Martincigh
* Made the build of the reference backend depend on a new ARMCOMPUTEREF macro * Made the relevant targets dependent on the ref backend * Moved Cl and Neon static registry initializers to separate files * Wrapped some of the unit tests into proper ifdefs where necessary Change-Id: I7f2c42699682630233a4c4b6aed2f005083de189 Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
2019-08-16IVGCVSW-3639 Add 5d tensor supportMatthew Jackson
* Increased MaxNumOfTensorDimensions and fixed issues related to its use * Fixed issues caused by assuming 5d tensors are invalid * Updated ArmComputeTensorUtils for 5d tensors * Added 5d tensor unit tests for add, mul, stack and reshape (needed by IVGCVSW-3527) Signed-off-by: Matthew Jackson <matthew.jackson@arm.com> Change-Id: I5bcd64942d0d04efcc6c5acb240ad4b88e010743
2019-08-13IVGCVSW-3616 Add multi-channel unit test for TransposeConvolution2dAron Virginas-Tar
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Ib9271920b39fb9d730006c79a322e32008096b56
2019-08-02IVGCVSW-3470 Add Quantized_LSTM testsJames Conroy
* Added Layer and Create Workload tests for the new Quantized LSTM layer. * Tests to be enabled on NEON and CL in their respective patches. Signed-off-by: James Conroy <james.conroy@arm.com> Change-Id: I7e9e9768dd63010ab58367c45fffcff452377cfb
2019-07-26IVGCVSW-3537 Add support for L2 Normalization with < 4 dimensional tensorsMatthew Jackson
* Fix reference L2 Normalization workload to support < 4 dimensional tensors * Add unit test for L2 Normalization with 2d tensor to Reference, Neon and CL test suites * Fix typo in StackLayer Signed-off-by: Matthew Jackson <matthew.jackson@arm.com> Change-Id: I48a6a1289bcb02955b24f261bc70b467bd1abc23
2019-07-23Fix various uses of non-standard C++:Rob Hughes
* Replace u_int32_t with uint32_t * Replace size_t with uint32_t for initializer list of TensorInfo * Replace variable size arrays with std::vector * Replace reference to local variable during its initialisation Change-Id: I298b3995f1525f90a1ab2416d7e270315698fae3
2019-07-23IVGCVSW-3536 Add Axis parameter to reference Softmax implementationFrancis Murtagh
* Add Axis parameter to Softmax Descriptor * Add new reference implementation for Softmax using Axis parameter * Add unit tests to cover each Axis Change-Id: Iafac2275d2212337456f2b1b56b0f76f77fb9543 Signed-off-by: Francis Murtagh <francis.murtagh@arm.com>
2019-07-22IVGCVSW-3368 Add reference support for depthwise multiplier > 3Matthew Jackson
* Remove multiplier check in TfLite parser * Add reference unit test for depthwise multipler of 64, as in DeepSpeaker Signed-off-by: Matthew Jackson <matthew.jackson@arm.com> Change-Id: I787339ab4c4d269333985353d191202d070906ba
2019-07-15IVGCVSW-3495 Refactor names of convolution2d unit testsJan Eilers
Signed-off-by: Jan Eilers <jan.eilers@arm.com> Change-Id: Idb1325cba730dbf62b4742e4078220ef97d4b526
2019-07-10IVGCVSW-3468 Add Unit test for Conv2D that combinesTeresa Charlin
strides, dilation and padding Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: Iea99a162e1f0c823cd0f8bc0ae2fb5f461778515
2019-07-09IVGCVSW-3399 Add support of QuantisedSymm16 to PadNarumol Prangnawarat
* Add support of QuantisedSymm16 to Pad * Fix custom padding tests * Add unit tests for Pad QuantisedSymm16 Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: Ieb9a4492760b13fa030a42eb4d38fd9ffd7a8c76
2019-07-08IVGCVSW-3399 Add support of QuantisedSymm16 to Permute and unit testsNarumol Prangnawarat
Signed-off-by: Narumol Prangnawarat <narumol.prangnawarat@arm.com> Change-Id: Id6ab073ae3e0ff5f60c2f4bef975798ce71c9f88
2019-07-08IVGCVSW-3393 Fix Ref Unit test for customizable padding valueTeresa Charlin
Add Neon missing Unit Test for Uint8. Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I9207be8c8cf572ae9cbbf155010bb6dabe0c971c
2019-07-05IVGCVSW-3353 Add CL support and tests for SpaceToDepthJames Conroy
* Added CL backend support for SpaceToDepth. * Enabled unit tests for SpaceToDepth on CL. * Renamed unit tests to make them type-agnostic. * Added QSymm16/S16 support to ClTensorHandle. Signed-off-by: James Conroy <james.conroy@arm.com> Change-Id: I417d82946142ed619c447428bf0b0c4a2116c004
2019-07-02IVGCVSW-3236 Extend Ref LSTM with layer normalization supportJan Eilers
* Add descriptor values * Update lstm queue descriptor validate function * Update lstm workload * Update isLstmSupported (Cl and Ref), LayerSupportBase, ILayerSupport * Update lstm layer * Add unit tests Signed-off-by: Jan Eilers <jan.eilers@arm.com> Change-Id: I932175d550facfb342325051eaa7bd2084ebdc18 Signed-off-by: Jan Eilers <jan.eilers@arm.com>
2019-06-27IVGCVSW-3320 Add reference workload support for TransposeConvolution2dLayerAron Virginas-Tar
Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: Icc64f8148c9d8a0d14d772e6e4e7865e70585cd9
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-25IVGCVSW-3334 Refactor BatchToSpace tests to be genericFrancis Murtagh
* Generify and reformat test BatchToSpace tests * Add missing RefCreateWorkload test Change-Id: I08af018c07ee41df5b9d1e578d99bc03f38090ac Signed-off-by: Francis Murtagh <francis.murtagh@arm.com>
2019-06-24IVGCVSW-3235 Add scalar to use as padding value in Reference PadDavid Monahan
Signed-off-by: David Monahan <david.monahan@arm.com> Change-Id: If050f318fcb7626bbfae1b8737a1d232a4a5a915
2019-06-19IVGCVSW-3271 Add unit test for dilated DepthwiseConvolution2dTeresa Charlin
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I0e7132f61001f7b2a9fad3d7b21acf2558c01df4
2019-06-19IVGCVSW-3231 Add reference workload support for SpaceToDepthKeith Davis
* Added reference workload for SpaceToDepth * Added unit tests for float32 & uint8 * Minor sort refactoring to RefWorkloads.hpp to alphabetical order Change-Id: I2e01f8101650e2aae102a8a32bc0064f067141ab Signed-off-by: Keith Davis <keith.davis@arm.com>
2019-06-18IVGCVSW-3264 Add Unit Test for Dilated Convolution2d to armnnTeresa Charlin
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I60da1414ab41ea196cdebc27f0f014a502274fa8
2019-06-17IVGCVSW-3286 Add epsilon Reference workload supportFerran Balaguer
Change-Id: I5cabbf9d1ef3858be68d6820d14845e512128c5b Signed-off-by: Ferran Balaguer <ferran.balaguer@arm.com>
2019-06-17IVGCVSW-3221 Refactor Mean ref workload and testsJames Conroy
* Renamed RefMeanFloat32Workload and RefMeanUint8Workload to RefMeanWorkload, updated references to reflect this change. * Refactored RefFloorWorkload to use Decoders/Encoders, to support the use of multiple data types. * Deleted reference Unit8 Mean tests as they were duplicates of the Float32 tests. Refactored these tests to support multiple data types and updated references. * Adjusted the values used in the tests' input tensors so that they are more like floating point numbers e.g. change 1.0f to 1.5f. * Replace size_t with unsigned int in Mean ref workload, for better compatibility with the Encoder/Decoder, removed some unnecessary casts after this. * Added ValidateTensorDataTypesMatch() function to WorkloadData.cpp, added CreateIncorrectDimensionsErrorMsg function to RefLayerSupport.cpp. * Added passing and failing tests for ref IsMeanSupported. Signed-off-by: James Conroy <james.conroy@arm.com> Change-Id: Id3d44463d1385255c727a497d4026d21a49e7eb2
2019-06-14IVGCVSW-3275 Add Uint8 support for L2NormalizationFerran Balaguer
Signed-off-by: Ferran Balaguer <ferran.balaguer@arm.com> Change-Id: I7f2bcf0596a4f654166aad9657bc7084f55e7451
2019-06-14IVGCVSW-3229 Refactor L2Normalization workload to support multiple data typesFerran Balaguer
Signed-off-by: Ferran Balaguer <ferran.balaguer@arm.com> Change-Id: I848056aad4b172d432664633eea000843d85a85d
2019-06-12IVGCVSW-3217 Refactor the Layer tests for ResizeBilinear to make them genericEllen Norris-Thompson
* Refactored the ResizeBilinear tests so can be used for both Float32 and Uint8. * Moved to .hpp file and renamed tests accordingly. Signed-off-by: Ellen Norris-Thompson <ellen.norris-thompson@arm.com> Change-Id: Icf79b0616db0c307cfcf94747fe0a6d4343588bd
2019-06-06IVGCVSW-3143 Extend the Pooling 2d workload to support QSymm16Teresa Charlin
Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: I4026a77377002f4f9c15a923e8fcb7075d700f6e
2019-06-05IVGCVSW-3216 Make Rsqrt f32 layers test genericnikraj01
Change-Id: Ibb8b71058039d0fb7345c2e6cba6382023541269 Signed-off-by: nikraj01 <nikhil.raj@arm.com>
2019-06-04IVGCVSW-3213 Extend the Reference BatchNormalization workload toMatteo Martincigh
support the new QSymm16 type * Added QSymm16 to the range of supported types for batch normalization ref workloads * Added unit tests for QSymm16 Change-Id: I5b2fcfbd9cb5af149ebfe24e2d95f3affa2e3690 Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
2019-05-31IVGCVSW-3177 Refactor Floor reference workloadJames Conroy
* Renamed RefFloorFloat32Workload to RefFloorWorkload and updated references to reflect this change. * RefFloorWorkload now uses Decoders/Encoders and supports the use of multiple data types. * Deleted FloorTestImpl.hpp and moved its contents into LayerTests.hpp. Change-Id: Ie079d05f2f6a578172f0fe3024f9607c030bce64 Signed-off-by: James Conroy <james.conroy@arm.com>
2019-05-31IVGCVSW-3195 Extend reference SpaceToBatch workload to support QSymm16nikraj01
Change-Id: I253eee2bbe1f48b94b03936af8f18603c1d58986 Signed-off-by: nikraj01 <nikhil.raj@arm.com>
2019-05-31IVGCVSW-3171 Extend the Strided Slice Ref workload to support the QSymm16Matteo Martincigh
* Added support for QSymm16 in the Strided Slice workload * Added unit tests Change-Id: I84485bc2fd5ad2b4edb49c644b644878e0e5aded Signed-off-by: Matteo Martincigh <matteo.martincigh@arm.com>
2019-05-30IVGCVSW-3159 Support QSymm16 for Splitter workloadsRuomei Yan
Change-Id: I9af5d2d8ade97b9ecd2e6fbf13db9fa3bb622ed8 Signed-off-by: Ruomei Yan <ruomei.yan@arm.com>
2019-05-29IVGCVSW-3173 Extend reference softmax workload to support qsymm16nikraj01
Change-Id: I9ad5a04368a4587588d733ac36ad157f79b6c432 Signed-off-by: nikraj01 <nikhil.raj@arm.com>
2019-05-29IVGCVSW-3172 Add QSymm16 support for reshape workloadNina Drozd
* Added QSymm16 to supported types in WorkloadData * Added QSymm16 to supported types in RefLayerSupport * Created templated SimpleReshapeTest in LayerTests * Updated ClLayerTests to use templated SimpleReshapeTest * Updated NeonLayerTests to use templated SimpleReshapeTest * Added test for QSymm16 to RefCreateWorkloadTests, RefLayerTests * Removed ReshapeTestImpl as all reshape test methods were moved * Added FloorTestImpl for existing SimpleFloorTest Change-Id: I78efede8aab74c2d4cb0841dd426b8e06186133d Signed-off-by: Nina Drozd <nina.drozd@arm.com>
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-23IVGCVSW-3026 Extend RefConvolution2dWorkload to support QSymm16Mike Kelly
* Added QuantisedSymm16 as supported type for Conv2D * Added Unit Tests for QSymm16 Signed-off-by: Mike Kelly <mike.kelly@arm.com> Change-Id: I4a8176091e75abfb0ea3a4b913c213111512df75
2019-05-23IVGCVSW-3074 Extend the DepthwiseConvolution2d workload to support QSymm16Ruomei Yan
Change-Id: I47bb0f782acfa5b2d2fee9132875f9a655ea635e Signed-off-by: Ruomei Yan <ruomei.yan@arm.com>
2019-05-23IVGCVSW-3025: Refactor reference Convolution2d workloadMike Kelly
* Refactored RefConvolution2dWorkload to support all DataTypes through Encoders and Decoders. * Added Convolute function to ConvImpl that uses Encoders and Decoders to support all DataTypes. * Deleted RefConvolution2dFloat32Workload and RefConvolution2dUint8Workload. Signed-off-by: Mike Kelly <mike.kelly@arm.com> Signed-off-by: Teresa Charlin <teresa.charlinreyes@arm.com> Change-Id: Ic5ef0f499d08b948fa65fdee54b5f681fd0b1c05
2019-05-20IVGCVSW-3125 Deprecate CreateMergerDescriptorForConcatenation functionJim Flynn
!android-nn-driver:1183 Change-Id: Ia69995b7f09cb86b64611e8efd315413e3064ca1 Signed-off-by: Jim Flynn <jim.flynn@arm.com>
2019-05-20IVGCVSW-3124 Rename workloadFactory CreateMerger to CreateConcatJim Flynn
Change-Id: Id836372c0e4ef0c3996085facc4da6263366abcf Signed-off-by: Jim Flynn <jim.flynn@arm.com>
2019-05-20IVGCVSW-2967 Support QSymm16 for Constant workloadsNina Drozd
* Validate that output is any of supported types in WorkloadData * Validate that output is any of supported types in RefLayerSupport * Add test for constant with QuantisedSymm16 in LayerTests * Add test for creating constant workload in RefCreateWorkloadTests * Add test for constant with QuantisedSymm16 in RefLayerTests * Refactor RefConstantWorkload - BaseWorkload instead of TypedWorkload * Refactor RefConstantWorkload - remove m_RanOnce, use PostAllocationConfigure() Signed-off-by: Nina Drozd <nina.drozd@arm.com> Change-Id: Ic30e61319ef4ff9c367689901f7c6d498142a9c5
2019-05-16IVGCVSW-2972 Support QSymm16 for MergerJim Flynn
Change-Id: If2289b2d1fc20f4524fcf4620f01ea3a36d727d2 Signed-off-by: Jim Flynn <jim.flynn@arm.com>
2019-05-14MLCE-101 Add dilation support for DepthWiseConv workloadBruno Goncalves
Adds unit tests for dilated depthwise conv Change-Id: Iad0a1b33d07fb0ef8f9f6edf0fd0f83a5800a36d Signed-off-by: Bruno Goncalves <bruno.slackware@gmail.com> Signed-off-by: Matthew Bentham <matthew.bentham@arm.com>
2019-05-13IVGCVSW-3013 Add unit tests for QSymm16 LSTMConor Kennedy
* Add unit tests for QSymm16 LSTM * Update supportedTypes in WorkloadData & RefLayerSupport with DataType::QuantisedSymm16 Change-Id: I1a2627b11b707d68d7d7002f63b985f9571ee177 Signed-off-by: Conor Kennedy <conor.kennedy@arm.com>
2019-04-10IVGCVSW-2947 Remove boost dependency from include/TypesUtils.hppAron Virginas-Tar
!android-nn-driver:968 Signed-off-by: Aron Virginas-Tar <Aron.Virginas-Tar@arm.com> Change-Id: I03ccb4842b060a9893567542bfcadc180bbc7311
2019-04-10IVGCVSW-2946 RefElementwiseWorkload configures prior to first executeDerek Lamberti
+ Added PostAllocationConfigure() method to workload interface + Elementwise function now deduces types based on Functor - Replaced RefComparisonWorkload with RefElementwiseWorkload specialization + Fixed up unit tests and minor formatting Change-Id: I33d08797767bba01cf4efb2904920ce0f950a4fe Signed-off-by: Derek Lamberti <derek.lamberti@arm.com>