xichenhku commited on
Commit
9cfc285
1 Parent(s): 8846870

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -21,7 +21,7 @@ from models.depth_guider import DepthGuider
21
  from mimicbrush import MimicBrush_RefNet
22
  from data_utils import *
23
  from modelscope.hub.snapshot_download import snapshot_download as ms_snapshot_download
24
-
25
 
26
 
27
  sd_dir = ms_snapshot_download('xichen/cleansd', cache_dir='./modelscope')
@@ -176,6 +176,7 @@ mimicbrush_model = MimicBrush_RefNet(pipe, image_encoder_path, mimicbrush_ckpt,
176
  mask_processor = VaeImageProcessor(vae_scale_factor=1, do_normalize=False, do_binarize=True, do_convert_grayscale=True)
177
 
178
 
 
179
  def infer_single(ref_image, target_image, target_mask, seed = -1, num_inference_steps=50, guidance_scale = 5, enable_shape_control = False):
180
  #return ref_image
181
  """
 
21
  from mimicbrush import MimicBrush_RefNet
22
  from data_utils import *
23
  from modelscope.hub.snapshot_download import snapshot_download as ms_snapshot_download
24
+ import spaces
25
 
26
 
27
  sd_dir = ms_snapshot_download('xichen/cleansd', cache_dir='./modelscope')
 
176
  mask_processor = VaeImageProcessor(vae_scale_factor=1, do_normalize=False, do_binarize=True, do_convert_grayscale=True)
177
 
178
 
179
+ @spaces.GPU
180
  def infer_single(ref_image, target_image, target_mask, seed = -1, num_inference_steps=50, guidance_scale = 5, enable_shape_control = False):
181
  #return ref_image
182
  """