LanguageBind commited on
Commit
5445c3d
·
verified ·
1 Parent(s): f5136ec

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -121,7 +121,7 @@ def initialize_models(args):
121
  nn.Dropout(0.3),
122
  nn.Linear(10240, 2)
123
  )
124
- task_head.load_state_dict(torch.load(os.path.join(args.model_path, 'task_head_final.pt')))
125
  task_head.eval()
126
 
127
  processor = AutoProcessor.from_pretrained(
@@ -271,7 +271,7 @@ def chat_step(image1, image2, text, height, width, steps, guidance,
271
  seed = torch.Generator(device="cpu").seed()
272
  torch.manual_seed(seed)
273
  # Generate
274
- if do_image:
275
  # image generation pipeline
276
  siglip_hs = None
277
  if state['siglip_processor'] and image_paths:
 
121
  nn.Dropout(0.3),
122
  nn.Linear(10240, 2)
123
  )
124
+ # task_head.load_state_dict(torch.load(os.path.join(args.model_path, 'task_head_final.pt')))
125
  task_head.eval()
126
 
127
  processor = AutoProcessor.from_pretrained(
 
271
  seed = torch.Generator(device="cpu").seed()
272
  torch.manual_seed(seed)
273
  # Generate
274
+ if True:
275
  # image generation pipeline
276
  siglip_hs = None
277
  if state['siglip_processor'] and image_paths: