Cognomen commited on
Commit
7aebef6
Β·
1 Parent(s): be4582e
Files changed (1) hide show
  1. app.py +1 -4
app.py CHANGED
@@ -31,9 +31,6 @@ generator = torch.manual_seed(0)
31
  # inference function takes prompt, negative prompt and image
32
  def infer(prompt, negative_prompt, image):
33
  # implement your inference function here
34
-
35
- inp = np.copy(image)
36
- inp.setflags(write=False)
37
 
38
  cond_input = conditioning_image_transforms(image)
39
 
@@ -45,7 +42,7 @@ def infer(prompt, negative_prompt, image):
45
  num_inference_steps=20
46
  )
47
 
48
- return output[0]
49
 
50
  # you need to pass inputs and outputs according to inference function
51
  title = "Categorical Conditioning Controlnet for One-Shot Image Stylization."
 
31
  # inference function takes prompt, negative prompt and image
32
  def infer(prompt, negative_prompt, image):
33
  # implement your inference function here
 
 
 
34
 
35
  cond_input = conditioning_image_transforms(image)
36
 
 
42
  num_inference_steps=20
43
  )
44
 
45
+ return output
46
 
47
  # you need to pass inputs and outputs according to inference function
48
  title = "Categorical Conditioning Controlnet for One-Shot Image Stylization."