Keeping the init() method on InitializableLookupTableBase intact but adding a deprecation notice instead.

PiperOrigin-RevId: 220130488
This commit is contained in:
Rohan Jain 2018-11-05 10:42:43 -08:00 committed by TensorFlower Gardener
parent f74a043642
commit 6dc0f05f84

View File

@ -171,6 +171,11 @@ class InitializableLookupTableBase(LookupInterface):
def initializer(self):
return self._init_op
@property
@deprecated("2018-12-15", "Use `initializer` instead.")
def init(self):
return self.initializer
@property
def default_value(self):
"""The default value of the table."""
@ -830,6 +835,11 @@ class IdTableWithHashBuckets(LookupInterface):
with ops.name_scope(None, "init"):
return control_flow_ops.no_op()
@property
@deprecated("2018-12-15", "Use `initializer` instead.")
def init(self):
return self.initializer
@property
def resource_handle(self):
if self._table is not None: