Initial commit
Browse files- docbank.py +2 -2
docbank.py
CHANGED
|
@@ -222,7 +222,7 @@ class Docbank(datasets.GeneratorBasedBuilder):
|
|
| 222 |
# print(filepath)
|
| 223 |
key = 0
|
| 224 |
for f_fp_txt, f_fp_img in filepath:
|
| 225 |
-
|
| 226 |
f_id = key
|
| 227 |
#f_fp_txt = f['filepath_txt']
|
| 228 |
#f_fp_img = f['filepath_img']
|
|
@@ -240,7 +240,7 @@ class Docbank(datasets.GeneratorBasedBuilder):
|
|
| 240 |
with open(f_fp_txt, encoding='utf-8') as csvfile:
|
| 241 |
reader = csv.reader(csvfile, delimiter=',')
|
| 242 |
for row in reader:
|
| 243 |
-
|
| 244 |
# normalized_bbox = normalize_bbox(row[1:5], size)
|
| 245 |
normalized_bbox = [int(x) for x in row[1:5]]
|
| 246 |
tokens.append(row[0])
|
|
|
|
| 222 |
# print(filepath)
|
| 223 |
key = 0
|
| 224 |
for f_fp_txt, f_fp_img in filepath:
|
| 225 |
+
print(f_fp_txt)
|
| 226 |
f_id = key
|
| 227 |
#f_fp_txt = f['filepath_txt']
|
| 228 |
#f_fp_img = f['filepath_img']
|
|
|
|
| 240 |
with open(f_fp_txt, encoding='utf-8') as csvfile:
|
| 241 |
reader = csv.reader(csvfile, delimiter=',')
|
| 242 |
for row in reader:
|
| 243 |
+
print(row)
|
| 244 |
# normalized_bbox = normalize_bbox(row[1:5], size)
|
| 245 |
normalized_bbox = [int(x) for x in row[1:5]]
|
| 246 |
tokens.append(row[0])
|