ccdv commited on
Commit
6e2d48d
1 Parent(s): 16ed971
Files changed (1) hide show
  1. QR-AN.py +13 -24
QR-AN.py CHANGED
@@ -103,30 +103,19 @@ class QRANDataset(datasets.GeneratorBasedBuilder):
103
  DEFAULT_CONFIG_NAME = "qran_answer"
104
 
105
  def _info(self):
106
- if self.config.name == "qran_generation":
107
- return datasets.DatasetInfo(
108
- description=_DESCRIPTION,
109
- features=datasets.Features(
110
- {
111
- "question": datasets.Value("string"),
112
- "answer": datasets.Value("string"),
113
- }
114
- ),
115
- supervised_keys=None,
116
- citation=_CITATION,
117
- )
118
- else:
119
- return datasets.DatasetInfo(
120
- description=_DESCRIPTION,
121
- features=datasets.Features(
122
- {
123
- "text": datasets.Value("string"),
124
- "label": datasets.features.ClassLabel(names=_LABELS),
125
- }
126
- ),
127
- supervised_keys=None,
128
- citation=_CITATION,
129
- )
130
 
131
  def _split_generators(self, dl_manager):
132
  train_path = dl_manager.download_and_extract(self._TRAIN_FILE)
 
103
  DEFAULT_CONFIG_NAME = "qran_answer"
104
 
105
  def _info(self):
106
+
107
+ return datasets.DatasetInfo(
108
+ description=_DESCRIPTION,
109
+ features=datasets.Features(
110
+ {
111
+ "question": datasets.Value("string"),
112
+ "answer": datasets.Value("string"),
113
+ }
114
+ ),
115
+ supervised_keys=None,
116
+ citation=_CITATION,
117
+ )
118
+
 
 
 
 
 
 
 
 
 
 
 
119
 
120
  def _split_generators(self, dl_manager):
121
  train_path = dl_manager.download_and_extract(self._TRAIN_FILE)