1818    StableAudioPipeline ,
1919    StableAudioProjectionModel ,
2020)
21- from  diffusers .models .modeling_utils  import  load_state_dict_into_meta 
21+ from  diffusers .models .modeling_utils  import  load_model_dict_into_meta 
2222from  diffusers .utils  import  is_accelerate_available 
2323
2424
@@ -221,7 +221,7 @@ def convert_stable_audio_state_dict_to_diffusers(state_dict, num_autoencoder_lay
221221        ],  # assume `seconds_start` and `seconds_total` have the same min / max values. 
222222    )
223223if  is_accelerate_available ():
224-     load_state_dict_into_meta (projection_model , projection_model_state_dict )
224+     load_model_dict_into_meta (projection_model , projection_model_state_dict )
225225else :
226226    projection_model .load_state_dict (projection_model_state_dict )
227227
@@ -242,7 +242,7 @@ def convert_stable_audio_state_dict_to_diffusers(state_dict, num_autoencoder_lay
242242        cross_attention_input_dim = model_config ["cond_token_dim" ],
243243    )
244244if  is_accelerate_available ():
245-     load_state_dict_into_meta (model , model_state_dict )
245+     load_model_dict_into_meta (model , model_state_dict )
246246else :
247247    model .load_state_dict (model_state_dict )
248248
@@ -260,7 +260,7 @@ def convert_stable_audio_state_dict_to_diffusers(state_dict, num_autoencoder_lay
260260    )
261261
262262if  is_accelerate_available ():
263-     load_state_dict_into_meta (autoencoder , autoencoder_state_dict )
263+     load_model_dict_into_meta (autoencoder , autoencoder_state_dict )
264264else :
265265    autoencoder .load_state_dict (autoencoder_state_dict )
266266
0 commit comments