Governance trains TEA's EEG on a local reference folder when one is configured
This commit is contained in:
@@ -18,7 +18,7 @@ from pathlib import Path
|
||||
|
||||
TAIL_CHARS = 4000
|
||||
# A domain whose scenarios train on a reference cohort and not on a dbt cohort build.
|
||||
OWN_STEPS = {"tea": "Entrena con la cohorte de referencia de EEG (requiere el clúster o --reference-dir)."}
|
||||
OWN_STEPS = {"tea": "Entrena con la cohorte de referencia de EEG (el clúster, o la carpeta de `TEA_REFERENCE_DIR`)."}
|
||||
|
||||
|
||||
def _models_root() -> Path:
|
||||
@@ -54,6 +54,13 @@ def _command(domain: str, scenario: str) -> list[str]:
|
||||
argv = [sys.executable, "-m", "models", "run", domain, scenario, "--environment", "prod", "--train", "--promote"]
|
||||
if domain not in OWN_STEPS:
|
||||
argv += ["--export", "--source", "dbt", "--manifest", os.environ["DBT_MANIFEST"]]
|
||||
elif domain == "tea" and os.environ.get("TEA_REFERENCE_DIR"):
|
||||
# A reference cohort on this machine's disk, instead of the configured one in the cluster's storage.
|
||||
argv += ["--reference-dir", os.environ["TEA_REFERENCE_DIR"]]
|
||||
if os.environ.get("TEA_REFERENCE_AGES"):
|
||||
argv += ["--reference-ages", os.environ["TEA_REFERENCE_AGES"]]
|
||||
if os.environ.get("TEA_REFERENCE_LINE_HZ"):
|
||||
argv += ["--line-hz", os.environ["TEA_REFERENCE_LINE_HZ"]]
|
||||
return argv
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user