adaface-neurips commited on
Commit
2bf6b24
1 Parent(s): d2b3308

Fix device bug

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -223,7 +223,7 @@ def check_prompt_and_model_type(prompt, model_style_type):
223
  base_model_path = model_style_type2base_model_path[model_style_type]
224
  # If the base model type is changed, reload the model.
225
  if model_style_type != args.model_style_type:
226
- id_animator = load_model(model_style_type=model_style_type, device=device)
227
  adaface = AdaFaceWrapper(pipeline_name="text2img", base_model_path=base_model_path,
228
  adaface_encoder_types=args.adaface_encoder_types,
229
  adaface_ckpt_paths=[args.adaface_ckpt_path], device='cpu')
 
223
  base_model_path = model_style_type2base_model_path[model_style_type]
224
  # If the base model type is changed, reload the model.
225
  if model_style_type != args.model_style_type:
226
+ id_animator = load_model(model_style_type=model_style_type, device='cpu')
227
  adaface = AdaFaceWrapper(pipeline_name="text2img", base_model_path=base_model_path,
228
  adaface_encoder_types=args.adaface_encoder_types,
229
  adaface_ckpt_paths=[args.adaface_ckpt_path], device='cpu')