| 354 | } |
| 355 | |
| 356 | Status CorruptFileError(const Status& in_status, const string& filename, |
| 357 | const string& detail) { |
| 358 | if (in_status.ok()) { |
| 359 | return errors::Internal("Unable to read file (", filename, |
| 360 | "). Perhaps the file is corrupt or was produced by " |
| 361 | "a newer version of TensorFlow with format changes " |
| 362 | "(", |
| 363 | detail, ")"); |
| 364 | } |
| 365 | return Status( |
| 366 | in_status.code(), |
| 367 | strings::StrCat("Unable to read file (", filename, |
| 368 | "). Perhaps the file is corrupt or was produced by a " |
| 369 | "newer version of TensorFlow with format changes (", |
| 370 | detail, "): ", in_status.error_message())); |
| 371 | } |
| 372 | |
| 373 | table::Options TableBuilderOptions() { |
| 374 | table::Options o; |