Skip to content

Commit

Permalink
fix CB integration
Browse files Browse the repository at this point in the history
  • Loading branch information
tcapelle committed Jun 20, 2023
1 parent 838b25e commit 91c183a
Showing 1 changed file with 3 additions and 14 deletions.
17 changes: 3 additions & 14 deletions colabs/raytune/RayTune_with_wandb.ipynb
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
{
"cells": [
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"source": [
Expand Down Expand Up @@ -124,8 +123,7 @@
"import random\n",
"import numpy as np\n",
"from ray import tune\n",
"from ray.tune.logger import DEFAULT_LOGGERS\n",
"from ray.air.integrations.wandb import WandbLoggerCallback\n",
"from ray.air.integrations.wandb import WandbLoggerCallback, wandb_setup\n",
"import torch\n",
"import torch.optim as optim\n",
"import wandb"
Expand Down Expand Up @@ -207,9 +205,9 @@
"metadata": {},
"outputs": [],
"source": [
"@wandb_mixin\n",
"def train_mnist(config):\n",
"\n",
" # Setup wandb\n",
" wandb = wandb_setup(config)\n",
" device = torch.device('cuda' if torch.cuda.is_available() else 'cpu')\n",
" train_loader, test_loader = get_data_loaders()\n",
"\n",
Expand Down Expand Up @@ -262,15 +260,6 @@
"[the documentation for the `WandbLoggerCallback`](https://docs.ray.io/en/master/tune/tutorials/tune-wandb.html)."
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"wandb.login()"
]
},
{
"attachments": {},
"cell_type": "markdown",
Expand Down

0 comments on commit 91c183a

Please sign in to comment.