Fix FP16, BF16 data ranges for conformance tests

Enable use of data ranges for old data gen path as well
as the new generate library path, so that FP16 and BF16 test data
is produced within the correct ranges.

Signed-off-by: Jeremy Johnson <jeremy.johnson@arm.com>
Change-Id: I749870a3112f8c3a75f4d16b8322c813fbf977cd
diff --git a/verif/generator/tosa_test_gen.py b/verif/generator/tosa_test_gen.py
index 3e5aee8..9dc3199 100644
--- a/verif/generator/tosa_test_gen.py
+++ b/verif/generator/tosa_test_gen.py
@@ -176,8 +176,11 @@
             # Inclusive range: low <= range <= high
             return (rng[0], rng[1] - 1)
 
-    def getRandTensor(self, shape, dtype):
-        low, high = self.getDTypeRange(dtype)
+    def getRandTensor(self, shape, dtype, data_range=None):
+        if data_range is None:
+            low, high = self.getDTypeRange(dtype)
+        else:
+            low, high = data_range
 
         if dtype == DType.BOOL:
             return np.bool_(self.rng.choice(a=[False, True], size=shape))