Skip to content

Commit

Permalink
fixes loss_classification_multi
Browse files Browse the repository at this point in the history
  • Loading branch information
wyli committed Dec 17, 2019
1 parent cca0cd3 commit 9ee918c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion niftynet/layer/loss_classification_multi.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ def loss_confusion_matrix(ground_truth, pred_multi, num_classes=2, nrater=6):
nn_pred[:, j, :])
confusion_gt = tf.matmul(tf.transpose(dense_one_hot[:, i, :]),
dense_one_hot[:, j, :])
error = tf.divide(np.abs(confusion_gt - confusion_pred), tf.cast(
error = tf.divide(tf.abs(confusion_gt - confusion_pred), tf.cast(
tf.shape(ground_truth)[0], tf.float32))
error_fin += error
error_fin = tf.Print(tf.cast(error,tf.float32), [tf.reduce_sum(
Expand Down

0 comments on commit 9ee918c

Please sign in to comment.