Skip to content

Commit

Permalink
Merge pull request #53 from noskill/main
Browse files Browse the repository at this point in the history
fix loading from safetensors
  • Loading branch information
Necr0x0Der authored Apr 24, 2024
2 parents d54a065 + 07749b8 commit 7837a30
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions multigen/pipes.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,10 +82,10 @@ def __init__(self, model_id: str,
else:
# we can't use specific class, because we dont know if it is sdxl
self.pipe = DiffusionPipeline.from_pretrained(self.model_id, **args)
if 'custom_pipeline' not in args:
# create correct class if custom_pipeline is not specified
# at this stage we know that the model is sdxl or sd
self.pipe = self.from_pipe(self.pipe, **constructor_args)
if 'custom_pipeline' not in args:
# create correct class if custom_pipeline is not specified
# at this stage we know that the model is sdxl or sd
self.pipe = self.from_pipe(self.pipe, **constructor_args)

else:
if self.model_id.endswith('.safetensors'):
Expand Down

0 comments on commit 7837a30

Please sign in to comment.