`DebugDumpDir` constructor. Args: dump_root: (`str`) path to the dump root directory. partition_graphs: A repeated field of GraphDefs representing the partition graphs executed by the TensorFlow runtime. validate: (`bool`) whether the dump files are to be validated a
(self, dump_root, partition_graphs=None, validate=True)
| 467 | """ |
| 468 | |
| 469 | def __init__(self, dump_root, partition_graphs=None, validate=True): |
| 470 | """`DebugDumpDir` constructor. |
| 471 | |
| 472 | Args: |
| 473 | dump_root: (`str`) path to the dump root directory. |
| 474 | partition_graphs: A repeated field of GraphDefs representing the |
| 475 | partition graphs executed by the TensorFlow runtime. |
| 476 | validate: (`bool`) whether the dump files are to be validated against the |
| 477 | partition graphs. |
| 478 | |
| 479 | Raises: |
| 480 | IOError: If dump_root does not exist as a directory. |
| 481 | ValueError: If more than one core metadata file is found under the dump |
| 482 | root directory. |
| 483 | """ |
| 484 | |
| 485 | if not gfile.IsDirectory(dump_root): |
| 486 | raise IOError("Dump root directory %s does not exist" % dump_root) |
| 487 | |
| 488 | self._core_metadata = [] |
| 489 | |
| 490 | # Find the list of devices. |
| 491 | self._dump_root = dump_root |
| 492 | |
| 493 | self._load_core_metadata() |
| 494 | self._load_fetches_info() |
| 495 | self._load_feeds_info() |
| 496 | self._load_all_device_dumps(partition_graphs, validate) |
| 497 | |
| 498 | self._python_graph = None |
| 499 | |
| 500 | def _load_all_device_dumps(self, partition_graphs, validate): |
| 501 | """Load the dump data for all devices.""" |
nothing calls this directly
no test coverage detected