HomeSort by relevance Sort by last modified time
    Searched refs:numpy (Results 26 - 50 of 1069) sorted by null

12 3 4 5 6 7 8 91011>>

  /external/tensorflow/tensorflow/contrib/framework/python/ops/
accumulate_n_v2_eager_test.py 25 import numpy as np
47 self.assertEqual(42, answer.numpy())
55 self.assertAllClose(sum(x), av2.accumulate_n_v2(tf_x).numpy())
56 self.assertAllClose(x[0] * 5, av2.accumulate_n_v2([tf_x[0]] * 5).numpy())
73 [elem.numpy() for elem in grad])
  /cts/apps/CameraITS/pymodules/its/
cv2image.py 23 import numpy
102 template: numpy array; chart template for locator
103 img_3a: numpy array; RGB image for chart location
155 if numpy.amax(scene) <= 1.0:
156 scene = (scene * 255.0).astype(numpy.uint8)
159 for scale in numpy.arange(scale_start, scale_stop, scale_step):
228 input_img (2D numpy.ndarray): Grayscale image stored as a 2D
229 numpy array.
238 img = numpy.array(input_img, copy=True)
242 img = img.astype(numpy.uint8
    [all...]
  /cts/apps/CameraITS/tests/sensor_fusion/
test_sensor_fusion.py 30 import numpy
123 # RGB images as numpy arrays.
204 candidates = numpy.arange(-50, 50.5, 0.5).tolist()
224 a, b, c = numpy.polyfit(candidates, dists, 2)
232 xfit = numpy.arange(candidates[0], candidates[-1], 0.05).tolist()
280 all_times = numpy.array([e["time"] for e in gyro_events])
281 all_rots = numpy.array([e["z"] for e in gyro_events])
311 gyro_rots = numpy.array(gyro_rots)
322 frames: List of N images (as RGB numpy arrays).
331 frame = (frame * 255.0).astype(numpy.uint8
    [all...]
  /external/autotest/server/brillo/
audio_utils.py 9 import numpy
204 fft_reference = numpy.fft.rfft(reference_data)
205 fft_rec = numpy.fft.rfft(rec_data)
206 fft_freqs_reference = numpy.fft.rfftfreq(len(reference_data),
208 fft_freqs_rec = numpy.fft.rfftfreq(len(rec_data), 1.0 / sample_rate)
212 numpy.argmax(numpy.abs(fft_reference))]
213 abs_fft_rec = numpy.abs(fft_rec)
214 freq_rec = fft_freqs_rec[numpy.argmax(abs_fft_rec)]
226 fft_rec_peak_val = numpy.max(abs_fft_rec
    [all...]
  /external/tensorflow/tensorflow/contrib/timeseries/python/timeseries/state_space_models/
state_space_model_test.py 23 import numpy
61 self.transition = numpy.random.normal(
64 self.noise_transform = numpy.random.normal(
68 self.observation_model = numpy.random.normal(
156 self._gap_test_template(times=[20, 21, 22], values=numpy.arange(3))
159 self._gap_test_template(times=[2, 60, 61], values=numpy.arange(3))
162 self._gap_test_template(times=[2, 3, 73], values=numpy.arange(3))
166 values=numpy.arange(7))
336 numpy.random.seed(2)
341 numpy.random.seed(4
    [all...]
structural_ensemble_test.py 21 import numpy
40 time = sample_every * numpy.arange(num_samples)
41 noise = numpy.random.normal(
43 values = noise + numpy.sin(
44 numpy.arange(num_features)[None, ...]
45 + time[..., None] / float(period) * 2.0 * numpy.pi).astype(
47 return {TrainEvalFeatures.TIMES: numpy.reshape(time, [1, -1]),
48 TrainEvalFeatures.VALUES: numpy.reshape(
54 numpy.random.seed(1)
kalman_filter_test.py 21 import numpy
102 evaled_state = numpy.array([[1., 1., 1., 1.]])
103 evaled_state_var = numpy.eye(4)[None]
152 self.assertAllClose(numpy.array([[1., 1.]]),
154 self.assertAllClose(numpy.array([[1., 1.]]),
156 self.assertAllClose(numpy.array([[[1.0001, 0.], [0., 3.0002]]]),
158 self.assertAllClose(numpy.array([[[1.01, 0.], [0., 3.02]]]),
195 expected_state=numpy.array([[0.5]]),
205 expected_state=numpy.array([[0.5]]),
215 expected_state=numpy.array([[2., 1.]])
    [all...]
  /cts/apps/CameraITS/tests/scene1/
test_param_noise_reduction.py 22 import numpy
101 rgb_snrs = [numpy.mean(r_snrs), numpy.mean(g_snrs), numpy.mean(b_snrs)]
142 assert(numpy.isclose(snrs[j][4], snrs[j][3],
146 assert(numpy.isclose(snrs[j][4], snrs[j][0],
  /external/tensorflow/tensorflow/compiler/xla/python/
local_computation_builder.i 28 // Literal <-> (nested tuple of) numpy ndarray
46 // where a terminal numpy ndarray translates to a Literal with a
50 // recursively. For example, if x is a numpy ndarray in Python, with
69 // dtype('O'), numpy's object dtype, the structure represents a tuple
114 #include "tensorflow/python/lib/core/numpy.h"
134 const int64 value = numpy::PyIntOrPyLongToLong(fo);
156 const int64 handle = numpy::PyIntOrPyLongToLong($input);
165 $result = numpy::LongToPyIntOrPyLong($1.handle());
184 $result = numpy::PyObjectFromXlaLiteral(*value);
206 $result = numpy::PyShapeInfoFromXlaShape($1.ConsumeValueOrDie())
    [all...]
  /cts/apps/CameraITS/tests/inprog/
test_burst_sameness_fullres_auto.py 20 import numpy
61 imgs = numpy.empty([FRAMES,h/4,w/4,3])
84 delta_max_pos = numpy.max(deltas)
85 delta_max_neg = numpy.min(deltas)
  /external/lmfit/test/
py_qr.py 4 import numpy as np
  /external/tensorflow/tensorflow/contrib/data/python/ops/
enumerate_ops.py 20 import numpy as np
  /external/tensorflow/tensorflow/examples/speech_commands/
generate_streaming_test_wav_test.py 21 import numpy as np
  /test/vts/testcases/vts_selftest/test_framework/python_virtualenv_preparer_test/part1/
VtsSelfTestPythonVirtualenvPreparerTestPart1.py 37 import numpy
39 asserts.fail('numpy is not installed from plan level preparer.')
  /external/tensorflow/tensorflow/contrib/timeseries/examples/
lstm.py 25 import numpy
216 "2d_exogenous_feature": numpy.concatenate(
217 [numpy.ones([1, 100, 1]), numpy.zeros([1, 100, 1])],
225 predicted_mean = numpy.squeeze(numpy.concatenate(
227 all_times = numpy.concatenate([times, predictions["times"]], axis=0)
247 numpy.testing.assert_allclose(
249 numpy.squeeze(saved_model_output["mean"], axis=0))
  /external/tensorflow/tensorflow/python/kernel_tests/
constant_op_eager_test.py 21 import numpy as np
40 tf_ans = ops.convert_to_tensor(x).numpy()
51 tf_ans = ops.convert_to_tensor(x).numpy()
70 self.assertAllClose(np.array(orig), tf_ans.numpy())
76 self.assertAllClose(np.array(orig), tf_ans.numpy())
81 self.assertAllClose(np.array(orig), tf_ans.numpy())
87 self.assertAllClose(np.array(orig), tf_ans.numpy())
98 self.assertAllClose(np.array(orig), tf_ans.numpy())
102 self.assertEqual(2**54, tf_ans.numpy())
125 self.assertAllClose(np.array(orig), tf_ans.numpy())
    [all...]
draw_bounding_box_op_test.py 21 import numpy as np
38 image: Numpy array of shape [height, width, depth].
39 color: Numpy color of shape [depth] and either contents RGB/RGBA.
61 img: 3-D numpy image on which to draw.
  /external/autotest/client/cros/audio/
audio_quality_measurement.py 10 import numpy
156 x = numpy.asarray(x)
157 if numpy.iscomplexobj(x):
164 Xf = numpy.fft.fft(x, N, axis=axis)
165 h = numpy.zeros(N)
177 x = numpy.fft.ifft(Xf * h, axis=axis)
195 noise = noise_level * numpy.random.standard_normal()
303 result = numpy.asarray(result)
304 amplitude = numpy.abs(result)
305 phase = numpy.unwrap(numpy.angle(result)
    [all...]
  /tools/test/connectivity/acts/framework/acts/test_utils/audio_analysis_lib/
audio_quality_measurement.py 21 import numpy
162 x = numpy.asarray(x)
163 if numpy.iscomplexobj(x):
170 Xf = numpy.fft.fft(x, N, axis=axis)
171 h = numpy.zeros(N)
183 x = numpy.fft.ifft(Xf * h, axis=axis)
204 noise = noise_level * numpy.random.standard_normal()
321 result = numpy.asarray(result)
322 amplitude = numpy.abs(result)
323 phase = numpy.unwrap(numpy.angle(result)
    [all...]
audio_data.py 20 import numpy
28 dtype_str: Data type used in numpy dtype. Check
29 https://docs.scipy.org/doc/numpy/reference/arrays.dtypes.html
92 Reads samples of fixed width from binary string into a numpy array
100 # The data type used in numpy fromstring function. For example,
106 np_array = numpy.fromstring(binary, dtype=np_dtype)
  /external/tensorflow/tensorflow/contrib/eager/python/
metrics_test.py 42 self.assertEqual(111111.0/6, m.result().numpy())
61 self.assertEqual(111111.0/6, m.result().numpy())
64 self.assertEqual(7.0, m.result().numpy())
84 self.assertNear(535521/4.5, m.result().numpy(), 0.001)
90 self.assertEqual(1, m.result().numpy())
101 self.assertEqual(3.0/8, m.result().numpy())
113 self.assertEqual(2.5/5, m.result().numpy())
119 self.assertEqual(0.5, m.result().numpy())
  /external/tensorflow/tensorflow/examples/tutorials/mnist/
input_data.py 26 import numpy
  /cts/apps/CameraITS/tests/scene3/
test_reprocess_edge_enhancement.py 23 import numpy
77 ret["sharpness"] = numpy.mean(sharpness_list)
169 assert(numpy.isclose(sharpness_regular[3], sharpness_regular[0],
186 assert(numpy.isclose(sharpnesses_reprocess[reprocess_format][3],
202 assert(numpy.isclose(sharpnesses_reprocess[reprocess_format][2] /
  /external/autotest/client/cros/cellular/mbim_compliance/
mbim_channel_endpoint.py 10 import numpy
189 numpy.set_printoptions(formatter={'int':lambda x: hex(int(x))},
192 len(response), numpy.array(response))
209 numpy.set_printoptions(formatter={'int':lambda x: hex(int(x))},
213 actual_written, len(payload), numpy.array(payload))
  /external/autotest/client/site_tests/power_SuspendStress/
power_SuspendStress.py 5 import logging, numpy, random, time
98 keyvals[key + '_mean'] = numpy.mean(values)
99 keyvals[key + '_stddev'] = numpy.std(values)
100 keyvals[key + '_min'] = numpy.amin(values)
101 keyvals[key + '_max'] = numpy.amax(values)

Completed in 548 milliseconds

12 3 4 5 6 7 8 91011>>