Skip to content

Commit

Permalink
[release][tune] Remove deprecated SyncConfig usage in `tune_cloud_d…
Browse files Browse the repository at this point in the history
…urable` release test (ray-project#43029)

ray-project#42909 hard deprecated outdated `SyncConfig` parameters, and this release test was not updated along with the rest of the examples. This `syncer` parameter was already being ignored, so it's okay to remove it fully now.

Signed-off-by: Justin Yu <justinvyu@anyscale.com>
Signed-off-by: tterrysun <terry@anyscale.com>
  • Loading branch information
justinvyu authored and tterrysun committed Feb 14, 2024
1 parent 6acfcdb commit 5bdf234
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 20 deletions.
10 changes: 0 additions & 10 deletions release/tune_tests/cloud_tests/workloads/_tune_script.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,6 @@ def on_step_begin(self, iteration, trials, **info):


def run_tune(
no_syncer: bool,
storage_path: Optional[str] = None,
experiment_name: str = "cloud_test",
indicator_file: str = "/tmp/tune_cloud_indicator",
Expand Down Expand Up @@ -114,8 +113,6 @@ def run_tune(
config=config,
storage_path=storage_path,
sync_config=train.SyncConfig(
syncer="auto" if not no_syncer else None,
sync_on_checkpoint=True,
sync_period=0.5,
sync_artifacts=True,
),
Expand All @@ -128,27 +125,20 @@ def run_tune(

if __name__ == "__main__":
parser = argparse.ArgumentParser()

parser.add_argument("--no-syncer", action="store_true", default=False)

parser.add_argument("--storage-path", required=False, default=None, type=str)

parser.add_argument("--experiment-name", required=False, default=None, type=str)

parser.add_argument(
"--indicator-file",
required=False,
default="/tmp/tune_cloud_indicator",
type=str,
)

args = parser.parse_args()

trainable = str(os.environ.get("TUNE_TRAINABLE", "function"))
num_cpus_per_trial = int(os.environ.get("TUNE_NUM_CPUS_PER_TRIAL", "2"))

run_kwargs = dict(
no_syncer=args.no_syncer or False,
storage_path=args.storage_path or None,
experiment_name=args.experiment_name or "cloud_test",
indicator_file=args.indicator_file,
Expand Down
10 changes: 0 additions & 10 deletions release/tune_tests/cloud_tests/workloads/run_cloud_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,15 +195,11 @@ def wait_for_nodes(


def start_run(
no_syncer: bool,
storage_path: Optional[str] = None,
experiment_name: str = "cloud_test",
indicator_file: str = "/tmp/tune_cloud_indicator",
) -> subprocess.Popen:
args = []
if no_syncer:
args.append("--no-syncer")

if storage_path:
args.extend(["--storage-path", storage_path])

Expand Down Expand Up @@ -297,13 +293,11 @@ def run_tune_script_for_time(
run_time: int,
experiment_name: str,
indicator_file: str,
no_syncer: bool,
storage_path: Optional[str],
run_start_timeout: int = 30,
):
# Start run
process = start_run(
no_syncer=no_syncer,
storage_path=storage_path,
experiment_name=experiment_name,
indicator_file=indicator_file,
Expand All @@ -327,7 +321,6 @@ def run_tune_script_for_time(
def run_resume_flow(
experiment_name: str,
indicator_file: str,
no_syncer: bool,
storage_path: Optional[str],
first_run_time: int = 33,
second_run_time: int = 33,
Expand Down Expand Up @@ -365,7 +358,6 @@ def run_resume_flow(
run_time=first_run_time,
experiment_name=experiment_name,
indicator_file=indicator_file,
no_syncer=no_syncer,
storage_path=storage_path,
run_start_timeout=run_start_timeout,
)
Expand All @@ -385,7 +377,6 @@ def run_resume_flow(
run_time=second_run_time,
experiment_name=experiment_name,
indicator_file=indicator_file,
no_syncer=no_syncer,
storage_path=storage_path,
)

Expand Down Expand Up @@ -1011,7 +1002,6 @@ def after_experiments():
run_resume_flow(
experiment_name=experiment_name,
indicator_file=indicator_file,
no_syncer=False,
storage_path=bucket,
first_run_time=run_time,
second_run_time=run_time,
Expand Down

0 comments on commit 5bdf234

Please sign in to comment.