Returns the data files as a dictionary of filename to byte data. Returns: Dict[str, bytes]: Dictionary mapping data filenames (e.g., .ptd files) to their serialized byte content. Returns empty dict if no data files are available.
(self)
| 639 | @property |
| 640 | @experimental("This API is experimental and subject to change without notice.") |
| 641 | def data_files(self) -> Dict[str, bytes]: |
| 642 | """Returns the data files as a dictionary of filename to byte data. |
| 643 | |
| 644 | Returns: |
| 645 | Dict[str, bytes]: Dictionary mapping data filenames (e.g., .ptd files) to |
| 646 | their serialized byte content. |
| 647 | Returns empty dict if no data files are available. |
| 648 | """ |
| 649 | if self._pte_data is None: |
| 650 | self._get_pte_data() # This populates _tensor_data |
| 651 | |
| 652 | if self._tensor_data is None: |
| 653 | return {} |
| 654 | |
| 655 | return {filename: bytes(cord) for filename, cord in self._tensor_data.items()} |
| 656 | |
| 657 | @property |
| 658 | def program(self) -> Program: |
nothing calls this directly
no test coverage detected