tolgacangoz commited on
Commit
6bb2088
·
verified ·
1 Parent(s): fc03512

Upload matryoshka.py

Browse files
Files changed (1) hide show
  1. scheduler/matryoshka.py +3 -3
scheduler/matryoshka.py CHANGED
@@ -3782,10 +3782,10 @@ class MatryoshkaPipeline(
3782
  new_config["clip_sample"] = False
3783
  scheduler._internal_dict = FrozenDict(new_config)
3784
 
3785
- is_unet_version_less_0_9_0 = hasattr(unet.config, "_diffusers_version") and version.parse(
3786
- version.parse(unet.config._diffusers_version).base_version
3787
  ) < version.parse("0.9.0.dev0")
3788
- is_unet_sample_size_less_64 = hasattr(unet.config, "sample_size") and unet.config.sample_size < 64
3789
  if is_unet_version_less_0_9_0 and is_unet_sample_size_less_64:
3790
  deprecation_message = (
3791
  "The configuration file of the unet has set the default `sample_size` to smaller than"
 
3782
  new_config["clip_sample"] = False
3783
  scheduler._internal_dict = FrozenDict(new_config)
3784
 
3785
+ is_unet_version_less_0_9_0 = hasattr(unet[0].config, "_diffusers_version") and version.parse(
3786
+ version.parse(unet[0].config._diffusers_version).base_version
3787
  ) < version.parse("0.9.0.dev0")
3788
+ is_unet_sample_size_less_64 = hasattr(unet[0].config, "sample_size") and unet[0].config.sample_size < 64
3789
  if is_unet_version_less_0_9_0 and is_unet_sample_size_less_64:
3790
  deprecation_message = (
3791
  "The configuration file of the unet has set the default `sample_size` to smaller than"