adirik commited on
Commit
7f597d1
β€’
1 Parent(s): a81e960
Files changed (2) hide show
  1. app.py +2 -2
  2. header.html +1 -1
app.py CHANGED
@@ -37,7 +37,7 @@ def process_image(image, prompt):
37
 
38
 
39
  def read_content(file_path):
40
- with open(file_path, 'r', encoding='utf-8') as f:
41
  content = f.read()
42
  return content
43
 
@@ -58,7 +58,7 @@ def predict(input_image, text_query, reference, scale, seed, step):
58
  mask = process_image(input_image, text_query).resize((width, height))
59
  #mask = dict["mask"].convert("RGB").resize((width, height))
60
 
61
- generator = torch.Generator('cuda').manual_seed(seed) if seed != 0 else None
62
  output = pipe(
63
  image=init_image,
64
  mask_image=mask,
 
37
 
38
 
39
  def read_content(file_path):
40
+ with open(file_path, "r", encoding="utf-8") as f:
41
  content = f.read()
42
  return content
43
 
 
58
  mask = process_image(input_image, text_query).resize((width, height))
59
  #mask = dict["mask"].convert("RGB").resize((width, height))
60
 
61
+ generator = torch.Generator("cuda").manual_seed(seed) if seed != 0 else None
62
  output = pipe(
63
  image=init_image,
64
  mask_image=mask,
header.html CHANGED
@@ -7,7 +7,7 @@
7
  margin-bottom: 10px;
8
  ">
9
  <h1 style="font-weight: 900; align-items: center; margin-bottom: 7px; margin-top: 20px;">
10
- Paint by Example 🎨
11
  </h1>
12
  </div>
13
  <div>
 
7
  margin-bottom: 10px;
8
  ">
9
  <h1 style="font-weight: 900; align-items: center; margin-bottom: 7px; margin-top: 20px;">
10
+ Change It!
11
  </h1>
12
  </div>
13
  <div>