Spaces:
Sleeping
Sleeping
Commit ·
0023489
1
Parent(s): 097dbb8
Fix: Override __call__ method in PixArtSigmaPipeline
Browse filesThe patched pipeline_pixart_alpha_call function was defined but never
assigned to the pipeline class. Added __call__ assignment to use the
patched call method that calls self.classify_height_width_bin() instead
of self.image_processor.classify_height_width_bin().
scripts/diffusers_patches.py
CHANGED
|
@@ -493,6 +493,9 @@ class PixArtSigmaPipeline(PixArtAlphaPipeline):
|
|
| 493 |
|
| 494 |
return image
|
| 495 |
|
|
|
|
|
|
|
|
|
|
| 496 |
|
| 497 |
def pixart_sigma_init_patched_inputs(self, norm_type):
|
| 498 |
assert self.config.sample_size is not None, "Transformer2DModel over patched input must provide sample_size"
|
|
|
|
| 493 |
|
| 494 |
return image
|
| 495 |
|
| 496 |
+
# Override __call__ with the patched version
|
| 497 |
+
__call__ = pipeline_pixart_alpha_call
|
| 498 |
+
|
| 499 |
|
| 500 |
def pixart_sigma_init_patched_inputs(self, norm_type):
|
| 501 |
assert self.config.sample_size is not None, "Transformer2DModel over patched input must provide sample_size"
|