-
Notifications
You must be signed in to change notification settings - Fork 0
Add distillation script for faster inference #54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@@ -147,7 +177,7 @@ | |||
) | |||
|
|||
# Load the learning rate scheduler state if a checkpoint is provided | |||
if args.checkpoint is not None: | |||
if args.checkpoint is not None and False: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This will always result in False
.
I assume you meant if args.checkpoint is not None and args.checkpoint is not False
in which case I would just do if args.checkpoint:
But I don't really see when it could be False anyway, since it is defined as a str
argument.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was just a hack to deactivate this code path. I will clean this up with another flag. Because loading the learning rate scheduler state when starting from a pretrained model is not desirable (as the end of the schedule was reached during pretrained). In contrast to that you want to resume the schedule if e.g. the training was interrupted.
Proposed changes
This adds an experimental script that is able to distill a diffusion model into one that only does a single step.
Checklist
DDLitLab
project board