Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: Stop looking for environment file if already running in AML #432

Merged
merged 3 commits into from
Jun 13, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion hi-ml/src/health_ml/runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,13 @@ def after_submission_hook(azure_run: Run) -> None:
temp_conda_file: Optional[Path] = None
try:
if self.experiment_config.cluster:
env_file = choose_conda_env_file(env_file=self.experiment_config.conda_env)
# Enable spawned processes to find relative env file regardless of CWD
conda_env_file = self.experiment_config.conda_env
if conda_env_file is not None:
if str(self.project_root) not in str(conda_env_file):
conda_env_file = self.project_root / conda_env_file

env_file = choose_conda_env_file(env_file=conda_env_file)
mebristo marked this conversation as resolved.
Show resolved Hide resolved
logging.info(f"Using this Conda environment definition: {env_file}")
check_conda_environment(env_file)
# This adds all pip packages required by hi-ml and hi-ml-azure in case the code is used directly from
Expand Down