-
Notifications
You must be signed in to change notification settings - Fork 204
fix: fix library name absolufy #289
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
pre-commit | ||
pytest | ||
autoflake | ||
absoulify-imports | ||
absolufy-imports |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,22 +8,25 @@ class StableDiffusion: | |
config_name: str = "stable_diffusion" | ||
|
||
def __init__(self, weights_path: str): | ||
pass | ||
raise NotImplementedError( | ||
"StableDiffusion is a placeholder and not yet implemented." | ||
) | ||
|
||
def finetune(self, dataset: Text2ImageDataset, logger=True): | ||
"""Finetune Stable Diffusion model on a given dataset. | ||
|
||
Args: | ||
dataset (Text2ImageDataset): Dataset to finetune on. | ||
logger (bool, optional): To be setup with a Pytorch Lightning logger when implemented.""" | ||
pass | ||
logger (bool, optional): To be setup with a Pytorch Lightning logger when implemented. | ||
""" | ||
raise NotImplementedError | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here, I would return the instance instead of the class |
||
|
||
def generate( | ||
self, | ||
texts: Optional[Union[List[str], str]] = None, | ||
dataset: Optional[Text2ImageDataset] = None, | ||
): | ||
pass | ||
raise NotImplementedError | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same |
||
|
||
def save(self, path: Union[str, Path]): | ||
pass | ||
raise NotImplementedError | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same |
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 is a good practice to return an exception instance instead of the class. It works, but I would use NotImplementedError()