mirror of
https://github.com/NicolasBohn/NexQuant.git
synced 2026-08-06 19:47:44 +00:00
feat: add ws CLI and support optional timeout/cache (#1066)
* feat: add ws CLI and support optional timeout/cache * lint * fix bugs * convert extra_volumes to dict for multiprocess * lint
This commit is contained in:
@@ -27,7 +27,8 @@ class DSCoderCoSTEERSettings(CoSTEERSettings):
|
||||
def get_ds_env(
|
||||
conf_type: Literal["kaggle", "mlebench"] = "kaggle",
|
||||
extra_volumes: dict = {},
|
||||
running_timeout_period: int = DS_RD_SETTING.debug_timeout,
|
||||
running_timeout_period: int | None = DS_RD_SETTING.debug_timeout,
|
||||
enable_cache: bool | None = None,
|
||||
) -> Env:
|
||||
"""
|
||||
Retrieve the appropriate environment configuration based on the env_type setting.
|
||||
@@ -52,8 +53,10 @@ def get_ds_env(
|
||||
)
|
||||
else:
|
||||
raise ValueError(f"Unknown env type: {conf.env_type}")
|
||||
env.conf.extra_volumes = extra_volumes
|
||||
env.conf.extra_volumes = extra_volumes.copy()
|
||||
env.conf.running_timeout_period = running_timeout_period
|
||||
if enable_cache is not None:
|
||||
env.conf.enable_cache = enable_cache
|
||||
env.prepare()
|
||||
return env
|
||||
|
||||
|
||||
Reference in New Issue
Block a user