wondervictor commited on
Commit
0342c0e
·
verified ·
1 Parent(s): e4507cb

Update model.py

Browse files
Files changed (1) hide show
  1. model.py +2 -2
model.py CHANGED
@@ -114,10 +114,10 @@ class Model:
114
  condition_img = condition_img.resize((512,512))
115
  W, H = condition_img.size
116
 
117
- condition_img = torch.from_numpy(np.array(condition_img)).unsqueeze(0).permute(0,3,1,2).repeat(3,1,1,1)
118
  condition_img = condition_img.to(self.device)
119
  condition_img = 2*(condition_img/255 - 0.5)
120
- prompts = [prompt] * 3
121
  caption_embs, emb_masks = self.t5_model.get_text_embeddings(prompts)
122
 
123
  print(f"processing left-padding...")
 
114
  condition_img = condition_img.resize((512,512))
115
  W, H = condition_img.size
116
 
117
+ condition_img = torch.from_numpy(np.array(condition_img)).unsqueeze(0).permute(0,3,1,2).repeat(1,1,1,1)
118
  condition_img = condition_img.to(self.device)
119
  condition_img = 2*(condition_img/255 - 0.5)
120
+ prompts = [prompt] * 1
121
  caption_embs, emb_masks = self.t5_model.get_text_embeddings(prompts)
122
 
123
  print(f"processing left-padding...")