/external/tensorflow/tensorflow/contrib/distributions/python/kernel_tests/bijectors/ |
D | affine_test.py | 61 self.assertAllClose([2., 0], run(bijector.forward, x)) 62 self.assertAllClose([0., 2], run(bijector.inverse, x)) 68 self.assertAllClose([[2., 0], [0., -2]], run(bijector.forward, x)) 69 self.assertAllClose([[0., 2], [-2., 0]], run(bijector.inverse, x)) 70 self.assertAllClose( 93 self.assertAllClose([3., 0], run(bijector.forward, x)) 94 self.assertAllClose([0., 2], run(bijector.inverse, x)) 95 self.assertAllClose( 106 self.assertAllClose([[3., 0], 109 self.assertAllClose([[0., 2], [all …]
|
D | affine_linear_operator_test.py | 39 self.assertAllClose(y, affine.forward(x).eval()) 40 self.assertAllClose(x, affine.inverse(y).eval()) 41 self.assertAllClose(ildj, affine.inverse_log_det_jacobian( 43 self.assertAllClose( 61 self.assertAllClose(y, affine.forward(x).eval()) 62 self.assertAllClose(x, affine.inverse(y).eval()) 63 self.assertAllClose( 65 self.assertAllClose( 95 self.assertAllClose(y, affine.forward(x).eval()) 96 self.assertAllClose(x, affine.inverse(y).eval()) [all …]
|
D | affine_scalar_test.py | 56 self.assertAllClose([1., 3, 5], run(bijector.forward, x)) 57 self.assertAllClose([1., 1.5, 2.], run(bijector.inverse, x)) 58 self.assertAllClose( 79 self.assertAllClose([2.], run(bijector.forward, x)) 80 self.assertAllClose([0.], run(bijector.inverse, x)) 81 self.assertAllClose( 102 self.assertAllClose([2.], run(bijector.forward, x)) 103 self.assertAllClose([0.5], run(bijector.inverse, x)) 104 self.assertAllClose( 125 self.assertAllClose([2., 0], run(bijector.forward, x)) [all …]
|
D | cholesky_outer_product_test.py | 51 self.assertAllClose(y, bijector.forward(x).eval()) 52 self.assertAllClose(x, bijector.inverse(y).eval()) 53 self.assertAllClose( 56 self.assertAllClose( 69 self.assertAllClose( 82 self.assertAllClose( 95 self.assertAllClose(y, y_actual_) 96 self.assertAllClose(x, x_actual_) 110 self.assertAllClose(y, y_actual_) 111 self.assertAllClose(x, x_actual_) [all …]
|
/external/tensorflow/tensorflow/python/debug/lib/ |
D | stepper_test.py | 94 self.assertAllClose(6.0, stepper.cont("c")) 103 self.assertAllClose(6.0, result) 106 self.assertAllClose(2.0, stepper.get_tensor_value("a/read:0")) 107 self.assertAllClose(3.0, stepper.get_tensor_value("b/read:0")) 113 self.assertAllClose(24.0, result) 116 self.assertAllClose(2.0, stepper.get_tensor_value("a/read:0")) 117 self.assertAllClose(3.0, stepper.get_tensor_value("b/read:0")) 118 self.assertAllClose(4.0, stepper.get_tensor_value("d:0")) 146 self.assertAllClose(6.0, result) 154 self.assertAllClose(6.0, stepper.get_tensor_value("c:0")) [all …]
|
D | debug_gradients_test.py | 69 self.assertAllClose(5.0, self.sess.run(y)) 70 self.assertAllClose(3.0, self.sess.run(u_grad)) 71 self.assertAllClose(2.0, self.sess.run(v_grad)) 76 self.assertAllClose(1.0, self.sess.run(w_grad)) 81 self.assertAllClose(1.0, self.sess.run(w_grad)) 86 self.assertAllClose(1.0, self.sess.run(w_grad)) 100 self.assertAllClose(5.0, self.sess.run(y)) 101 self.assertAllClose(3.0, self.sess.run(u_grad)) 102 self.assertAllClose(2.0, self.sess.run(v_grad)) 107 self.assertAllClose(1.0, self.sess.run(w_grad)) [all …]
|
/external/tensorflow/tensorflow/contrib/distributions/python/kernel_tests/ |
D | quantized_distribution_test.py | 68 self.assertAllClose(0., pmf_n1) 70 self.assertAllClose(0., pmf_0) 73 self.assertAllClose(1 / 3, pmf_1) 74 self.assertAllClose(1 / 3, pmf_2) 75 self.assertAllClose(1 / 3, pmf_3) 77 self.assertAllClose(0 / 3, pmf_4) 78 self.assertAllClose(0 / 3, pmf_5) 83 self.assertAllClose(0., cdf_n1) 84 self.assertAllClose(0., cdf_0) 85 self.assertAllClose(1 / 3, cdf_1) [all …]
|
D | geometric_test.py | 69 self.assertAllClose(expected_log_prob, log_prob.eval()) 73 self.assertAllClose(np.exp(expected_log_prob), pmf.eval()) 108 self.assertAllClose(expected_log_prob, log_prob_values) 113 self.assertAllClose(np.exp(expected_log_prob), pmf_values) 127 self.assertAllClose(expected_cdf, cdf.eval()) 135 self.assertAllClose(expected_entropy, geom.entropy().eval()) 143 self.assertAllClose(expected_means, geom.mean().eval()) 151 self.assertAllClose(expected_vars, geom.variance().eval()) 159 self.assertAllClose(geom.stddev().eval(), expected_stddevs) 166 self.assertAllClose([0.] * 3, geom.mode().eval()) [all …]
|
/external/tensorflow/tensorflow/compiler/tests/ |
D | proximal_gradient_descent_test.py | 45 self.assertAllClose([0.0, 0.0], self.evaluate(var0)) 46 self.assertAllClose([0.0, 0.0], self.evaluate(var1)) 52 self.assertAllClose(np.array([-0.9, -1.8]), self.evaluate(var0)) 53 self.assertAllClose(np.array([-0.09, -0.18]), self.evaluate(var1)) 67 self.assertAllClose([1.0, 2.0], self.evaluate(var0)) 68 self.assertAllClose([4.0, 3.0], self.evaluate(var1)) 74 self.assertAllClose(np.array([0.1, 0.2]), self.evaluate(var0)) 75 self.assertAllClose(np.array([3.91, 2.82]), self.evaluate(var1)) 89 self.assertAllClose([1.0, 2.0], self.evaluate(var0)) 90 self.assertAllClose([4.0, 3.0], self.evaluate(var1)) [all …]
|
D | proximal_adagrad_test.py | 48 self.assertAllClose([0.0, 0.0], self.evaluate(var0)) 49 self.assertAllClose([0.0, 0.0], self.evaluate(var1)) 55 self.assertAllClose( 57 self.assertAllClose( 79 self.assertAllClose([1.0, 2.0], self.evaluate(var0)) 80 self.assertAllClose([4.0, 3.0], self.evaluate(var1)) 85 self.assertAllClose(np.array([-1.60261, -2.296985]), self.evaluate(var0)) 86 self.assertAllClose(np.array([3.715679, 2.433051]), self.evaluate(var1)) 103 self.assertAllClose([1.0, 2.0], self.evaluate(var0)) 104 self.assertAllClose([4.0, 3.0], self.evaluate(var1)) [all …]
|
D | lstm_test.py | 97 self.assertAllClose(m, [[0.]] * self._batch_size) 98 self.assertAllClose(c, [[0.]] * self._batch_size) 100 self.assertAllClose(m, [[.25]] * self._batch_size) 101 self.assertAllClose(c, [[.5]] * self._batch_size) 103 self.assertAllClose(m, [[.0]] * self._batch_size) 104 self.assertAllClose(c, [[.0]] * self._batch_size) 106 self.assertAllClose(m, [[.25]] * self._batch_size) 107 self.assertAllClose(c, [[.5]] * self._batch_size) 115 self.assertAllClose(m, self._NextM(self._inputs, 1., m_prev, c_prev)) 116 self.assertAllClose(c, self._NextC(self._inputs, 1., m_prev, c_prev)) [all …]
|
/external/tensorflow/tensorflow/python/keras/preprocessing/ |
D | sequence_test.py | 36 self.assertAllClose(b, [[0, 0, 1], [0, 1, 2], [1, 2, 3]]) 38 self.assertAllClose(b, [[1, 0, 0], [1, 2, 0], [1, 2, 3]]) 43 self.assertAllClose(b, [[0, 1], [1, 2], [2, 3]]) 46 self.assertAllClose(b, [[0, 1], [1, 2], [1, 2]]) 50 self.assertAllClose(b, [[1, 1, 1], [1, 1, 2], [1, 2, 3]]) 57 self.assertAllClose(b, [[[0, 0], [0, 0], [1, 1]], [[0, 0], [2, 1], [2, 2]], 60 self.assertAllClose(b, [[[1, 1], [0, 0], [0, 0]], [[2, 1], [2, 2], [0, 0]], 66 self.assertAllClose(b, [[[0, 0], [1, 1]], [[2, 1], [2, 2]], [[3, 2], [3, 71 self.assertAllClose(b, [[[0, 0], [1, 1]], [[2, 1], [2, 2]], [[3, 1], [3, 76 self.assertAllClose(b, [[[1, 1], [1, 1], [1, 1]], [[1, 1], [2, 1], [2, 2]], [all …]
|
/external/tensorflow/tensorflow/contrib/linear_optimizer/python/kernel_tests/ |
D | sdca_ops_test.py | 263 self.assertAllClose(0.693147, unregularized_loss.eval()) 264 self.assertAllClose(0.693147, loss.eval()) 276 self.assertAllClose(0.411608, unregularized_loss.eval(), atol=0.05) 277 self.assertAllClose(0.525457, loss.eval(), atol=0.01) 280 self.assertAllClose( 311 self.assertAllClose(0.693147, unregularized_loss.eval()) 312 self.assertAllClose(0.693147, loss.eval()) 324 self.assertAllClose(0.411608, unregularized_loss.eval(), atol=0.05) 325 self.assertAllClose(0.525457, loss.eval(), atol=0.01) 328 self.assertAllClose( [all …]
|
/external/tensorflow/tensorflow/python/training/ |
D | learning_rate_decay_test.py | 40 self.assertAllClose(self.evaluate(decayed_lr), expected, 1e-6) 53 self.assertAllClose(self.evaluate(decayed_lr), expected, 1e-6) 57 self.assertAllClose(self.evaluate(decayed_lr), .1, 1e-6) 62 self.assertAllClose(self.evaluate(decayed_lr), expected, 1e-6) 75 self.assertAllClose(self.evaluate(decayed_lr), .1, 1e-6) 77 self.assertAllClose(self.evaluate(decayed_lr), .1, 1e-6) 81 self.assertAllClose(self.evaluate(decayed_lr), expected, 1e-6) 91 self.assertAllClose(self.evaluate(decayed_lr), 1.0, 1e-6) 93 self.assertAllClose(self.evaluate(decayed_lr), 1.0, 1e-6) 95 self.assertAllClose(self.evaluate(decayed_lr), 0.1, 1e-6) [all …]
|
D | proximal_adagrad_test.py | 53 self.assertAllClose([0.0, 0.0], v0_val) 54 self.assertAllClose([0.0, 0.0], v1_val) 61 self.assertAllClose(np.array([-2.60260963, -4.29698515]), v0_val) 62 self.assertAllClose(np.array([-0.28432083, -0.56694895]), v1_val) 93 self.assertAllClose([1.0, 2.0], v0_val) 94 self.assertAllClose([4.0, 3.0], v1_val) 100 self.assertAllClose(np.array([-1.60261, -2.296985]), v0_val) 101 self.assertAllClose(np.array([3.715679, 2.433051]), v1_val) 139 self.assertAllClose([1.0, 2.0], v0_val) 140 self.assertAllClose([4.0, 3.0], v1_val) [all …]
|
D | proximal_gradient_descent_test.py | 55 self.assertAllClose([0.0, 0.0], v0_val) 56 self.assertAllClose([0.0, 0.0], v1_val) 63 self.assertAllClose(np.array([-0.9, -1.8]), v0_val) 64 self.assertAllClose(np.array([-0.09, -0.18]), v1_val) 88 self.assertAllClose([1.0, 2.0], v0_val) 89 self.assertAllClose([4.0, 3.0], v1_val) 96 self.assertAllClose(np.array([0.1, 0.2]), v0_val) 97 self.assertAllClose(np.array([3.91, 2.82]), v1_val) 133 self.assertAllClose([1.0, 2.0], v0_val) 134 self.assertAllClose([4.0, 3.0], v1_val) [all …]
|
/external/tensorflow/tensorflow/python/kernel_tests/boosted_trees/ |
D | prediction_ops_test.py | 61 self.assertAllClose(cached_tree_ids, new_tree_ids) 62 self.assertAllClose(cached_node_ids, new_node_ids) 63 self.assertAllClose([[0], [0]], logits_updates) 128 self.assertAllClose([0, 0], new_tree_ids) 129 self.assertAllClose([2, 1], new_node_ids) 130 self.assertAllClose([[0.1 * 8.79], [0.1 * 1.14]], logits_updates) 201 self.assertAllClose(cached_tree_ids, new_tree_ids) 202 self.assertAllClose(cached_node_ids, new_node_ids) 203 self.assertAllClose([[0], [0]], logits_updates) 311 self.assertAllClose([0, 0], new_tree_ids) [all …]
|
D | stats_ops_test.py | 69 self.assertAllClose([[0.004775, 0.41184], [0.02823, 0.41184]], 74 self.assertAllClose([[[-.416667], [.568966]], [[-.6], [-.75]]], 76 self.assertAllClose([[[-.592593], [-.75]], [[-.076923], [.568966]]], 117 self.assertAllClose([[0., 0.33931375], [0.01879096, 0.33931375]], 122 self.assertAllClose([[[0.], [.485294]], [[-.5], [-.6]]], 124 self.assertAllClose([[[-.424658], [-.6]], [[-.043478], [.485294]]], 168 self.assertAllClose([[[0.0], [0.3965517]], [[-0.4], [-0.5]]], 171 self.assertAllClose([[[-0.3333333], [-0.5]], [[0.0], [0.396552]]], 175 self.assertAllClose([[0.0, 0.191207], [0.01, 0.191207]], 219 self.assertAllClose([[-3., -2.66068625], [-2.98120904, -2.66068625]], [all …]
|
D | quantile_ops_test.py | 104 self.assertAllClose(self._feature_0_boundaries, buckets[0].eval()) 105 self.assertAllClose(self._feature_1_boundaries, buckets[1].eval()) 107 self.assertAllClose(self._feature_0_quantiles, quantiles[0].eval()) 108 self.assertAllClose(self._feature_1_quantiles, quantiles[1].eval()) 138 self.assertAllClose(self._feature_0_boundaries, bucket_0[0].eval()) 139 self.assertAllClose(self._feature_1_boundaries, bucket_1[0].eval()) 141 self.assertAllClose(self._feature_0_quantiles, quantiles[0].eval()) 142 self.assertAllClose(self._feature_1_quantiles, quantiles[1].eval()) 156 self.assertAllClose([], buckets[0].eval()) 157 self.assertAllClose([], buckets[1].eval()) [all …]
|
/external/tensorflow/tensorflow/contrib/boosted_trees/python/kernel_tests/ |
D | stats_accumulator_ops_test.py | 56 self.assertAllClose(result[(1, 2, 0)], [0.2, 0.4]) 57 self.assertAllClose(result[(2, 3, 0)], [0.3, 0.4]) 84 self.assertAllClose(result[(1, 2, 2)], [1.9, -9.8]) 85 self.assertAllClose(result[(2, 3, 0)], [0.3, 0.4]) 86 self.assertAllClose(result[(2, 3, 1)], [0.1, 0.2]) 117 self.assertAllClose(result[(1, 2, 0)], [0.1, 0.2]) 118 self.assertAllClose(result[(2, 3, 0)], [0.3, 0.4]) 156 self.assertAllClose(result_1[(1, 2, 0)], [0.1, 0.2]) 157 self.assertAllClose(result_1[(2, 3, 0)], [0.3, 0.4]) 195 self.assertAllClose(result[(3, 5, 0)], [0.4, 0.6]) [all …]
|
/external/tensorflow/tensorflow/python/kernel_tests/ |
D | clip_ops_test.py | 62 self.assertAllClose(np_ans, tf_ans) 78 self.assertAllClose(np_ans, tf_ans) 95 self.assertAllClose(np_ans, tf_ans) 112 self.assertAllClose(np_ans, tf_ans) 130 self.assertAllClose(np_ans, tf_ans) 151 self.assertAllClose(np_ans, tf_ans) 167 self.assertAllClose(np_ans, tf_ans) 168 self.assertAllClose(np_ans, tf_ans_tensor) 196 self.assertAllClose(np_ans, tf_ans) 208 self.assertAllClose(np_ans, tf_ans) [all …]
|
D | inplace_ops_test.py | 40 self.assertAllClose(x.eval(), y) 43 self.assertAllClose(x.eval(), y) 47 self.assertAllClose(x.eval(), y) 50 self.assertAllClose(x.eval(), y) 57 self.assertAllClose(x.eval(), y) 61 self.assertAllClose(x.eval(), y) 65 self.assertAllClose(x.eval(), y) 68 self.assertAllClose(x.eval(), y) 76 self.assertAllClose(x.eval(), y) 79 self.assertAllClose(x.eval(), y) [all …]
|
/external/tensorflow/tensorflow/python/keras/optimizer_v2/ |
D | learning_rate_schedule_test.py | 53 self.assertAllClose(self.evaluate(decayed_lr(step)), expected, 1e-6) 67 self.assertAllClose(self.evaluate(decayed_lr(step)), expected, 1e-6) 71 self.assertAllClose(self.evaluate(decayed_lr(step)), expected, 1e-6) 76 self.assertAllClose(self.evaluate(decayed_lr(step)), expected, 1e-6) 91 self.assertAllClose(self.evaluate(decayed_lr(step)), .1, 1e-6) 93 self.assertAllClose(self.evaluate(decayed_lr(step)), .1, 1e-6) 97 self.assertAllClose(self.evaluate(decayed_lr(step)), expected, 1e-6) 108 self.assertAllClose(self.evaluate(decayed_lr(x)), 1.0, 1e-6) 110 self.assertAllClose(self.evaluate(decayed_lr(x)), 1.0, 1e-6) 112 self.assertAllClose(self.evaluate(decayed_lr(x)), 0.1, 1e-6) [all …]
|
/external/tensorflow/tensorflow/python/kernel_tests/distributions/ |
D | uniform_test.py | 56 self.assertAllClose(a, self.evaluate(uniform.low)) 57 self.assertAllClose(b, self.evaluate(uniform.high)) 58 self.assertAllClose(b - a, self.evaluate(uniform.range())) 80 self.assertAllClose(expected_pdf, self.evaluate(pdf)) 83 self.assertAllClose(np.log(expected_pdf), self.evaluate(log_pdf)) 106 self.assertAllClose(expected_pdf, self.evaluate(pdf)) 126 self.assertAllClose(_expected_cdf(), self.evaluate(cdf)) 129 self.assertAllClose(np.log(_expected_cdf()), self.evaluate(log_cdf)) 138 self.assertAllClose(expected_entropy, self.evaluate(uniform.entropy())) 163 self.assertAllClose( [all …]
|
/external/tensorflow/tensorflow/contrib/timeseries/python/timeseries/ |
D | math_utils_test.py | 59 self.assertAllClose(result, 70 self.assertAllClose(result, 84 self.assertAllClose(result, 95 self.assertAllClose(expected_result, 98 self.assertAllClose(expected_result, 102 self.assertAllClose(expected_result, 106 self.assertAllClose(expected_result, 118 self.assertAllClose(expected_result, 121 self.assertAllClose(expected_result, 125 self.assertAllClose(expected_result, [all …]
|