code: def flatten_binary_scores(scores, labels, ignore=None):
      """
      Flattens predictions in the batch (binary case)
      Remove labels equal to 'ignore'
      """
      scores = scores.view(-1)
      labels = labels.view(-1)
      if ignore is None:
          return scores, labels
      valid = labels != ignore
      vscores = scores[valid]
      vlabels = labels[valid]
      return vscores, vlabels
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import numpy
  import torch
  import torch.nn.functional
  from torch import nn
  from torch.autograd import Variable
label_desc: Use image node_id 6 for calling a global function with example usage: flatten_binary_scores(scores, labels, ignore) and returns: vscores,  vlabels, scores,  labels