LuyangZ commited on
Commit
8211204
·
verified ·
1 Parent(s): c1197f5

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -3,6 +3,7 @@ import cv2
3
  from PIL import Image
4
  import numpy as np
5
 
 
6
  from diffusers import StableDiffusionControlNetPipeline, ControlNetModel, UniPCMultistepScheduler
7
  from diffusers.utils import load_image
8
  import torch
@@ -84,7 +85,8 @@ def clean_img(image, mask):
84
  image[mask<250]=(255,255,255)
85
  image = Image.fromarray(image).convert('RGB')
86
  return image
87
-
 
88
  def floorplan_generation(outline, num_of_rooms):
89
  new_width = 512
90
  new_height = 512
 
3
  from PIL import Image
4
  import numpy as np
5
 
6
+ +import spaces
7
  from diffusers import StableDiffusionControlNetPipeline, ControlNetModel, UniPCMultistepScheduler
8
  from diffusers.utils import load_image
9
  import torch
 
85
  image[mask<250]=(255,255,255)
86
  image = Image.fromarray(image).convert('RGB')
87
  return image
88
+
89
90
  def floorplan_generation(outline, num_of_rooms):
91
  new_width = 512
92
  new_height = 512