Skip to content

Commit

Permalink
Fix/train limit logging (#140)
Browse files Browse the repository at this point in the history
* Ignore _do_training_repeats diagnostics when they're None

* Fix max-failures typo in instrument.py

* Add commented gpu dependencies to conda environment.yml
  • Loading branch information
hartikainen authored Apr 28, 2020
1 parent 84d7589 commit 0596f68
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 2 additions & 0 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,7 @@ dependencies:
- pip>=20.0
- conda>=4.7
- pyopengl-accelerate==3.1.3b1
# - cudatoolkit==10.1.243
# - cudnn==7.6.5
- pip:
- -r ./requirements.txt
2 changes: 1 addition & 1 deletion examples/instrument.py
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ def run_example_debug(example_module_name, example_argv):
of all cpus once ray local mode supports custom resources.
"""

debug_example_argv = ['--with-server=False', '--max-failure=0']
debug_example_argv = ['--with-server=False', '--max-failures=0']
for option in example_argv:
if '--trial-cpus' in option:
available_cpus = multiprocessing.cpu_count()
Expand Down
6 changes: 4 additions & 2 deletions softlearning/algorithms/rl_algorithm.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,10 @@ def _train(self):
gt.stamp('sample')

if self.ready_to_train:
update_diagnostics.append(self._do_training_repeats(
timestep=self._total_timestep))
repeat_diagnostics = self._do_training_repeats(
timestep=self._total_timestep)
if repeat_diagnostics is not None:
update_diagnostics.append(repeat_diagnostics)

gt.stamp('train')

Expand Down

0 comments on commit 0596f68

Please sign in to comment.