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

Per rank mlflow tracking location and updating fcn_afno config for easier benchmarking #121

Merged
merged 1 commit into from
Oct 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
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
2 changes: 2 additions & 0 deletions examples/weather/fcn_afno/conf/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,9 @@ hydra:
dir: ./outputs/

wb_artifacts: False
use_mlflow: True

start_epoch: 0
max_epoch: 80

num_samples_per_year_train: 1456
4 changes: 2 additions & 2 deletions examples/weather/fcn_afno/train_era5.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ def main(cfg: DictConfig) -> None:
user_name="Modulus User",
mode="offline",
)
LaunchLogger.initialize(use_mlflow=True) # Modulus launch logger
LaunchLogger.initialize(use_mlflow=cfg.use_mlflow) # Modulus launch logger
logger = PythonLogger("main") # General python logger

datapipe = ERA5HDF5Datapipe(
Expand Down Expand Up @@ -199,7 +199,7 @@ def train_step_forward(my_model, invar, outvar):
return loss

# Main training loop
max_epoch = 80
max_epoch = cfg.max_epoch
for epoch in range(max(1, loaded_epoch + 1), max_epoch + 1):
# Wrap epoch in launch logger for console / WandB logs
with LaunchLogger(
Expand Down
2 changes: 1 addition & 1 deletion modulus/launch/logging/mlflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def initialize_mlflow(
group_name = f"{run_name}_{time_string}"
# Set default value here for Hydra
if tracking_location is None:
tracking_location = str(Path("./mlruns").absolute())
tracking_location = str(Path(f"./mlruns_{dist.rank}").absolute())

# Set up URI (remote or local)
if mode == "online":
Expand Down