Skip to content

Commit

Permalink
Merge pull request #39 from wandb/fix/fashion-mnist-configs
Browse files Browse the repository at this point in the history
fix: Set fashion mnist inputs as configs
  • Loading branch information
KyleGoyette authored Feb 26, 2024
2 parents c1497c7 + 8027d64 commit 1188725
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions jobs/fashion_mnist_train/job.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,14 @@


def train(project: Optional[str], entity: Optional[str], **kwargs: Any):
run = wandb.init(project=project, entity=entity)
run = wandb.init(project=project, entity=entity, config={
"epochs": 10,
"learning_rate": 0.001,
"steps_per_epoch": 10,
})

# get config, could be set from sweep scheduler
train_config = run.config

# get training parameters from config
epochs = train_config.get("epochs", 10)
learning_rate = train_config.get("learning_rate", 0.001)
Expand Down Expand Up @@ -98,7 +101,6 @@ def train(project: Optional[str], entity: Optional[str], **kwargs: Any):
# Log plot
wandb.log({"prediction-chart": plt})


# Code from: https://www.geeksforgeeks.org/fashion-mnist-with-python-keras-and-deep-learning/
def model_arch():
"""Define the architecture of the model"""
Expand Down

0 comments on commit 1188725

Please sign in to comment.