aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/Reference.cpp
diff options
context:
space:
mode:
authorMoritz Pflanzer <moritz.pflanzer@arm.com>2017-08-09 11:45:15 +0100
committerAnthony Barbier <anthony.barbier@arm.com>2018-11-02 16:35:24 +0000
commit69d3341e6903c1ea87c46e39d6d3e64b2a0d5b4e (patch)
treefcb9afb7b9c51614bde40c978aa0d50849d27168 /tests/validation/Reference.cpp
parent75af28e6936f084fdfa65add7631cd2cd2050b0c (diff)
downloadComputeLibrary-69d3341e6903c1ea87c46e39d6d3e64b2a0d5b4e.tar.gz
COMPMID-415: Move FullyConnectedLayer to new validation
Change-Id: I7f60d6fb484d3962b88874e1531cec734c11e416 Reviewed-on: http://mpd-gerrit.cambridge.arm.com/83556 Tested-by: Kaizen <jeremy.johnson+kaizengerrit@arm.com> Reviewed-by: Anthony Barbier <anthony.barbier@arm.com>
Diffstat (limited to 'tests/validation/Reference.cpp')
-rw-r--r--tests/validation/Reference.cpp40
1 files changed, 0 insertions, 40 deletions
diff --git a/tests/validation/Reference.cpp b/tests/validation/Reference.cpp
index 16b4cb9217..1ea017e998 100644
--- a/tests/validation/Reference.cpp
+++ b/tests/validation/Reference.cpp
@@ -461,46 +461,6 @@ RawTensor Reference::compute_reference_batch_normalization_layer(const TensorSha
return ref_dst;
}
-RawTensor Reference::compute_reference_fully_connected_layer(const TensorShape &input_shape, const TensorShape &weights_shape, const TensorShape &bias_shape, const TensorShape &output_shape,
- DataType dt, bool transpose_weights, int fixed_point_position)
-{
- // Create reference
- RawTensor ref_src(input_shape, dt, 1, fixed_point_position);
- RawTensor ref_bias(bias_shape, dt, 1, fixed_point_position);
- RawTensor ref_dst(output_shape, dt, 1, fixed_point_position);
-
- // Swap the first and second dimension of weights' shape if transpose_weights is true
- TensorShape ws = weights_shape;
- if(transpose_weights)
- {
- const size_t dimx = ws.x();
- ws.set(0, ws.y());
- ws.set(1, dimx);
- }
-
- RawTensor ref_weights(ws, dt, 1, fixed_point_position);
-
- // Fill reference
- if(dt == DataType::F16 || dt == DataType::F32)
- {
- std::uniform_real_distribution<> distribution(-1.0f, 1.0f);
- library->fill(ref_src, distribution, 0);
- library->fill(ref_weights, distribution, 1);
- library->fill(ref_bias, distribution, 2);
- }
- else
- {
- library->fill_tensor_uniform(ref_src, 0);
- library->fill_tensor_uniform(ref_weights, 1);
- library->fill_tensor_uniform(ref_bias, 2);
- }
-
- // Compute reference
- ReferenceCPP::fully_connected_layer(ref_src, ref_weights, ref_bias, ref_dst);
-
- return ref_dst;
-}
-
RawTensor Reference::compute_reference_pooling_layer(const TensorShape &shape_in, const TensorShape &shape_out, DataType dt, PoolingLayerInfo pool_info, int fixed_point_position)
{
// Create reference