{"record":{"id":"ba14cd032481c092","repo":"tensorflow/models","slug":"groundtruth-padded-size-height-width-needs-to-ba14cd","errorCode":null,"errorMessage":"groundtruth_padded_size ([height, width]) needs to bespecified when resize_eval_groundtruth is False.","messagePattern":"groundtruth_padded_size \\(\\[height, width\\]\\) needs to bespecified when resize_eval_groundtruth is False\\.","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"official/vision/dataloaders/segmentation_input.py","lineNumber":117,"sourceCode":"      aug_scale_min: `float`, the minimum scale applied to `output_size` for\n        data augmentation during training.\n      aug_scale_max: `float`, the maximum scale applied to `output_size` for\n        data augmentation during training.\n      dtype: `str`, data type. One of {`bfloat16`, `float32`, `float16`}.\n      image_feature: the config for the image input (usually RGB). Defaults to\n        the config for a 3-channel image with key = `image/encoded` and ImageNet\n        dataset mean/stddev.\n      additional_dense_features: `list` of DenseFeatureConfig for additional\n        dense features.\n      centered_crop: If `centered_crop` is set to True, then resized crop (if\n        smaller than padded size) is place in the center of the image. Default\n        behaviour is to place it at left top corner.\n    \"\"\"\n    self._output_size = output_size\n    self._crop_size = crop_size\n    self._resize_eval_groundtruth = resize_eval_groundtruth\n    if (not resize_eval_groundtruth) and (groundtruth_padded_size is None):\n      raise ValueError(\n          'groundtruth_padded_size ([height, width]) needs to be'\n          'specified when resize_eval_groundtruth is False.'\n      )\n    self._gt_is_matting_map = gt_is_matting_map\n    self._groundtruth_padded_size = groundtruth_padded_size\n    self._ignore_label = ignore_label\n    self._preserve_aspect_ratio = preserve_aspect_ratio\n\n    # Data augmentation.\n    self._aug_rand_hflip = aug_rand_hflip\n    self._aug_scale_min = aug_scale_min\n    self._aug_scale_max = aug_scale_max\n\n    # dtype.\n    self._dtype = dtype\n\n    self._image_feature = image_feature\n    self._additional_dense_features = additional_dense_features","sourceCodeStart":99,"sourceCodeEnd":135,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/vision/dataloaders/segmentation_input.py#L99-L135","documentation":"Error \"groundtruth_padded_size ([height, width]) needs to bespecified when resize_eval_groundtruth is False.\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/vision/dataloaders/segmentation_input.py:117 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"e006f5f0d534913e49c1f1dae87364039fa607e2","analyzedAt":"2026-08-24T14:09:15.576Z","schemaVersion":2},"datasetVersion":"2026-08-24T17:17:21.512Z"}