i want to watch not only continuous error, which should be optimized during training, but also another not differentiable metrics(like top1 or top5 classification error) during training. Is it possible?
Example:
outputs = MyModel(inputs)
continuous_loss = some_loss(outputs, labels)
# it could return tensor with dimension different than continuous loss,
# which return only one scalar for batch
another_loss = some_another_loss(outputs, labels, ...)
optimizer = tf.RMSPropOptimizer(lr, momentum)
train_op = slim.learning.create_train_op(continuous_loss, optimizer, ...)
# this call is blocking and i can't run another op with session.run
slim.learning.train(train_op, logdir, ...)
What i needed it's simply redefine train_step_fn and pass to slim.learning.train array of [train_op, another_loss]