Home
last modified time | relevance | path

Searched refs:log_prob (Results 1 – 25 of 76) sorted by relevance

1234

/external/tensorflow/tensorflow/contrib/distributions/python/kernel_tests/
Dgeometric_test.py67 log_prob = geom.log_prob(x)
68 self.assertEqual([6,], log_prob.get_shape())
69 self.assertAllClose(expected_log_prob, log_prob.eval())
84 log_prob = geom.log_prob(x)
85 log_prob.eval(feed_dict=feed_dict)
88 log_prob = geom.log_prob(np.array([-1.], dtype=np.float32))
89 log_prob.eval()
92 log_prob = geom.log_prob(x)
93 self.assertEqual([6,], log_prob.get_shape())
105 log_prob = geom.log_prob(x)
[all …]
Dwishart_test.py212 self.assertAllClose(log_prob_df_seq, w.log_prob(chol_x).eval())
217 log_prob = np.array([
239 self.assertAllClose(log_prob[0], w.log_prob(x[0]).eval())
240 self.assertAllClose(log_prob[0:2], w.log_prob(x[0:2]).eval())
242 np.reshape(log_prob, (2, 2)),
243 w.log_prob(np.reshape(x, (2, 2, 2, 2))).eval())
245 np.reshape(np.exp(log_prob), (2, 2)),
248 w.log_prob(np.reshape(x, (2, 2, 2, 2))).get_shape())
261 self.assertAllClose(log_prob[0], w.log_prob(chol_x[0]).eval())
262 self.assertAllClose(log_prob[0:2], w.log_prob(chol_x[0:2]).eval())
[all …]
Dmvn_diag_plus_low_rank_test.py185 dist.log_prob(samps) - mvn_identity.log_prob(samps), 0)
189 dist.log_prob(samps) - mvn_scaled.log_prob(samps), 0)
193 dist.log_prob(samps) - mvn_diag.log_prob(samps), 0)
197 dist.log_prob(samps) - mvn_chol.log_prob(samps), 0)
208 baseline.log_prob(samps) - mvn_identity.log_prob(samps), 0)
213 baseline.log_prob(samps) - mvn_scaled.log_prob(samps), 0)
218 baseline.log_prob(samps) - mvn_diag.log_prob(samps), 0)
222 baseline.log_prob(samps) - mvn_chol.log_prob(samps), 0)
Dvector_student_t_test.py50 def log_prob(self, x): member in _FakeVectorStudentT
69 return np.exp(self.log_prob(x))
93 self.assertAllClose(expected_mst.log_prob(x),
94 actual_mst.log_prob(x).eval(),
122 self.assertAllClose(expected_mst.log_prob(x),
123 actual_mst.log_prob(x).eval(),
155 self.assertAllClose(expected_mst.log_prob(x),
156 actual_mst.log_prob(x).eval(feed_dict=feed_dict),
186 self.assertAllClose(expected_mst.log_prob(x),
187 actual_mst.log_prob(x).eval(),
[all …]
Dmixture_same_family_test.py44 log_prob_x = gm.log_prob(x)
55 log_prob_x = gm.log_prob(x)
67 log_prob_x = bm.log_prob(x)
81 log_prob_x = gm.log_prob(x)
96 log_prob_x = gm.log_prob(x)
Dtransformed_distribution_test.py102 for func in [[log_normal.log_prob, sp_dist.logpdf],
147 abs_normal.log_prob(2.13).eval())
180 sample_val, log_pdf_val = sess.run([sample, log_normal.log_prob(sample)])
208 sample_val, log_pdf_val = sess.run([sample, exp_normal.log_prob(sample)])
228 multi_logit_normal.log_prob(y).eval())
255 normal.log_prob(y).eval()
285 log_prob = exp2.log_prob(1.)
286 log_prob_ = sess.run(log_prob)
396 fake_mvn.log_prob(x),
534 fake_mvn.log_prob(x),
Dnegative_binomial_test.py131 log_pmf = negbinom.log_prob(x)
150 log_pmf = negbinom.log_prob(x)
154 log_pmf = negbinom.log_prob([-1.])
159 log_pmf = negbinom.log_prob(x)
175 log_pmf = negbinom.log_prob(x)
251 log_prob_ = sess.run(nb.log_prob(x))
262 log_prob_ = sess.run(nb.log_prob(x))
Dbatch_reshape_test.py76 wishart.log_prob(x), expected_log_prob_shape)
77 actual_log_prob = reshape_wishart.log_prob(expected_sample)
202 normal.log_prob(x), expected_log_prob_shape)
203 actual_log_prob = reshape_normal.log_prob(expected_sample)
323 mvn.log_prob(x), expected_log_prob_shape)
324 actual_log_prob = reshape_mvn.log_prob(expected_sample)
544 poisson_141_reshaped.log_prob(x_4)
547 poisson_141_reshaped.log_prob(x_114)
552 poisson_141_reshaped.log_prob(x_4).eval()
556 poisson_141_reshaped.log_prob(x_114).eval()
Dnormal_conjugate_posteriors_test.py50 posterior_log_pdf = posterior.log_prob(x).eval()
71 posterior_log_pdf = posterior.log_prob(x).eval()
96 posterior_log_pdf = posterior.log_prob(x)
115 predictive_log_pdf = predictive.log_prob(x).eval()
Dlogistic_test.py51 log_prob = dist.log_prob(x)
52 self.assertEqual(log_prob.get_shape(), (6,))
53 self.assertAllClose(log_prob.eval(), expected_log_prob)
168 self.assertEqual(dist.loc.dtype, dist.log_prob(0.2).dtype)
Drelaxed_bernoulli_test.py111 self.assertEqual(dist.probs.dtype, dist.log_prob([0.0]).dtype)
130 log_pdf = dist.log_prob(xs).eval()
137 self.assertAllClose(np.nan, dist.log_prob(0.0).eval())
138 self.assertAllClose([np.nan], [dist.log_prob(1.0).eval()])
Dpoisson_test.py62 log_pmf = poisson.log_prob(x)
80 log_pmf = poisson.log_prob(x)
84 log_pmf = poisson.log_prob([-1.])
88 log_pmf = poisson.log_prob(x)
101 log_pmf = poisson.log_prob(x)
Dsinh_arcsinh_test.py122 norm_lp, sasnorm_lp = sess.run([norm.log_prob(x), sasnorm.log_prob(x)])
164 norm_lp, sasnorm_lp = sess.run([norm.log_prob(x), sasnorm.log_prob(x)])
Dvector_sinh_arcsinh_diag_test.py114 norm_lp, sasnorm_lp = sess.run([norm.log_prob(x), sasnorm.log_prob(x)])
159 norm_lp, sasnorm_lp = sess.run([norm.log_prob(x), sasnorm.log_prob(x)])
Dquantized_distribution_test.py311 np.log(sm_normal.cdf(-2)), qdist.log_prob(-2.).eval(), atol=0)
315 qdist.log_prob(-1.).eval(),
320 qdist.log_prob(0.).eval(),
324 np.log(1. - sm_normal.cdf(1)), qdist.log_prob(2.).eval(), atol=0)
336 proba = qdist.log_prob(x)
Dindependent_test.py61 log_prob_x = ind.log_prob(x)
84 log_prob_x = ind.log_prob(x)
113 sample_entropy = -math_ops.reduce_mean(ind.log_prob(x), axis=0)
240 log_prob_x = ind.log_prob(x)
Dmvn_tril_test.py55 log_pdf = mvn.log_prob(x)
75 log_pdf = mvn.log_prob(x)
96 log_pdf = mvn.log_prob(x)
181 log_prob_val = mvn.log_prob(samples_val).eval()
358 dist.log_prob(samps) - mvn_chol.log_prob(samps), 0)
/external/tensorflow/tensorflow/python/kernel_tests/distributions/
Dcategorical_test.py107 dist.logits.dtype, dist.log_prob(np.array(
291 "cat_log_prob": cat.log_prob(disc_event_tf),
295 "norm_log_prob": norm.log_prob(real_event_tf),
317 self.assertAllClose(dist.log_prob([0, 1]).eval(), np.log([0.2, 0.4]))
318 self.assertAllClose(dist.log_prob([0.0, 1.0]).eval(), np.log([0.2, 0.4]))
438 log_prob = dist.log_prob([0, 1])
439 self.assertEqual(2, log_prob.get_shape().ndims)
440 self.assertAllEqual([1, 2], log_prob.get_shape())
442 log_prob = dist.log_prob([[[1, 1], [1, 0]], [[1, 0], [0, 1]]])
443 self.assertEqual(3, log_prob.get_shape().ndims)
[all …]
Dbernoulli_test.py122 self.assertEqual(dist.probs.dtype, dist.log_prob(0).dtype)
123 self.assertEqual(dist.probs.dtype, dist.log_prob(0.5).dtype)
152 self.assertAllClose(self.evaluate(dist.log_prob(x)), np.log(expected_pmf))
196 bernoulli.Bernoulli(probs=p, validate_args=False).log_prob(samps)))
203 self.assertAllClose(np.log(0.5), dist.log_prob(1).eval({p: 0.5}))
205 np.log([0.5, 0.5, 0.5]), dist.log_prob([1, 1, 1]).eval({
209 np.log([0.5, 0.5, 0.5]), dist.log_prob(1).eval({
218 self.assertEqual(2, len(dist.log_prob(1).eval({p: [[0.5], [0.5]]}).shape))
221 self.assertEqual(2, len(self.evaluate(dist.log_prob([[1], [1]])).shape))
224 self.assertEqual((), dist.log_prob(1).get_shape())
[all …]
Ddirichlet_test.py93 log_prob = self.evaluate(dist.log_prob(x))
95 np.ones_like(log_prob, dtype=np.bool), np.isfinite(log_prob))
99 log_prob = self.evaluate(dist.log_prob(x))
101 np.ones_like(log_prob, dtype=np.bool), np.isfinite(log_prob))
282 kl_sample = math_ops.reduce_mean(d1.log_prob(x) - d2.log_prob(x), 0)
/external/tensorflow/tensorflow/contrib/bayesflow/python/kernel_tests/
Dmonte_carlo_test.py55 f=lambda x: x, log_p=p.log_prob, sampling_dist_q=q, n=n, seed=42)
59 f=math_ops.square, log_p=p.log_prob, sampling_dist_q=q, n=n, seed=42)
88 f=indicator, log_p=p.log_prob, sampling_dist_q=q, n=n, seed=42)
114 log_p=p.log_prob,
177 efx_reparam = mc.expectation(f, samples, p.log_prob)
178 efx_score = mc.expectation(f, samples, p.log_prob,
224 f=lambda x: p.log_prob(x) - q.log_prob(x),
226 log_prob=p.log_prob,
/external/tensorflow/tensorflow/contrib/bayesflow/python/ops/
Dmonte_carlo_impl.py87 q_log_prob_z = q.log_prob(z)
160 log_values = log_f(z) + log_p(z) - q.log_prob(z)
198 def expectation(f, samples, log_prob=None, use_reparametrization=True, argument
333 if not callable(log_prob):
337 logpx = log_prob(x)
/external/tensorflow/tensorflow/core/kernels/
Dctc_decoder_ops.cc59 Tensor** log_prob, OpOutputList* decoded_indices, in ValidateInputsGenerateOutputs() argument
99 "log_probability", TensorShape({batch_size, top_paths_}), log_prob); in ValidateInputsGenerateOutputs()
182 Tensor* log_prob = nullptr; in Compute() local
187 ctx, &inputs, &seq_len, &log_prob, &decoded_indices, in Compute()
208 auto log_prob_t = log_prob->matrix<float>(); in Compute()
270 Tensor* log_prob = nullptr; in Compute() local
275 ctx, &inputs, &seq_len, &log_prob, &decoded_indices, in Compute()
280 auto log_prob_t = log_prob->matrix<float>(); in Compute()
/external/tensorflow/tensorflow/contrib/distributions/python/ops/
Dconditional_transformed_distribution.py123 log_prob = self.distribution.log_prob(x, **distribution_kwargs)
125 log_prob = math_ops.reduce_sum(log_prob, self._reduce_event_indices)
126 return math_ops.cast(ildj, log_prob.dtype) + log_prob
/external/tensorflow/tensorflow/python/ops/distributions/
Dtransformed_distribution.py442 log_prob = self.distribution.log_prob(x)
444 log_prob = math_ops.reduce_sum(log_prob, self._reduce_event_indices)
445 log_prob += math_ops.cast(ildj, log_prob.dtype)
447 log_prob.set_shape(
451 return log_prob

1234