Spaces:
Runtime error
Runtime error
Update model.py
Browse files
model.py
CHANGED
@@ -381,6 +381,7 @@ class StreamMultiDiffusion(nn.Module):
|
|
381 |
question = 'Question: What are in the image? Answer:'
|
382 |
inputs = self.i2t_processor(image, question, return_tensors='pt')
|
383 |
out = self.i2t_model.generate(**{k: v.to(self.i2t_model.device) for k, v in inputs.items()}, max_new_tokens=77)
|
|
|
384 |
prompt = self.i2t_processor.decode(out[0], skip_special_tokens=True).strip()
|
385 |
return prompt
|
386 |
|
|
|
381 |
question = 'Question: What are in the image? Answer:'
|
382 |
inputs = self.i2t_processor(image, question, return_tensors='pt')
|
383 |
out = self.i2t_model.generate(**{k: v.to(self.i2t_model.device) for k, v in inputs.items()}, max_new_tokens=77)
|
384 |
+
print(out)
|
385 |
prompt = self.i2t_processor.decode(out[0], skip_special_tokens=True).strip()
|
386 |
return prompt
|
387 |
|