@@ -68,11 +68,11 @@ def perform_special_model_features(self, model: BaseModel, conds: list, x_in: Te
6868 for special_model in special_models :
6969 if special_model .model .is_in_effect ():
7070 attachment = get_mm_attachment (special_model )
71- if attachment .is_pia ():
71+ if attachment .is_pia (special_model ):
7272 special_model .model .inject_unet_conv_in_pia_fancyvideo (model )
7373 conds = get_conds_with_c_concat (conds ,
7474 attachment .get_pia_c_concat (model , x_in ))
75- elif attachment .is_fancyvideo ():
75+ elif attachment .is_fancyvideo (special_model ):
7676 # TODO: handle other weights
7777 special_model .model .inject_unet_conv_in_pia_fancyvideo (model )
7878 conds = get_conds_with_c_concat (conds ,
@@ -90,9 +90,9 @@ def restore_special_model_features(self, model: BaseModel):
9090 if len (special_models ) > 0 :
9191 for special_model in reversed (special_models ):
9292 attachment = get_mm_attachment (special_model )
93- if attachment .is_pia ():
93+ if attachment .is_pia (special_model ):
9494 special_model .model .restore_unet_conv_in_pia_fancyvideo (model )
95- elif attachment .is_fancyvideo ():
95+ elif attachment .is_fancyvideo (special_model ):
9696 # TODO: fill out
9797 special_model .model .restore_unet_conv_in_pia_fancyvideo (model )
9898
@@ -189,8 +189,9 @@ def _apply_model_wrapper(executor, *args, **kwargs):
189189 ADGS : AnimateDiffGlobalState = transformer_options ["ADGS" ]
190190 if ADGS .motion_models is not None :
191191 for motion_model in ADGS .motion_models .models :
192- motion_model .prepare_alcmi2v_features (x = x , cond_or_uncond = cond_or_uncond , ad_params = ad_params , latent_format = executor .class_obj .latent_format )
193- motion_model .prepare_camera_features (x = x , cond_or_uncond = cond_or_uncond , ad_params = ad_params )
192+ attachment = get_mm_attachment (motion_model )
193+ attachment .prepare_alcmi2v_features (motion_model , x = x , cond_or_uncond = cond_or_uncond , ad_params = ad_params , latent_format = executor .class_obj .latent_format )
194+ attachment .prepare_camera_features (motion_model , x = x , cond_or_uncond = cond_or_uncond , ad_params = ad_params )
194195 del x
195196 return executor (* args , ** kwargs )
196197
0 commit comments