Returns tensors of all keys and values in the table. Args: name: A name for the operation (optional). Returns: A pair of tensors with the first tensor containing all keys and the second tensors containing all values in the table.
(self, name=None)
| 2076 | return self.erase(keys, name) |
| 2077 | |
| 2078 | def export(self, name=None): |
| 2079 | """Returns tensors of all keys and values in the table. |
| 2080 | |
| 2081 | Args: |
| 2082 | name: A name for the operation (optional). |
| 2083 | |
| 2084 | Returns: |
| 2085 | A pair of tensors with the first tensor containing all keys and the |
| 2086 | second tensors containing all values in the table. |
| 2087 | """ |
| 2088 | with ops.name_scope(name, "%s_lookup_table_export_values" % self.name, |
| 2089 | [self.resource_handle]): |
| 2090 | with ops.colocate_with(self.resource_handle): |
| 2091 | exported_keys, exported_values = gen_lookup_ops.lookup_table_export_v2( |
| 2092 | self.resource_handle, self._key_dtype, self._value_dtype) |
| 2093 | |
| 2094 | return exported_keys, exported_values |
| 2095 | |
| 2096 | def _gather_saveables_for_checkpoint(self): |
| 2097 | """For object-based checkpointing.""" |