class_docstr: Generate RCNN target tensors for both probabilities and bounding boxes.
  
  Targets for RCNN are based upon the results of the RPN, this can get tricky
  in the sense that RPN results might not be the best and it might not be
  possible to have the ideal amount of targets for all the available ground
  truth boxes.
  
  There are two types of targets, class targets and bounding box targets.
  
  Class targets are used both for background and foreground, while bounding
  box targets are only used for foreground (since it's not possible to create
  a bounding box of "background objects").
  
  A minibatch size determines how many targets are going to be generated and
  how many are going to be ignored. RCNNTarget is responsible for choosing
  which proposals and corresponding targets are included in the minibatch and
  which ones are completely ignored.
docstr: Args:
      num_classes: Number of possible classes.
      config: Configuration object for RCNNTarget.
docstr_tok: ["Args",":","num_classes",":","Number","of","possible","classes",".","config",":","Configuration","object","for","RCNNTarget","."]
code: def __init__(
      self,
      num_classes,
      config,
      seed=None,
      variances=None,
      name="rcnn_proposal",
  ):
      """
      Args:
          num_classes: Number of possible classes.
          config: Configuration object for RCNNTarget.
      """
      super(RCNNTarget, self).__init__(name=name)
      self._num_classes = num_classes
      self._variances = variances
      # Ratio of foreground vs background for the minibatch.
      self._foreground_fraction = config.foreground_fraction
      self._minibatch_size = config.minibatch_size
      # IoU lower threshold with a ground truth box to be considered that
      # specific class.
      self._foreground_threshold = config.foreground_threshold
      # High and low treshold to be considered background.
      self._background_threshold_high = config.background_threshold_high
      self._background_threshold_low = config.background_threshold_low
      self._seed = seed
  
file_path: luminoth/luminoth/models/fasterrcnn/rcnn_target.py
imports: import tensorflow
  import sonnet
  from luminoth.utils.bbox_transform_tf import encode
  from luminoth.utils.bbox_overlap import bbox_overlap_tf
label_desc: Use image node_id 1 to create a new RCNNTarget object from inherited base classes: snt with example: obj = RCNNTarget(num_classes, config, seed, variances, name)