class_docstr: Evaluate detection result of a single image.
class_docstr_tok: ["Evaluate","detection","result","of","a","single","image","."]
docstr: Removes entries with invalid boxes.
  
  A box is invalid if either its xmax is smaller than its xmin, or its ymax
  is smaller than its ymin.
  
  Args:
    detected_boxes: A float numpy array of size [num_boxes, 4] containing box
      coordinates in [ymin, xmin, ymax, xmax] format.
    detected_scores: A float numpy array of size [num_boxes].
    detected_class_labels: A int32 numpy array of size [num_boxes].
    detected_masks: A uint8 numpy array of size [num_boxes, height, width].
  
  Returns:
    valid_detected_boxes: A float numpy array of size [num_valid_boxes, 4]
      containing box coordinates in [ymin, xmin, ymax, xmax] format.
    valid_detected_scores: A float numpy array of size [num_valid_boxes].
    valid_detected_class_labels: A int32 numpy array of size
      [num_valid_boxes].
    valid_detected_masks: A uint8 numpy array of size
      [num_valid_boxes, height, width].
docstr_tok: ["Removes","entries","with","invalid","boxes",".","A","box","is","invalid","if","either","its","xmax","is","smaller","than","its","xmin",",","or","its","ymax","is","smaller","than","its","ymin",".","Args",":","detected_boxes",":","A","float","numpy","array","of","size","[","num_boxes",",","4","]","containing","box","coordinates","in","[","ymin",",","xmin",",","ymax",",","xmax","]","format",".","detected_scores",":","A","float","numpy","array","of","size","[","num_boxes","]",".","detected_class_labels",":","A","int32","numpy","array","of","size","[","num_boxes","]",".","detected_masks",":","A","uint8","numpy","array","of","size","[","num_boxes",",","height",",","width","]",".","Returns",":","valid_detected_boxes",":","A","float","numpy","array","of","size","[","num_valid_boxes",",","4","]","containing","box","coordinates","in","[","ymin",",","xmin",",","ymax",",","xmax","]","format",".","valid_detected_scores",":","A","float","numpy","array","of","size","[","num_valid_boxes","]",".","valid_detected_class_labels",":","A","int32","numpy","array","of","size","[","num_valid_boxes","]",".","valid_detected_masks",":","A","uint8","numpy","array","of","size","[","num_valid_boxes",",","height",",","width","]","."]
code: def _remove_invalid_boxes(
      self,
      detected_boxes,
      detected_scores,
      detected_class_labels,
      detected_masks=None,
  ):
      """Removes entries with invalid boxes.
  
      A box is invalid if either its xmax is smaller than its xmin, or its ymax
      is smaller than its ymin.
  
      Args:
        detected_boxes: A float numpy array of size [num_boxes, 4] containing box
          coordinates in [ymin, xmin, ymax, xmax] format.
        detected_scores: A float numpy array of size [num_boxes].
        detected_class_labels: A int32 numpy array of size [num_boxes].
        detected_masks: A uint8 numpy array of size [num_boxes, height, width].
  
      Returns:
        valid_detected_boxes: A float numpy array of size [num_valid_boxes, 4]
          containing box coordinates in [ymin, xmin, ymax, xmax] format.
        valid_detected_scores: A float numpy array of size [num_valid_boxes].
        valid_detected_class_labels: A int32 numpy array of size
          [num_valid_boxes].
        valid_detected_masks: A uint8 numpy array of size
          [num_valid_boxes, height, width].
      """
      valid_indices = np.logical_and(
          detected_boxes[:, 0] < detected_boxes[:, 2],
          detected_boxes[:, 1] < detected_boxes[:, 3],
      )
      detected_boxes = detected_boxes[valid_indices]
      detected_scores = detected_scores[valid_indices]
      detected_class_labels = detected_class_labels[valid_indices]
      if detected_masks is not None:
          detected_masks = detected_masks[valid_indices]
      return [
          detected_boxes,
          detected_scores,
          detected_class_labels,
          detected_masks,
      ]
  
file_path: SlowFast/ava_evaluation/per_image_evaluation.py
imports: from __future__ import absolute_import, division, print_function, unicode_literals
  import numpy
  from .None import np_box_list, np_box_list_ops, np_box_mask_list, np_box_mask_list_ops
label_desc: Use image node_id 7 for calling the PerImageEvaluation obj's underlying member method code with example usage: obj._remove_invalid_boxes(detected_boxes, detected_scores, detected_class_labels, detected_masks) and returns: list