Jyothirmai commited on
Commit
37335e4
1 Parent(s): 6ae4f98

Update clipGPT.py

Browse files
Files changed (1) hide show
  1. clipGPT.py +1 -1
clipGPT.py CHANGED
@@ -158,7 +158,7 @@ def generate_caption_clipgpt(img):
158
  tokenizer = GPT2Tokenizer.from_pretrained("gpt2")
159
 
160
  start_time = time.time()
161
- pil_image = PIL.Image.fromarray(image)
162
  image = preprocess(pil_image).unsqueeze(0).to(device)
163
 
164
  with torch.no_grad():
 
158
  tokenizer = GPT2Tokenizer.from_pretrained("gpt2")
159
 
160
  start_time = time.time()
161
+ pil_image = PIL.Image.fromarray(img)
162
  image = preprocess(pil_image).unsqueeze(0).to(device)
163
 
164
  with torch.no_grad():