Checkpointable: compatibility mode with name-based saving
authorAllen Lavoie <allenl@google.com>
Sat, 24 Feb 2018 00:59:01 +0000 (16:59 -0800)
committerTensorFlower Gardener <gardener@tensorflow.org>
Sat, 24 Feb 2018 01:07:48 +0000 (17:07 -0800)
commitce4ae5bed9b47f49b085d9d8287cee2fcc5d42ac
tree78d699f20a737b2bcc72b9bead7161024b3f5bd8
parent4f983f23e05da691868a1e20c56e900bb4afbadd
Checkpointable: compatibility mode with name-based saving

Allows loading a name-based checkpoint using the object-based API. When
graph building it's quite seamless. There's no restore-on-create for
eager, so it would require program changes to do much useful there (i.e.
is not seamless).

Adds several tests for checkpoint compatibility (name->object in eager/graph,
and eager->graph/graph->eager for object-based saving)

PiperOrigin-RevId: 186844431
tensorflow/contrib/eager/python/checkpointable_utils.py
tensorflow/contrib/eager/python/checkpointable_utils_test.py