Open sadamov opened 1 month ago
Okay I requested another review, and from my side this PR should be ready for merge.
@joeloskarsson the issue was that wandb is only initialized once the trainer.fit() started. So a nice way to solve this issue is: removing the wandb.init()
as you suggested and then saving the configs in the ar_model:
def on_run_end(self):
if self.trainer.is_global_zero:
wandb.save("neural_lam/data_config.yaml")
@leifdenby can I add this PR to the roadmap for v.0.2.0? and then add it as a feature to the changelog as well?
Description: This PR introduces
rank_zero_print
andinit_wandb
utility functions to enhance printing behavior in multi-process environments and streamline Weights and Biases (wandb) initialization for logging and experiment tracking.Changes:
Added
rank_zero_print
function:print
function for selective printing based on process rank.Introduced
init_wandb
function:WandbLogger
for PyTorch Lightning integration.constants.py
file to wandb for reference.Added necessary imports for time, PyTorch Lightning, wandb, and rank-zero utilities.
Benefits:
constants.py
file to wandb.