mathemakitten commited on
Commit
efa4e1c
1 Parent(s): 6cd5fef
Files changed (1) hide show
  1. glue-suite-v2.py +30 -32
glue-suite-v2.py CHANGED
@@ -13,36 +13,34 @@ class Suite(evaluate.EvaluationSuite):
13
  citation="insert citation here",
14
  features=Features({"predictions": Value("int64"), "references": Value("int64")}))
15
 
16
- def setup(self):
17
- self.preprocessor = None #lambda x: x["text"].lower()
18
-
19
- print(SubTask)
20
- self.suite = [
21
- SubTask(
22
- data="imdb",
23
- split="test",
24
- data_preprocessor=lambda x: x["text"].lower(),#self.preprocessor,
25
- args_for_task={"metric": "accuracy",
26
- "input_column": "text",
27
- "label_column": "label",
28
- "label_mapping": {
29
- "LABEL_0": 0.0,
30
- "LABEL_1": 1.0
31
- }
32
  }
33
- ),
34
- SubTask(
35
- data="sst2",
36
- split="test[:10]",
37
- data_preprocessor=self.preprocessor,
38
- # args_for_task={
39
- # "metric": "accuracy",
40
- # "input_column": "sentence",
41
- # "label_column": "label",
42
- # "label_mapping": {
43
- # "LABEL_0": 0.0,
44
- # "LABEL_1": 1.0
45
- # }
46
- # }
47
- )
48
- ]
 
 
13
  citation="insert citation here",
14
  features=Features({"predictions": Value("int64"), "references": Value("int64")}))
15
 
16
+ preprocessor = None #lambda x: x["text"].lower()
17
+ suite = [
18
+ SubTask(
19
+ data="imdb",
20
+ split="test",
21
+ data_preprocessor=lambda x: x["text"].lower(),#self.preprocessor,
22
+ args_for_task={
23
+ "metric": "accuracy",
24
+ "input_column": "text",
25
+ "label_column": "label",
26
+ "label_mapping": {
27
+ "LABEL_0": 0.0,
28
+ "LABEL_1": 1.0
 
 
 
29
  }
30
+ }
31
+ ),
32
+ SubTask(
33
+ data="sst2",
34
+ split="test[:10]",
35
+ data_preprocessor=self.preprocessor,
36
+ # args_for_task={
37
+ # "metric": "accuracy",
38
+ # "input_column": "sentence",
39
+ # "label_column": "label",
40
+ # "label_mapping": {
41
+ # "LABEL_0": 0.0,
42
+ # "LABEL_1": 1.0
43
+ # }
44
+ # }
45
+ )
46
+ ]