Skip to content

Commit

Permalink
session_config
Browse files Browse the repository at this point in the history
  • Loading branch information
Ubuntu authored and lefnire committed Feb 10, 2018
1 parent aa793c2 commit 6f8f8e9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tensorforce/models/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -533,13 +533,14 @@ def init_fn(scaffold, session):
# tf.train.NanTensorHook(loss_tensor, fail_on_nan_loss=True)
# tf.train.ProfilerHook(save_steps=None, save_secs=None, output_dir='', show_dataflow=True, show_memory=False)

session_config = tf.ConfigProto(gpu_options=tf.GPUOptions(per_process_gpu_memory_fraction=.9/2))
if self.distributed_spec is None:
# TensorFlow non-distributed monitored session object
self.monitored_session = tf.train.SingularMonitoredSession(
hooks=hooks,
scaffold=self.scaffold,
master='', # Default value.
config=None, # self.distributed_spec.get('session_config'),
config=session_config,
checkpoint_dir=None
)

Expand Down

0 comments on commit 6f8f8e9

Please sign in to comment.