You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The path of checkpoint turned out to be: $CURRENT_DIR/ray_result/TuneRelavtieLocalDirTest/PG_CartPole-v0_0_2019-05-01_15-24-54xo9z1bq8/ray_result/TuneRelavtieLocalDirTest/PG_CartPole-v0_0_2019-05-01_15-24-54xo9z1bq8/checkpoint_1/checkpoint-1
You can see that the path is nested. It is ought to be $CURRENT_DIR/ray_result/TuneRelavtieLocalDirTest/PG_CartPole-v0_0_2019-05-01_15-24-54xo9z1bq8/checkpoint_1/checkpoint-1
Using local_dir with dot identifier gives the same result.
tune.run(
self.algo,
name="TuneRelavtieLocalDirTest",
stop={"training_iteration": 1},
checkpoint_freq=1,
local_dir="./ray_result", # This should be ray/tune/tests/ray_result
config={
"env": "CartPole-v0",
},
)
Why this matter? Because in some cases, user needs to take away all the experiments results within their directory of codes, via git or FTP.
What about using absolute path?
abs_path = os.path.abspath("ray_result3")
print("abs_path:", abs_path) # abs_path: /Users/XXX/ray/python/ray/ray_result3
tune.run(
self.algo,
name="TuneRelavtieLocalDirTest",
stop={"training_iteration": 1},
checkpoint_freq=1,
local_dir=abs_path, # This should be ray/tune/tests/ray_result3
config={
"env": "CartPole-v0",
},
)
It's correct!
Discussion
I think maybe we can divide the local_dir into three kinds:
"./result"
"result"
"/User/XXX/result"
"~/result"
We should consider No.1 & 2 to be the relative path and the last two as absolute path.
The text was updated successfully, but these errors were encountered:
pengzhenghao
changed the title
Relative local_dir is not supported.
[tune] Relative local_dir is not supported.
May 1, 2019
System information
Describe the problem
If you use
The path of checkpoint turned out to be:
$CURRENT_DIR/ray_result/TuneRelavtieLocalDirTest/PG_CartPole-v0_0_2019-05-01_15-24-54xo9z1bq8/ray_result/TuneRelavtieLocalDirTest/PG_CartPole-v0_0_2019-05-01_15-24-54xo9z1bq8/checkpoint_1/checkpoint-1
You can see that the path is nested. It is ought to be
$CURRENT_DIR/ray_result/TuneRelavtieLocalDirTest/PG_CartPole-v0_0_2019-05-01_15-24-54xo9z1bq8/checkpoint_1/checkpoint-1
Using
local_dir
with dot identifier gives the same result.Why this matter? Because in some cases, user needs to take away all the experiments results within their directory of codes, via git or FTP.
What about using absolute path?
It's correct!
Discussion
I think maybe we can divide the
local_dir
into three kinds:We should consider No.1 & 2 to be the relative path and the last two as absolute path.
The text was updated successfully, but these errors were encountered: