Home
last modified time | relevance | path

Searched refs:losses (Results 1 – 25 of 892) sorted by relevance

12345678910>>...36

/external/tensorflow/tensorflow/contrib/keras/api/keras/losses/
D__init__.py22 from tensorflow.python.keras.losses import binary_crossentropy
23 from tensorflow.python.keras.losses import categorical_crossentropy
24 from tensorflow.python.keras.losses import categorical_hinge
25 from tensorflow.python.keras.losses import cosine_similarity
26 from tensorflow.python.keras.losses import hinge
27 from tensorflow.python.keras.losses import kullback_leibler_divergence
28 from tensorflow.python.keras.losses import logcosh
29 from tensorflow.python.keras.losses import mean_absolute_error
30 from tensorflow.python.keras.losses import mean_absolute_percentage_error
31 from tensorflow.python.keras.losses import mean_squared_error
[all …]
/external/tensorflow/tensorflow/python/kernel_tests/
Dlosses_test.py35 from tensorflow.python.ops.losses import losses
36 from tensorflow.python.ops.losses import util
52 losses.absolute_difference(
56 loss = losses.absolute_difference(self._predictions, self._predictions)
61 loss = losses.absolute_difference(self._labels, self._predictions)
67 loss = losses.absolute_difference(self._labels, self._predictions, weights)
73 loss = losses.absolute_difference(self._labels, self._predictions,
80 loss = losses.absolute_difference(self._labels, self._predictions, weights)
86 loss = losses.absolute_difference(self._labels, self._predictions, weights)
92 loss = losses.absolute_difference(self._labels, self._predictions, weights)
[all …]
/external/tensorflow/tensorflow/contrib/losses/python/losses/
Dloss_ops.py44 def _scale_losses(losses, weights): argument
63 axis = list(range(start_index, losses.get_shape().ndims))
64 reduced_losses = math_ops.reduce_sum(losses, axis=axis)
69 def _safe_mean(losses, num_present): argument
80 total_loss = math_ops.reduce_sum(losses)
85 def compute_weighted_loss(losses, weights=1.0, scope=None): argument
101 with ops.name_scope(scope, "weighted_loss", [losses, weights]):
102 losses = ops.convert_to_tensor(losses)
103 input_dtype = losses.dtype
104 losses = math_ops.cast(losses, dtypes.float32)
[all …]
/external/tensorflow/tensorflow/python/keras/utils/
Dlosses_utils.py150 def _safe_mean(losses, num_present): argument
161 total_loss = math_ops.reduce_sum(losses)
165 def _num_elements(losses): argument
167 with ops.name_scope(None, 'num_elements', values=[losses]) as scope:
168 return math_ops.cast(array_ops.size(losses, name=scope), dtype=losses.dtype)
185 def compute_weighted_loss(losses, argument
209 with ops.name_scope(name, 'weighted_loss', (losses, sample_weight)):
211 losses, _, sample_weight = squeeze_or_expand_dimensions(
212 losses, None, sample_weight)
213 losses = ops.convert_to_tensor(losses)
[all …]
/external/tensorflow/tensorflow/python/keras/
Dlosses_test.py38 ALL_LOSSES = [keras.losses.mean_squared_error,
39 keras.losses.mean_absolute_error,
40 keras.losses.mean_absolute_percentage_error,
41 keras.losses.mean_squared_logarithmic_error,
42 keras.losses.squared_hinge,
43 keras.losses.hinge,
44 keras.losses.categorical_crossentropy,
45 keras.losses.binary_crossentropy,
46 keras.losses.kullback_leibler_divergence,
47 keras.losses.poisson,
[all …]
/external/tensorflow/tensorflow/python/ops/losses/
Dlosses_impl.py32 from tensorflow.python.ops.losses import util
81 def _safe_mean(losses, num_present): argument
92 total_loss = math_ops.reduce_sum(losses)
96 def _num_present(losses, weights, per_batch=False): argument
121 return _num_elements(losses)
122 with ops.name_scope(None, "num_present", (losses, weights)) as scope:
128 present = weights_broadcast_ops.broadcast_weights(present, losses)
138 def _num_elements(losses): argument
140 with ops.name_scope(None, "num_elements", values=[losses]) as scope:
141 return math_ops.cast(array_ops.size(losses, name=scope), dtype=losses.dtype)
[all …]
Dutil.py81 losses = get_regularization_losses(scope)
82 if losses:
83 return math_ops.add_n(losses, name=name)
109 losses = get_losses()
111 losses += get_regularization_losses()
112 return math_ops.add_n(losses, name=name)
/external/tensorflow/tensorflow/tools/api/golden/v1/
Dtensorflow.losses.pbtxt1 path: "tensorflow.losses"
9 …eduction\'], varargs=None, keywords=None, defaults=[\'1.0\', \'None\', \'losses\', \'weighted_sum_…
13 …argspec: "args=[\'loss\', \'loss_collection\'], varargs=None, keywords=None, defaults=[\'losses\']…
17 …args=[\'losses\', \'weights\', \'scope\', \'loss_collection\', \'reduction\'], varargs=None, keywo…
21 …], varargs=None, keywords=None, defaults=[\'None\', \'1.0\', \'None\', \'losses\', \'weighted_sum_…
25 …s=[\'scope\', \'loss_collection\'], varargs=None, keywords=None, defaults=[\'None\', \'losses\'], "
41 …eduction\'], varargs=None, keywords=None, defaults=[\'1.0\', \'None\', \'losses\', \'weighted_sum_…
45 …'], varargs=None, keywords=None, defaults=[\'1.0\', \'1.0\', \'None\', \'losses\', \'weighted_sum_…
49 …, varargs=None, keywords=None, defaults=[\'1.0\', \'1e-07\', \'None\', \'losses\', \'weighted_sum_…
53 …e\', \'loss_collection\'], varargs=None, keywords=None, defaults=[\'1.0\', \'None\', \'losses\'], "
[all …]
/external/tensorflow/tensorflow/contrib/kernel_methods/python/
Dlosses_test.py23 from tensorflow.contrib.kernel_methods.python import losses
39 _ = losses.sparse_multiclass_hinge_loss(labels, logits)
47 _ = losses.sparse_multiclass_hinge_loss(labels, logits)
56 _ = losses.sparse_multiclass_hinge_loss(labels, logits, weights)
64 _ = losses.sparse_multiclass_hinge_loss(labels, logits)
72 _ = losses.sparse_multiclass_hinge_loss(labels, logits, weights=None)
81 _ = losses.sparse_multiclass_hinge_loss(labels, logits, weights)
90 _ = losses.sparse_multiclass_hinge_loss(labels, logits, weights)
98 loss = losses.sparse_multiclass_hinge_loss(labels, logits)
108 loss = losses.sparse_multiclass_hinge_loss(labels, logits)
[all …]
/external/tensorflow/tensorflow/contrib/gan/python/losses/python/
Dlosses_impl.py50 from tensorflow.python.ops.losses import losses
51 from tensorflow.python.ops.losses import util
83 reduction=losses.Reduction.SUM_BY_NONZERO_WEIGHTS,
109 loss = losses.compute_weighted_loss(
125 reduction=losses.Reduction.SUM_BY_NONZERO_WEIGHTS,
157 loss_on_generated = losses.compute_weighted_loss(
160 loss_on_real = losses.compute_weighted_loss(
185 reduction=losses.Reduction.SUM_BY_NONZERO_WEIGHTS,
228 loss_on_generated = losses.softmax_cross_entropy(
232 loss_on_real = losses.softmax_cross_entropy(
[all …]
/external/tensorflow/tensorflow/python/ops/
Dnn_xent_test.py54 losses = np.array(self._SigmoidCrossEntropyWithLogits(x, y)).reshape(*sizes)
55 return logits, targets, losses
69 logits, targets, losses = self._Inputs(dtype=dtype)
72 np_loss = np.array(losses).astype(np.float32)
80 logits, targets, losses = self._Inputs(dtype=dtype, sizes=[2, 2, 2])
83 np_loss = np.array(losses).astype(np.float32)
133 losses = np.array(self._WeightedCrossEntropy(x, y, q)).reshape(*sizes)
134 return logits, targets, q, losses
147 logits, targets, pos_weight, losses = self._Inputs(dtype=dtypes.float32)
150 np_loss = np.array(losses).astype(np.float32)
[all …]
/external/tensorflow/tensorflow/contrib/losses/
DREADME.md1 # TensorFlow contrib losses.
5 This module is deprecated. Instructions for updating: Use tf.losses instead.
7 ## losses section in TensorFlow contrib losses.
9 Note: By default all the losses are collected into the GraphKeys.LOSSES collection.
22 the batch. The result of each loss is a scalar average of all sample losses with
26 probability distribution (i.e., `[0.0, 1.0]`). `target` for losses taking
/external/tensorflow/tensorflow/python/tpu/
Dtpu_optimizer.py24 from tensorflow.python.ops.losses import losses
36 reduction=losses.Reduction.MEAN,
53 if reduction not in (losses.Reduction.SUM, losses.Reduction.MEAN):
133 if num_shards > 1 and self._reduction == losses.Reduction.MEAN:
/external/tensorflow/tensorflow/contrib/training/python/training/
Dtraining_test.py35 from tensorflow.python.ops.losses import losses
99 loss = losses.log_loss(tf_labels, tf_predictions)
116 loss = losses.log_loss(tf_labels, tf_predictions)
150 loss = losses.log_loss(tf_labels, tf_predictions)
183 loss = losses.log_loss(tf_labels, tf_predictions)
206 loss = losses.log_loss(tf_labels, tf_predictions)
243 losses.log_loss(tf_labels, tf_predictions)
244 total_loss = losses.get_total_loss()
279 losses.log_loss(tf_labels, tf_predictions)
280 total_loss = losses.get_total_loss()
[all …]
/external/tensorflow/tensorflow/tools/api/golden/v2/
Dtensorflow.losses.-k-l-divergence.pbtxt1 path: "tensorflow.losses.KLDivergence"
3 is_instance: "<class \'tensorflow.python.keras.losses.KLDivergence\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-hinge.pbtxt1 path: "tensorflow.losses.Hinge"
3 is_instance: "<class \'tensorflow.python.keras.losses.Hinge\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-mean-squared-error.pbtxt1 path: "tensorflow.losses.MeanSquaredError"
3 is_instance: "<class \'tensorflow.python.keras.losses.MeanSquaredError\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-mean-absolute-error.pbtxt1 path: "tensorflow.losses.MeanAbsoluteError"
3 is_instance: "<class \'tensorflow.python.keras.losses.MeanAbsoluteError\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-poisson.pbtxt1 path: "tensorflow.losses.Poisson"
3 is_instance: "<class \'tensorflow.python.keras.losses.Poisson\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-mean-absolute-percentage-error.pbtxt1 path: "tensorflow.losses.MeanAbsolutePercentageError"
3 is_instance: "<class \'tensorflow.python.keras.losses.MeanAbsolutePercentageError\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-categorical-hinge.pbtxt1 path: "tensorflow.losses.CategoricalHinge"
3 is_instance: "<class \'tensorflow.python.keras.losses.CategoricalHinge\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-squared-hinge.pbtxt1 path: "tensorflow.losses.SquaredHinge"
3 is_instance: "<class \'tensorflow.python.keras.losses.SquaredHinge\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-mean-squared-logarithmic-error.pbtxt1 path: "tensorflow.losses.MeanSquaredLogarithmicError"
3 is_instance: "<class \'tensorflow.python.keras.losses.MeanSquaredLogarithmicError\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-log-cosh.pbtxt1 path: "tensorflow.losses.LogCosh"
3 is_instance: "<class \'tensorflow.python.keras.losses.LogCosh\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.keras.losses.-categorical-crossentropy.pbtxt1 path: "tensorflow.keras.losses.CategoricalCrossentropy"
3 is_instance: "<class \'tensorflow.python.keras.losses.CategoricalCrossentropy\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"

12345678910>>...36