{"record":{"id":"0c5ecc10d0c7a1d4","repo":"tensorflow/models","slug":"fatal-exception-in-the-data-production-loop","errorCode":null,"errorMessage":"Fatal exception in the data production loop: {}","messagePattern":"Fatal exception in the data production loop: (.+?)","errorType":"exception","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"official/recommendation/data_pipeline.py","lineNumber":702,"sourceCode":"\n    self._eval_dataset.start_construction()\n    map_args = [i for i in range(self.eval_batches_per_epoch)]\n\n    get_pool = (\n        popen_helper.get_fauxpool\n        if self.deterministic else popen_helper.get_threadpool)\n    with get_pool(6) as pool:\n      pool.map(self._get_eval_batch, map_args)\n    self._eval_dataset.end_construction()\n\n    logging.info(\"Eval construction complete. Time: {:.1f} seconds\".format(\n        timeit.default_timer() - start_time))\n\n  def make_input_fn(self, is_training):\n    # It isn't feasible to provide a foolproof check, so this is designed to\n    # catch most failures rather than provide an exhaustive guard.\n    if self._fatal_exception is not None:\n      raise ValueError(\"Fatal exception in the data production loop: {}\".format(\n          self._fatal_exception))\n\n    return (self._train_dataset.make_input_fn(self.train_batch_size)\n            if is_training else self._eval_dataset.make_input_fn(\n                self.eval_batch_size))\n\n  def increment_request_epoch(self):\n    self._train_dataset.increment_request_epoch()\n\n\nclass DummyConstructor(threading.Thread):\n  \"\"\"Class for running with synthetic data.\"\"\"\n\n  def __init__(self, *args, **kwargs):\n    super(DummyConstructor, self).__init__(*args, **kwargs)\n    self.train_batches_per_epoch = rconst.SYNTHETIC_BATCHES_PER_EPOCH\n    self.eval_batches_per_epoch = rconst.SYNTHETIC_BATCHES_PER_EPOCH\n","sourceCodeStart":684,"sourceCodeEnd":720,"githubUrl":"https://github.com/tensorflow/models/blob/e006f5f0d534913e49c1f1dae87364039fa607e2/official/recommendation/data_pipeline.py#L684-L720","documentation":"Error \"Fatal exception in the data production loop: {}\" thrown in tensorflow/models.","triggerScenarios":"Thrown at official/recommendation/data_pipeline.py:702 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"}