diff options
author | Allen Lavoie <allenl@google.com> | 2018-04-19 09:54:40 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2018-04-19 09:57:23 -0700 |
commit | 436f1434060d7f370baae9661baacc6cf27415ec (patch) | |
tree | 9276bf419abb2e1bcfccdb7c43bea7ffbab80283 /tensorflow/contrib/cudnn_rnn | |
parent | c173157bdc132460c6f424a9803221e74fc73f59 (diff) |
Create a skeleton tf.contrib.checkpoint.
My plan for this is to incubate tools for working with object-based checkpoints:
- Tools for managing dependency graphs, e.g. checkpointable lists/dictionaries
- Inspecting/visualizing checkpoints
- Listing variables and gathering initializers from a Checkpointable object
and its dependencies
- Verifying all variables are accessible as dependencies, which should make
converting existing graph building Saver uses easier/safer.
This CL includes none of those things, it just moves the split_dependency tool
here instead of contrib/eager.
PiperOrigin-RevId: 193531292
Diffstat (limited to 'tensorflow/contrib/cudnn_rnn')
-rw-r--r-- | tensorflow/contrib/cudnn_rnn/BUILD | 2 | ||||
-rw-r--r-- | tensorflow/contrib/cudnn_rnn/python/ops/cudnn_rnn_ops.py | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/tensorflow/contrib/cudnn_rnn/BUILD b/tensorflow/contrib/cudnn_rnn/BUILD index d68015ae15..aeefa3cee6 100644 --- a/tensorflow/contrib/cudnn_rnn/BUILD +++ b/tensorflow/contrib/cudnn_rnn/BUILD @@ -25,7 +25,7 @@ tf_custom_op_py_library( srcs_version = "PY2AND3", visibility = ["//visibility:public"], deps = [ - "//tensorflow/contrib/eager/python:checkpointable_utils", + "//tensorflow/contrib/checkpoint/python:split_dependency", "//tensorflow/contrib/util:util_py", "//tensorflow/python:array_ops", "//tensorflow/python:control_flow_ops", diff --git a/tensorflow/contrib/cudnn_rnn/python/ops/cudnn_rnn_ops.py b/tensorflow/contrib/cudnn_rnn/python/ops/cudnn_rnn_ops.py index b615824460..a1ede4471e 100644 --- a/tensorflow/contrib/cudnn_rnn/python/ops/cudnn_rnn_ops.py +++ b/tensorflow/contrib/cudnn_rnn/python/ops/cudnn_rnn_ops.py @@ -17,7 +17,7 @@ from __future__ import absolute_import from __future__ import division from __future__ import print_function -from tensorflow.contrib.eager.python import checkpointable_utils +from tensorflow.contrib.checkpoint.python import split_dependency from tensorflow.contrib.rnn.python.ops import lstm_ops from tensorflow.python.framework import common_shapes from tensorflow.python.framework import dtypes @@ -318,7 +318,7 @@ class CudnnOpaqueParamsSaveable(saver.BaseSaverBuilder.SaveableObject): dependencies too (typically the cuDNN `Layer`). dtype: The dtype for the canonical parameter Tensors. """ - split_dependencies = checkpointable_utils.split_dependency( + split_dependencies = split_dependency.split_dependency( component_names=self._param_names, component_dtypes=(dtype,) * len(self._param_names), fill_save_buffer_fn=self._checkpointable_save, |