Hugging Face Flax Community Week and W&B Support

Weights and Biases support for the Hugging Face Flax Community Week. Made by Morgan using Weights & Biases
Morgan
At Weights & Biases, we love to support the ML community. Hugging Face's Flax Community Week is a phenomenal idea and so W&B would like to support this event in a 3 ways:
See the BART-Pretraining project dashboard here as an example

Free W&B Team Project Sign-up

Weights and Biases would love to support the community for this event and so we're offering a free W&B Team project to every project group in this challenge. Just sign up in the sheet below and we'll ping you on Discord once the team is created

Add your Hugging Face Discord username and HF project name to this sheet for a free W&B Team project

Logging with W&B

Add the below code to any training script that uses Tensorboard to log to Weights & Biases. Make sure to have wandb installed and upgraded to the latest version:
pip install wandb --upgrade
Then, import wandb and call wandb.init to log the Tensorboard logs. You can also log additional config and even additional metric if you'd like
def main(): import wandb if jax.process_index() == 0: wandb.init( entity='my_team_name_or_username', project='norwegian-t5-demo', sync_tensorboard=True ) # log your configs with wandb.config, accepts a dict if jax.process_index() == 0: wandb.config.update(training_args) # optional, log your configs wandb.config.update(model_args) # optional, log your configs wandb.config.update(data_args) # optional, log your configs wandb.config['my_other_thing'] = 12345 # log additional things ... # Log additional metrics not logged to Tensorboard for b in batches ... metric = get_metric() if jax.process_index() == 0: wandb.log({'my_metric' : metric})

See the W&B Tensorboard integration docs for more

W&B Support

Weights and Biases are happy to run Q&A sessions with all projects interested! You can contact Morgan McGuire throughout the week to set up a call or help with any setup questions:P
Hugging Face Discord: @morg
Hugging Face Slack: @morg
Hugging Face Forums: @morgan

Hugging Face Trainer Integration

Finally, if using the Hugging Face Trainer (for PyTorch or Tensorflow work), see our docs here for code and explanations on how to log with Weights & Biases and the Hugging Face Trainer