{"record":{"id":"1189dffd468a357e","repo":"tensorflow/models","slug":"invalid-dtype-s-1189df","errorCode":null,"errorMessage":"Invalid dtype: %s","messagePattern":"Invalid dtype: (.+?)","errorType":"exception","errorClass":"AssertionError","httpStatus":null,"severity":"error","filePath":"official/nlp/modeling/ops/decoding_module.py","lineNumber":307,"sourceCode":"                      state: Dict[str, Any]) -> tf.Tensor:\n    \"\"\"Calculate the finished flags.\"\"\"\n    pass\n\n  def inf(self):\n    \"\"\"Returns a value close to infinity, but is still finite in `dtype`.\n\n    This is useful to get a very large value that is still zero when multiplied\n    by zero. The floating-point \"Inf\" value is NaN when multiplied by zero.\n\n    Returns:\n      A very large value.\n    \"\"\"\n    if self.dtype == dtypes.float32 or self.dtype == dtypes.bfloat16:\n      return 1e7\n    elif self.dtype == dtypes.float16:\n      return dtypes.float16.max\n    else:\n      raise AssertionError(\"Invalid dtype: %s\" % self.dtype)\n","sourceCodeStart":289,"sourceCodeEnd":308,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/nlp/modeling/ops/decoding_module.py#L289-L308","documentation":"Error \"Invalid dtype: %s\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/nlp/modeling/ops/decoding_module.py:307 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"}