Home
last modified time | relevance | path

Searched refs:newaxis (Results 1 – 25 of 72) sorted by relevance

123

/external/tensorflow/tensorflow/python/ops/distributions/
Dmultinomial.py207 self._mean_val = self._total_count[..., array_ops.newaxis] * self._probs
254 n_draws[..., array_ops.newaxis], dtype=self.logits.dtype) * self.logits
263 x = random_ops.multinomial(logits[array_ops.newaxis, ...], n_draw,
296 self.total_count)[..., array_ops.newaxis]
298 -math_ops.matmul(self._mean_val[..., array_ops.newaxis],
299 p[..., array_ops.newaxis, :]), # outer product
304 self.total_count)[..., array_ops.newaxis]
Ddirichlet.py264 return self.concentration / self.total_concentration[..., array_ops.newaxis]
269 -math_ops.matmul(x[..., array_ops.newaxis],
270 x[..., array_ops.newaxis, :]), # outer prod
280 return math_ops.rsqrt(1. + self.total_concentration[..., array_ops.newaxis])
290 self.total_concentration[..., array_ops.newaxis] - k)
Ddirichlet_multinomial.py295 self.total_concentration[..., array_ops.newaxis])
318 -math_ops.matmul(x[..., array_ops.newaxis],
319 x[..., array_ops.newaxis, :]), # outer prod
331 c0 = self.total_concentration[..., array_ops.newaxis]
/external/tensorflow/tensorflow/contrib/distributions/python/ops/
Dvector_diffeomixture.py114 (normal_loc[..., array_ops.newaxis] +
115 np.sqrt(2.) * normal_scale[..., array_ops.newaxis] * grid),
704 p[..., k, array_ops.newaxis])
708 (p[..., k, array_ops.newaxis] * math_ops.square(s.multiplier)))
710 diag = add(diag, (p[..., k, array_ops.newaxis] *
713 x = (p[..., k, array_ops.newaxis, array_ops.newaxis] *
728 diag *= v[..., array_ops.newaxis]
730 full *= v[..., array_ops.newaxis]
737 return scale_identity_multiplier[..., array_ops.newaxis] * ones
768 p = p[..., array_ops.newaxis, :] # Assuming event.ndims=1.
[all …]
Dpoisson_lognormal.py92 grid = (loc[..., array_ops.newaxis]
93 + np.sqrt(2.) * scale[..., array_ops.newaxis] * grid)
404 + self.distribution.log_prob(x[..., array_ops.newaxis])),
439 - self._mean()[..., array_ops.newaxis])),
442 self.mixture_distribution.logits[..., array_ops.newaxis] + v,
Ddistribution_util.py166 tril_diag += scale_identity_multiplier[..., array_ops.newaxis]
248 scale_diag += scale_identity_multiplier[..., array_ops.newaxis]
315 event_shape = event_size[array_ops.newaxis]
Dmvn_linear_operator.py349 b_inv_a = (a.stddev() / b.stddev())[..., array_ops.newaxis]
358 (b.mean() - a.mean())[..., array_ops.newaxis]))))
/external/tensorflow/tensorflow/contrib/distributions/python/ops/bijectors/
Dordered.py81 return (input_shape[-1])[..., array_ops.newaxis]
96 return (output_shape[-1])[..., array_ops.newaxis]
100 y0 = x[..., 0, array_ops.newaxis]
106 x0 = y[..., 0, array_ops.newaxis]
Dsoftmax_centered.py88 return (input_shape[-1] + 1)[..., array_ops.newaxis]
104 return (output_shape[-1] - 1)[..., array_ops.newaxis]
133 log_normalization = (-x[..., -1])[..., array_ops.newaxis]
Dcholesky_outer_product.py181 exponents[..., array_ops.newaxis]),
218 x = x[array_ops.newaxis, :]
/external/tensorflow/tensorflow/python/ops/linalg/
Dlinear_operator_kronecker.py333 output = output[array_ops.newaxis, ...]
450 output = output[array_ops.newaxis, ...]
507 diag_part = diag_part[..., :, array_ops.newaxis]
508 op_diag_part = operator.diag_part()[..., array_ops.newaxis, :]
527 ..., :, array_ops.newaxis, :, array_ops.newaxis]
530 ..., array_ops.newaxis, :, array_ops.newaxis, :]
Dlinalg_impl.py288 array_ops.newaxis,
289 array_ops.newaxis])
306 array_ops.newaxis,
307 array_ops.newaxis])
/external/tensorflow/tensorflow/compiler/tests/
Dimage_ops_test.py423 out = sess.run(resized, {image: image_np[np.newaxis, :, :, np.newaxis]})
426 expected[np.newaxis, :, :, np.newaxis], out, rtol=2e-4, atol=2e-4)
428 self.assertAllClose(expected[np.newaxis, :, :, np.newaxis], out)
531 out = sess.run(resized, {image: image_np[np.newaxis, :, :, np.newaxis]})
534 expected[np.newaxis, :, :, np.newaxis], out, rtol=0.03, atol=0.1)
536 self.assertAllClose(expected[np.newaxis, :, :, np.newaxis], out)
554 out = sess.run(resized, {grads: grads_np[np.newaxis, :, :, np.newaxis]})
555 self.assertAllCloseAccordingToType(expected[np.newaxis, :, :, np.newaxis],
729 out = sess.run(resized, {image: input_image[:, :, :, np.newaxis]})
730 self.assertAllClose(expected[:, :, :, np.newaxis], out)
Dgather_nd_op_test.py112 np.vstack((params[np.newaxis, :], params[np.newaxis, :])),
/external/tensorflow/tensorflow/contrib/gan/python/eval/python/
Dsliced_wasserstein_test.py43 gaussian_filter[np.newaxis, np.newaxis, :, :],
53 gaussian_filter[np.newaxis, np.newaxis, :, :] * 4.0,
/external/tensorflow/tensorflow/python/kernel_tests/linalg/
Dlinear_operator_kronecker_test.py41 product = product[..., array_ops.newaxis, :, array_ops.newaxis]
42 factor_to_mul = factor[..., array_ops.newaxis, :, array_ops.newaxis, :]
/external/tensorflow/tensorflow/contrib/training/python/training/
Dbatch_sequences_with_states_test.py233 self.sequences["seq1"][np.newaxis, 0:num_unroll, :],
236 self.sequences["seq2"][np.newaxis, 0:num_unroll, :, :],
239 self.sequences["seq1"][np.newaxis, num_unroll:self.value_length, :],
242 self.sequences["seq2"][np.newaxis, num_unroll:self.value_length, :, :],
368 self.sequences["seq1"][np.newaxis, 0:num_unroll, :],
371 self.sequences["seq2"][np.newaxis, 0:num_unroll, :, :],
376 self.sequences["seq1"][np.newaxis, num_unroll:self.value_length, :],
385 self.sequences["seq2"][np.newaxis, num_unroll:self.value_length, :],
/external/tensorflow/tensorflow/python/kernel_tests/
Dctc_decoder_ops_test.py144 ], np.float32)[:, np.newaxis]
198 input_prob_matrix_0[t, :][np.newaxis, :] for t in range(seq_len_0)
212 np.float32)[np.newaxis, :]
Darray_ops_test.py666 ones[array_ops.newaxis, :, 0].eval(
707 _ = checker[np.newaxis]
709 _ = checker[..., np.newaxis]
711 _ = checker[..., np.newaxis, :]
712 _ = checker[:, ..., np.newaxis, :, :]
714 _ = checker[:, :, np.newaxis, :, 2::-1]
716 _ = checker[np.newaxis, ..., np.newaxis]
737 _ = checker[np.newaxis, ..., np.newaxis]
741 _ = checker[np.newaxis, 1:]
807 self.tensorShapeEqual(a[3:5, :, array_ops.newaxis, 50:3,],
[all …]
/external/tensorflow/tensorflow/python/ops/ragged/
Dragged_getitem.py137 if row_key is array_ops.newaxis:
246 if column_key is array_ops.newaxis:
304 num_indices = sum(1 for idx in key_list if idx is not array_ops.newaxis)
Dragged_tensor_test.py808 (SLICE_BUILDER[array_ops.newaxis, :], [EXAMPLE_RAGGED_TENSOR_2D]),
809 (SLICE_BUILDER[:, array_ops.newaxis],
909 (SLICE_BUILDER[array_ops.newaxis, :], [EXAMPLE_RAGGED_TENSOR_4D]),
910 (SLICE_BUILDER[:, array_ops.newaxis],
1035 rt_newaxis0 = rt[array_ops.newaxis]
1036 rt_newaxis1 = rt[:, array_ops.newaxis]
1037 rt_newaxis2 = rt[:, :, array_ops.newaxis]
1038 rt_newaxis3 = rt[:, :, :, array_ops.newaxis]
1039 rt_newaxis4 = rt[:, :, :, :, array_ops.newaxis]
/external/tensorflow/tensorflow/contrib/distributions/python/kernel_tests/
Dvector_student_t_test.py239 loc=np.tile(loc[array_ops.newaxis, :], reps=[len(df), 1]),
240 scale_tril=np.tile(scale_tril[array_ops.newaxis, :, :],
265 loc=np.tile(loc[array_ops.newaxis, :], reps=[len(df), 1]),
266 scale_tril=np.tile(scale_tril[array_ops.newaxis, :, :],
/external/tensorflow/tensorflow/python/kernel_tests/signal/
Dreconstruction_ops_test.py44 powers = np.power(self.bases[:, np.newaxis], exponents[np.newaxis, :])
187 input_matrix = input_matrix[np.newaxis, :, :].astype(float)
/external/tensorflow/tensorflow/python/data/experimental/kernel_tests/serialization/
Dparallel_map_dataset_serialization_test.py44 np.arange(self._tensor_slice_len)[:, np.newaxis],
55 np.arange(self._tensor_slice_len)[:, np.newaxis],
/external/tensorflow/tensorflow/python/kernel_tests/distributions/
Dmultinomial_test.py269 theta /= np.sum(theta, 1)[..., array_ops.newaxis]
276 x_centered = x - sample_mean[array_ops.newaxis, ...]
278 x_centered[..., array_ops.newaxis],
279 x_centered[..., array_ops.newaxis, :]), 0)

123