aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/fixtures/GatherFixture.h
diff options
context:
space:
mode:
Diffstat (limited to 'tests/validation/fixtures/GatherFixture.h')
-rw-r--r--tests/validation/fixtures/GatherFixture.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/validation/fixtures/GatherFixture.h b/tests/validation/fixtures/GatherFixture.h
index f6f70023b9..b28f93d850 100644
--- a/tests/validation/fixtures/GatherFixture.h
+++ b/tests/validation/fixtures/GatherFixture.h
@@ -69,10 +69,9 @@ protected:
// 10% of the time the index is out-of-range.
uint32_t max_index = input_shape[actual_axis] + input_shape[actual_axis] / 9 + 1;
-
std::uniform_int_distribution<uint32_t> dist_index(0, max_index - 1);
- //Let's consider 1D indices
- for(unsigned int ind = 0; ind < indices_shape[0]; ind++)
+
+ for(unsigned int ind = 0; ind < indices_shape.total_size(); ind++)
{
indices_ptr[ind] = dist_index(gen);
}