Home
last modified time | relevance | path

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

12345678910>>...50

/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/python/keras/
Dlosses_test.py33 from tensorflow.python.keras import losses
40 losses.mean_squared_error, losses.mean_absolute_error,
41 losses.mean_absolute_percentage_error,
42 losses.mean_squared_logarithmic_error, losses.squared_hinge, losses.hinge,
43 losses.categorical_crossentropy, losses.binary_crossentropy,
44 losses.kl_divergence, losses.poisson,
45 losses.cosine_similarity, losses.log_cosh, losses.categorical_hinge
73 objective_output = losses.sparse_categorical_crossentropy(y_a, y_b)
78 objective_output = losses.sparse_categorical_crossentropy(y_a, y_b)
86 output_from_logit = losses.categorical_crossentropy(
[all …]
/external/tensorflow/tensorflow/python/ops/losses/
Dlosses_impl.py31 from tensorflow.python.ops.losses import util
76 def _safe_mean(losses, num_present): argument
87 total_loss = math_ops.reduce_sum(losses)
91 def _num_present(losses, weights, per_batch=False): argument
116 return _num_elements(losses)
117 with ops.name_scope(None, "num_present", (losses, weights)) as scope:
123 present = weights_broadcast_ops.broadcast_weights(present, losses)
133 def _num_elements(losses): argument
135 with ops.name_scope(None, "num_elements", values=[losses]) as scope:
136 return math_ops.cast(array_ops.size(losses, name=scope), dtype=losses.dtype)
[all …]
Dutil.py123 def scale_losses_by_sample_weight(losses, sample_weight): argument
138 losses = math_ops.cast(losses, dtypes.float32)
142 losses, _, sample_weight = squeeze_or_expand_dimensions(
143 losses, None, sample_weight)
144 return math_ops.multiply(losses, sample_weight)
230 losses = get_regularization_losses(scope)
231 if losses:
232 return math_ops.add_n(losses, name=name)
263 losses = get_losses(scope=scope)
265 losses += get_regularization_losses(scope=scope)
[all …]
/external/tensorflow/tensorflow/python/keras/utils/
Dlosses_utils.py235 def _safe_mean(losses, num_present): argument
246 total_loss = math_ops.reduce_sum(losses)
250 def _num_elements(losses): argument
253 return math_ops.cast(array_ops.size(losses, name=scope), dtype=losses.dtype)
268 def compute_weighted_loss(losses, argument
302 if not isinstance(losses,
304 losses = ops.convert_to_tensor_v2_with_dispatch(losses)
305 input_dtype = losses.dtype
312 losses = math_ops.cast(losses, 'float32')
315losses, _, sample_weight = squeeze_or_expand_dimensions( # pylint: disable=unbalanced-tuple-unpac…
[all …]
/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 …]
Dtensorflow.keras.losses.-mean-absolute-percentage-error.pbtxt1 path: "tensorflow.keras.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.keras.losses.-binary-crossentropy.pbtxt1 path: "tensorflow.keras.losses.BinaryCrossentropy"
3 is_instance: "<class \'tensorflow.python.keras.losses.BinaryCrossentropy\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.keras.losses.-hinge.pbtxt1 path: "tensorflow.keras.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\'>"
/external/tensorflow/tensorflow/python/keras/saving/
Dlosses_serialization_test.py30 from tensorflow.python.keras import losses
45 class MyMeanAbsoluteError(losses.LossFunctionWrapper):
71 dict(testcase_name='built_in_fn', value=losses.mae),
72 dict(testcase_name='built_in_class', value=losses.MeanAbsoluteError()),
76 dict(testcase_name='list_of_built_in_fns', value=[losses.mae, losses.mae]),
79 value=[losses.MeanAbsoluteError(),
80 losses.MeanAbsoluteError()]),
95 'output': losses.mae,
96 'output_1': losses.mae,
101 'output': losses.MeanAbsoluteError(),
[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/python/tpu/
Dtpu_optimizer.py24 from tensorflow.python.ops.losses import losses
38 reduction=losses.Reduction.MEAN,
55 if reduction not in (losses.Reduction.SUM, losses.Reduction.MEAN):
154 if num_shards > 1 and self._reduction == losses.Reduction.MEAN:
/external/tensorflow/tensorflow/tools/api/golden/v2/
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.-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.-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.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.-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.-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.-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.-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.-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.-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.keras.losses.-hinge.pbtxt1 path: "tensorflow.keras.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.-huber.pbtxt1 path: "tensorflow.losses.Huber"
3 is_instance: "<class \'tensorflow.python.keras.losses.Huber\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"
Dtensorflow.losses.-binary-crossentropy.pbtxt1 path: "tensorflow.losses.BinaryCrossentropy"
3 is_instance: "<class \'tensorflow.python.keras.losses.BinaryCrossentropy\'>"
4 is_instance: "<class \'tensorflow.python.keras.losses.LossFunctionWrapper\'>"
5 is_instance: "<class \'tensorflow.python.keras.losses.Loss\'>"

12345678910>>...50