Datasets:
Upload qqp.py
Browse files
qqp.py
CHANGED
|
@@ -186,10 +186,6 @@ class Glue(datasets.GeneratorBasedBuilder):
|
|
| 186 |
}
|
| 187 |
if self.config.label_column in item:
|
| 188 |
label = item[self.config.label_column]
|
| 189 |
-
# For some tasks, the label is represented as 0 and 1 in the tsv
|
| 190 |
-
# files and needs to be cast to integer to work with the feature.
|
| 191 |
-
if label_classes and label not in label_classes:
|
| 192 |
-
label = int(label) if label else None
|
| 193 |
example["label"] = process_label(label)
|
| 194 |
else:
|
| 195 |
example["label"] = process_label(-1)
|
|
|
|
| 186 |
}
|
| 187 |
if self.config.label_column in item:
|
| 188 |
label = item[self.config.label_column]
|
|
|
|
|
|
|
|
|
|
|
|
|
| 189 |
example["label"] = process_label(label)
|
| 190 |
else:
|
| 191 |
example["label"] = process_label(-1)
|