Spaces:
Runtime error
Runtime error
utils.py
CHANGED
@@ -79,7 +79,7 @@ class Image2Text:
|
|
79 |
seq = re.sub(r"<.*?>", "", seq, count=1).strip()
|
80 |
seq = self.processor.token2json(seq)
|
81 |
contents = seq['content'].split('[newline]')
|
82 |
-
return
|
83 |
|
84 |
def get_text(self, img_path, num_beams=4):
|
85 |
pixel_values = self.load_img(img_path)
|
|
|
79 |
seq = re.sub(r"<.*?>", "", seq, count=1).strip()
|
80 |
seq = self.processor.token2json(seq)
|
81 |
contents = seq['content'].split('[newline]')
|
82 |
+
return contents
|
83 |
|
84 |
def get_text(self, img_path, num_beams=4):
|
85 |
pixel_values = self.load_img(img_path)
|