tensorflow/models · error · ValueError

segmentation_groundtruth_padded_size ([height, width]) needs

Error message

segmentation_groundtruth_padded_size ([height, width]) needs to bespecified when segmentation_resize_eval_groundtruth is False.

What it means

Error "segmentation_groundtruth_padded_size ([height, width]) needs to bespecified when segmentation_resize_eval_groundtruth is False." thrown in tensorflow/models.

Source

Thrown at official/projects/panoptic/dataloaders/panoptic_maskrcnn_input.py:198

        aug_scale_max=aug_scale_max,
        aug_type=aug_type,
        skip_crowd_during_training=skip_crowd_during_training,
        max_num_instances=max_num_instances,
        include_mask=True,
        outer_boxes_scale=outer_boxes_scale,
        mask_crop_size=mask_crop_size,
        dtype=dtype,
    )

    self.aug_rand_hflip = aug_rand_hflip
    self.aug_rand_vflip = aug_rand_vflip
    self._segmentation_resize_eval_groundtruth = (
        segmentation_resize_eval_groundtruth
    )
    if (not segmentation_resize_eval_groundtruth) and (
        segmentation_groundtruth_padded_size is None
    ):
      raise ValueError(
          'segmentation_groundtruth_padded_size ([height, width]) needs to be'
          'specified when segmentation_resize_eval_groundtruth is False.'
      )
    self._segmentation_groundtruth_padded_size = (
        segmentation_groundtruth_padded_size
    )
    self._segmentation_ignore_label = segmentation_ignore_label
    self._panoptic_ignore_label = panoptic_ignore_label
    self._include_panoptic_masks = include_panoptic_masks

  def _parse_train_data(self, data):
    """Parses data for training.

    Args:
      data: the decoded tensor dictionary from TfExampleDecoder.

    Returns:
      image: image tensor that is preproessed to have normalized value and

View on GitHub (pinned to e006f5f0d5)

When it happens

Trigger: Thrown at official/projects/panoptic/dataloaders/panoptic_maskrcnn_input.py:198 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of tensorflow/models@e006f5f0d5 (2026-08-24). Data as JSON: /api/errors/51c4ec41138a53a3. Report an issue: GitHub.