ZeroCommand commited on
Commit
0d92a0d
1 Parent(s): 717364a

hot fix labels doublw list

Browse files
Files changed (1) hide show
  1. text_classification.py +1 -1
text_classification.py CHANGED
@@ -24,7 +24,7 @@ def get_labels_and_features_from_dataset(dataset_id, dataset_config, split):
24
  label_feat = dataset_features[label_keys[0]].feature
25
  labels = label_feat.names
26
  else:
27
- labels = [dataset_features[label_keys[0]].names]
28
  features = [f for f in dataset_features.keys() if not f.startswith("label")]
29
  return labels, features
30
  except Exception as e:
 
24
  label_feat = dataset_features[label_keys[0]].feature
25
  labels = label_feat.names
26
  else:
27
+ labels = dataset_features[label_keys[0]].names
28
  features = [f for f in dataset_features.keys() if not f.startswith("label")]
29
  return labels, features
30
  except Exception as e: