sheikh commited on
Commit
83f0dfa
·
1 Parent(s): 4857e17

Update SLR.py

Browse files
Files changed (1) hide show
  1. SLR.py +2 -2
SLR.py CHANGED
@@ -114,10 +114,10 @@ class SLR(datasets.GeneratorBasedBuilder):
114
  for item in data['categories']:
115
 
116
  labels=item['name']
117
- words.append(item['name'])
118
  ner_tags.append(labels)
119
  for item in data['annotations']:
120
  bbox=item['bbox']
121
  bboxes.append(bbox)
122
 
123
- yield guid, {"id": str(guid), "words":words, "tokens": tokens, "bboxes": bboxes, "ner_tags": ner_tags, "image": image, "image_path": image_path}
 
114
  for item in data['categories']:
115
 
116
  labels=item['name']
117
+ words.append(labels)
118
  ner_tags.append(labels)
119
  for item in data['annotations']:
120
  bbox=item['bbox']
121
  bboxes.append(bbox)
122
 
123
+ yield guid, {"id": str(guid), "words": words, "tokens": tokens, "bboxes": bboxes, "ner_tags": ner_tags, "image_path": image_path}