a-alnaggar
commited on
Update khatt-paragraphs.py
Browse files- khatt-paragraphs.py +2 -2
khatt-paragraphs.py
CHANGED
@@ -55,9 +55,9 @@ class KhattPara(datasets.GeneratorBasedBuilder):
|
|
55 |
for idx, (filepath, image) in enumerate(images):
|
56 |
text_path = os.path.join("proc_text", str(os.path.basename(filepath)[:-4] + ".txt"))
|
57 |
text = self.read_arabic_text_file(os.path.join(text_archive_path,text_path))
|
58 |
-
|
59 |
yield idx, {
|
60 |
-
"image": {"path": filepath, "bytes":
|
61 |
"text": text,
|
62 |
}
|
63 |
|
|
|
55 |
for idx, (filepath, image) in enumerate(images):
|
56 |
text_path = os.path.join("proc_text", str(os.path.basename(filepath)[:-4] + ".txt"))
|
57 |
text = self.read_arabic_text_file(os.path.join(text_archive_path,text_path))
|
58 |
+
|
59 |
yield idx, {
|
60 |
+
"image": {"path": filepath, "bytes": image.read()},
|
61 |
"text": text,
|
62 |
}
|
63 |
|