{"record":{"id":"9a6003d0e4812090","repo":"tensorflow/models","slug":"invalid-augmentation-name-9a6003","errorCode":null,"errorMessage":"Invalid augmentation_name: {}","messagePattern":"Invalid augmentation_name: (.+?)","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"official/vision/ops/augment.py","lineNumber":1985,"sourceCode":"    self.augmentation_name = augmentation_name\n    self.cutout_const = float(cutout_const)\n    self.translate_const = float(translate_const)\n    self.available_policies = {\n        'detection_v0': self.detection_policy_v0(),\n        'v0': self.policy_v0(),\n        'test': self.policy_test(),\n        'simple': self.policy_simple(),\n        'reduced_cifar10': self.policy_reduced_cifar10(),\n        'svhn': self.policy_svhn(),\n        'reduced_imagenet': self.policy_reduced_imagenet(),\n        'panoptic_deeplab_policy': self.panoptic_deeplab_policy(),\n        'vit': self.vit(),\n        'deit3_three_augment': self.deit3_three_augment(),\n    }\n\n    if not policies:\n      if augmentation_name not in self.available_policies:\n        raise ValueError(\n            'Invalid augmentation_name: {}'.format(augmentation_name))\n\n      self.policies = self.available_policies[augmentation_name]\n\n    else:\n      self._check_policy_shape(policies)\n      self.policies = policies\n\n  def _check_policy_shape(self, policies):\n    \"\"\"Checks dimension and shape of the custom policy.\n\n    Args:\n      policies: List of list of tuples in the form `(func, prob, level)`. Must\n        have shape of `(:, :, 3)`.\n\n    Raises:\n      ValueError if the shape of `policies` is unexpected.\n    \"\"\"","sourceCodeStart":1967,"sourceCodeEnd":2003,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/vision/ops/augment.py#L1967-L2003","documentation":"Error \"Invalid augmentation_name: {}\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/vision/ops/augment.py:1985 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use one of the supported augmentation names listed in the augmentation registry.","Check the augmentation_name in the config for typos."],"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"}