Update Image-demo.py
Browse files- Image-demo.py +2 -2
Image-demo.py
CHANGED
@@ -48,12 +48,12 @@ class ImageSet(datasets.GeneratorBasedBuilder):
|
|
48 |
name=datasets.Split.TRAIN,
|
49 |
gen_kwargs={
|
50 |
"images": image_iters
|
51 |
-
"
|
52 |
}
|
53 |
),
|
54 |
]
|
55 |
|
56 |
-
def _generate_examples(self, images,
|
57 |
""" This function returns the examples in the raw (text) form."""
|
58 |
_CAPTION = json.load(open(filePath, 'r'))
|
59 |
for idx, (filepath, image) in enumerate(images):
|
|
|
48 |
name=datasets.Split.TRAIN,
|
49 |
gen_kwargs={
|
50 |
"images": image_iters
|
51 |
+
"filepath":filepath
|
52 |
}
|
53 |
),
|
54 |
]
|
55 |
|
56 |
+
def _generate_examples(self, images, filepath):
|
57 |
""" This function returns the examples in the raw (text) form."""
|
58 |
_CAPTION = json.load(open(filePath, 'r'))
|
59 |
for idx, (filepath, image) in enumerate(images):
|