Commit 17522ce1 authored by Marius Kriegerowski's avatar Marius Kriegerowski

test loss alternative

parent 30e3963b
......@@ -120,14 +120,15 @@ class Model(Object):
# vector length
loss = tf.sqrt(tf.reduce_sum((predictions - labels) ** 2))/ self.batch_size
# loss = tf.losses.mean_squared_error(
# labels,
# predictions,
# weights=1.0,
# scope=None,
# loss_collection=tf.GraphKeys.LOSSES,
# reduction=tf.losses.Reduction.SUM_BY_NONZERO_WEIGHTS
# )
lossalternative= tf.losses.mean_squared_error(
labels,
predictions,
weights=1.0,
scope=None,
loss_collection=tf.GraphKeys.LOSSES,
reduction=tf.losses.Reduction.SUM_BY_NONZERO_WEIGHTS
)
tf.summary.scalar('lossalternative', lossalternative)
accuracy = tf.metrics.accuracy(
labels=labels,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment