Type RunConfig
Namespace tensorflow.contrib.learn
Parent ClusterConfig
Interfaces IRunConfig
This class specifies the configurations for an `Estimator` run. This class is a deprecated implementation of
tf.estimator.RunConfig
interface.
Methods
Properties
- cluster_spec
- cluster_spec_dyn
- device_fn
- device_fn_dyn
- environment
- environment_dyn
- eval_distribute
- eval_distribute_dyn
- evaluation_master
- evaluation_master_dyn
- experimental_max_worker_delay_secs
- experimental_max_worker_delay_secs_dyn
- global_id_in_cluster
- global_id_in_cluster_dyn
- is_chief
- is_chief_dyn
- keep_checkpoint_every_n_hours
- keep_checkpoint_every_n_hours_dyn
- keep_checkpoint_max
- keep_checkpoint_max_dyn
- log_step_count_steps
- log_step_count_steps_dyn
- master
- master_dyn
- model_dir
- model_dir_dyn
- num_ps_replicas
- num_ps_replicas_dyn
- num_worker_replicas
- num_worker_replicas_dyn
- protocol
- protocol_dyn
- PythonObject
- save_checkpoints_secs
- save_checkpoints_secs_dyn
- save_checkpoints_steps
- save_checkpoints_steps_dyn
- save_summary_steps
- save_summary_steps_dyn
- service
- service_dyn
- session_config
- session_config_dyn
- session_creation_timeout_secs
- session_creation_timeout_secs_dyn
- task_id
- task_id_dyn
- task_type
- task_type_dyn
- tf_config
- tf_config_dyn
- tf_random_seed
- tf_random_seed_dyn
- train_distribute
- train_distribute_dyn
Public instance methods
IEnumerator<string> uid(IEnumerable<string> whitelist)
Generates a 'Unique Identifier' based on all internal fields. (experimental) Warning: THIS FUNCTION IS EXPERIMENTAL. It may change or be removed at any time, and without warning. Caller should use the uid string to check `RunConfig` instance integrity
in one session use, but should not rely on the implementation details, which
is subject to change.
Parameters
-
IEnumerable<string>
whitelist - A list of the string names of the properties uid should not include. If `None`, defaults to `_DEFAULT_UID_WHITE_LIST`, which includes most properties user allowes to change.
Returns
-
IEnumerator<string>
- A uid string.
object uid_dyn(object whitelist)
Generates a 'Unique Identifier' based on all internal fields. (experimental) Warning: THIS FUNCTION IS EXPERIMENTAL. It may change or be removed at any time, and without warning. Caller should use the uid string to check `RunConfig` instance integrity
in one session use, but should not rely on the implementation details, which
is subject to change.
Parameters
-
object
whitelist - A list of the string names of the properties uid should not include. If `None`, defaults to `_DEFAULT_UID_WHITE_LIST`, which includes most properties user allowes to change.
Returns
-
object
- A uid string.
Public static methods
RunConfig NewDyn(object master, ImplicitContainer<T> num_cores, ImplicitContainer<T> log_device_placement, ImplicitContainer<T> gpu_memory_fraction, object tf_random_seed, ImplicitContainer<T> save_summary_steps, ImplicitContainer<T> save_checkpoints_secs, object save_checkpoints_steps, ImplicitContainer<T> keep_checkpoint_max, ImplicitContainer<T> keep_checkpoint_every_n_hours, ImplicitContainer<T> log_step_count_steps, object protocol, ImplicitContainer<T> evaluation_master, object model_dir, object session_config, ImplicitContainer<T> session_creation_timeout_secs)
Constructor. (deprecated) Warning: THIS FUNCTION IS DEPRECATED. It will be removed in a future version.
Instructions for updating:
When switching to tf.estimator.Estimator, use tf.estimator.RunConfig instead. The superclass `ClusterConfig` may set properties like `cluster_spec`,
`is_chief`, `master` (if `None` in the args), `num_ps_replicas`, `task_id`,
and `task_type` based on the `TF_CONFIG` environment variable. See
`ClusterConfig` for more details. N.B.: If `save_checkpoints_steps` or `save_checkpoints_secs` is set,
`keep_checkpoint_max` might need to be adjusted accordingly, especially in
distributed training. For example, setting `save_checkpoints_secs` as 60
without adjusting `keep_checkpoint_max` (defaults to 5) leads to situation
that checkpoint would be garbage collected after 5 minutes. In distributed
training, the evaluation job starts asynchronously and might fail to load or
find the checkpoint due to race condition.
Parameters
-
object
master - TensorFlow master. Defaults to empty string for local.
-
ImplicitContainer<T>
num_cores - Number of cores to be used. If 0, the system picks an appropriate number (default: 0).
-
ImplicitContainer<T>
log_device_placement - Log the op placement to devices (default: False).
-
ImplicitContainer<T>
gpu_memory_fraction - Fraction of GPU memory used by the process on each GPU uniformly on the same machine.
-
object
tf_random_seed - Random seed for TensorFlow initializers. Setting this value allows consistency between reruns.
-
ImplicitContainer<T>
save_summary_steps - Save summaries every this many steps.
-
ImplicitContainer<T>
save_checkpoints_secs - Save checkpoints every this many seconds. Can not be specified with `save_checkpoints_steps`.
-
object
save_checkpoints_steps - Save checkpoints every this many steps. Can not be specified with `save_checkpoints_secs`.
-
ImplicitContainer<T>
keep_checkpoint_max - The maximum number of recent checkpoint files to keep. As new files are created, older files are deleted. If None or 0, all checkpoint files are kept. Defaults to 5 (that is, the 5 most recent checkpoint files are kept.)
-
ImplicitContainer<T>
keep_checkpoint_every_n_hours - Number of hours between each checkpoint to be saved. The default value of 10,000 hours effectively disables the feature.
-
ImplicitContainer<T>
log_step_count_steps - The frequency, in number of global steps, that the global step/sec will be logged during training.
-
object
protocol - An optional argument which specifies the protocol used when starting server. None means default to grpc.
-
ImplicitContainer<T>
evaluation_master - the master on which to perform evaluation.
-
object
model_dir - directory where model parameters, graph etc are saved. If `None`, will use `model_dir` property in `TF_CONFIG` environment variable. If both are set, must have same value. If both are `None`, see `Estimator` about where the model will be saved.
-
object
session_config - a ConfigProto used to set session parameters, or None. Note - using this argument, it is easy to provide settings which break otherwise perfectly good models. Use with care.
-
ImplicitContainer<T>
session_creation_timeout_secs - Max time workers should wait for a session to become available (on initialization or when recovering a session) with MonitoredTrainingSession. Defaults to 7200 seconds, but users may want to set a lower value to detect problems with variable / session (re)-initialization more quickly.