Skip to content

Instantly share code, notes, and snippets.

@SubhadityaMukherjee
Created August 12, 2022 17:32
Show Gist options
  • Save SubhadityaMukherjee/6de0506d5287a2885848a9cbb7e98a68 to your computer and use it in GitHub Desktop.
Save SubhadityaMukherjee/6de0506d5287a2885848a9cbb7e98a68 to your computer and use it in GitHub Desktop.
teach
learn = vision_learner(dls,
resnet18, #architecture
loss_func=LabelSmoothingCrossEntropy(), #loss function/objective
opt_func=partial(OptimWrapper, opt=torch.optim.AdamW), # Optimizer
metrics=[accuracy, error_rate],
cbs=[MixUp]).to_fp16() #callbacks, mixed precision
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment