Datasets:
GEM
/

Modalities:
Text
Languages:
English
Libraries:
Datasets
License:
ratishsp commited on
Commit
c4b38e9
1 Parent(s): 445676a

updates in definition of features

Browse files
Files changed (1) hide show
  1. mlb_data_to_text.py +142 -5
mlb_data_to_text.py CHANGED
@@ -64,15 +64,152 @@ class MlbDataToText(datasets.GeneratorBasedBuilder):
64
  features = datasets.Features(
65
  {
66
  "home_name": datasets.Value("string"),
67
- "box_score": dict,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
68
  "home_city": datasets.Value("string"),
69
  "vis_name": datasets.Value("string"),
70
- "play_by_play": dict,
71
- "vis_line": dict,
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
72
  "vis_city": datasets.Value("string"),
73
  "day": datasets.Value("string"),
74
- "home_line": dict,
75
- "summary": list,
 
76
  "gem_id": datasets.Value("string")
77
  }
78
  )
 
64
  features = datasets.Features(
65
  {
66
  "home_name": datasets.Value("string"),
67
+ "box_score": [
68
+ {
69
+ "p_l": datasets.Value("string"),
70
+ "last_name": datasets.Value("string"),
71
+ "p_h": datasets.Value("string"),
72
+ "sac": datasets.Value("string"),
73
+ "p_bb": datasets.Value("string"),
74
+ "pos": datasets.Value("string"),
75
+ "ao": datasets.Value("string"),
76
+ "p_bf": datasets.Value("string"),
77
+ "cs": datasets.Value("string"),
78
+ "hbp": datasets.Value("string"),
79
+ "ab": datasets.Value("string"),
80
+ "full_name": datasets.Value("string"),
81
+ "p_w": datasets.Value("string"),
82
+ "go": datasets.Value("string"),
83
+ "fldg": datasets.Value("string"),
84
+ "p_bs": datasets.Value("string"),
85
+ "avg": datasets.Value("string"),
86
+ "p_r": datasets.Value("string"),
87
+ "p_s": datasets.Value("string"),
88
+ "lob": datasets.Value("string"),
89
+ "first_name": datasets.Value("string"),
90
+ "p_sv": datasets.Value("string"),
91
+ "p_so": datasets.Value("string"),
92
+ "p_save": datasets.Value("string"),
93
+ "p_hr": datasets.Value("string"),
94
+ "po": datasets.Value("string"),
95
+ "p_ip1": datasets.Value("string"),
96
+ "p_ip2": datasets.Value("string"),
97
+ "bb": datasets.Value("string"),
98
+ "ops": datasets.Value("string"),
99
+ "p_hld": datasets.Value("string"),
100
+ "bo": datasets.Value("string"),
101
+ "p_loss": datasets.Value("string"),
102
+ "e": datasets.Value("string"),
103
+ "p_game_score": datasets.Value("string"),
104
+ "p_win": datasets.Value("string"),
105
+ "a": datasets.Value("string"),
106
+ "p_era": datasets.Value("string"),
107
+ "d": datasets.Value("string"),
108
+ "p_out": datasets.Value("string"),
109
+ "h": datasets.Value("string"),
110
+ "p_er": datasets.Value("string"),
111
+ "p_np": datasets.Value("string"),
112
+ "hr": datasets.Value("string"),
113
+ "r": datasets.Value("string"),
114
+ "so": datasets.Value("string"),
115
+ "t": datasets.Value("string"),
116
+ "rbi": datasets.Value("string"),
117
+ "team": datasets.Value("string"),
118
+ "sb": datasets.Value("string"),
119
+ "slg": datasets.Value("string"),
120
+ "sf": datasets.Value("string"),
121
+ "obp": datasets.Value("string"),
122
+ }
123
+ ],
124
  "home_city": datasets.Value("string"),
125
  "vis_name": datasets.Value("string"),
126
+ "play_by_play": [{
127
+ "top": [{
128
+ "runs": datasets.Value("string"),
129
+ "scorers": [{
130
+ datasets.Value("string"),
131
+ }
132
+ ],
133
+ "pitcher": datasets.Value("string"),
134
+ "o": datasets.Value("string"),
135
+ "b": datasets.Value("string"),
136
+ "s": datasets.Value("string"),
137
+ "batter": datasets.Value("string"),
138
+ "b1": [{
139
+ datasets.Value("string"),
140
+ }
141
+ ],
142
+ "b2": [{
143
+ datasets.Value("string"),
144
+ }
145
+ ],
146
+ "b3": [{
147
+ datasets.Value("string"),
148
+ }
149
+ ],
150
+ "event": datasets.Value("string"),
151
+ }
152
+ ],
153
+ "bottom": [{
154
+ "runs": datasets.Value("string"),
155
+ "scorers": [{
156
+ datasets.Value("string"),
157
+ }
158
+ ],
159
+ "pitcher": datasets.Value("string"),
160
+ "o": datasets.Value("string"),
161
+ "b": datasets.Value("string"),
162
+ "s": datasets.Value("string"),
163
+ "batter": datasets.Value("string"),
164
+ "b1": [{
165
+ datasets.Value("string"),
166
+ }
167
+ ],
168
+ "b2": [{
169
+ datasets.Value("string"),
170
+ }
171
+ ],
172
+ "b3": [{
173
+ datasets.Value("string"),
174
+ }
175
+ ],
176
+ "event": datasets.Value("string"),
177
+ }
178
+ ],
179
+ "inning": datasets.Value("string")
180
+ }
181
+ ],
182
+ "vis_line": {
183
+ "innings": [{
184
+ "inn": datasets.Value("string"),
185
+ "runs": datasets.Value("string")
186
+ }
187
+ ],
188
+ "result": datasets.Value("string"),
189
+ "team_runs": datasets.Value("string"),
190
+ "team_hits": datasets.Value("string"),
191
+ "team_errors": datasets.Value("string"),
192
+ "team_name": datasets.Value("string"),
193
+ "team_city": datasets.Value("string")
194
+ },
195
+ "home_line": {
196
+ "innings": [{
197
+ "inn": datasets.Value("string"),
198
+ "runs": datasets.Value("string")
199
+ }
200
+ ],
201
+ "result": datasets.Value("string"),
202
+ "team_runs": datasets.Value("string"),
203
+ "team_hits": datasets.Value("string"),
204
+ "team_errors": datasets.Value("string"),
205
+ "team_name": datasets.Value("string"),
206
+ "team_city": datasets.Value("string")
207
+ },
208
  "vis_city": datasets.Value("string"),
209
  "day": datasets.Value("string"),
210
+ "summary": [
211
+ datasets.Value("string"),
212
+ ],
213
  "gem_id": datasets.Value("string")
214
  }
215
  )