Lint Python files with Yapf (#1872)

This commit is contained in:
Philipp Moritz
2018-04-11 10:11:35 -07:00
committed by Robert Nishihara
parent a3ddde398c
commit 74162d1492
97 changed files with 3927 additions and 3139 deletions
+16 -4
View File
@@ -35,14 +35,26 @@ class Experiment(object):
checkpoint at least this many times. Only applies if
checkpointing is enabled. Defaults to 3.
"""
def __init__(self, name, run, stop=None, config=None,
trial_resources=None, repeat=1, local_dir=None,
upload_dir="", checkpoint_freq=0, max_failures=3):
def __init__(self,
name,
run,
stop=None,
config=None,
trial_resources=None,
repeat=1,
local_dir=None,
upload_dir="",
checkpoint_freq=0,
max_failures=3):
spec = {
"run": run,
"stop": stop or {},
"config": config or {},
"trial_resources": trial_resources or {"cpu": 1, "gpu": 0},
"trial_resources": trial_resources or {
"cpu": 1,
"gpu": 0
},
"repeat": repeat,
"local_dir": local_dir or DEFAULT_RESULTS_DIR,
"upload_dir": upload_dir,