update moment_key
Browse files
nba_tracking_data_15_16.py
CHANGED
|
@@ -156,8 +156,8 @@ class NbaTracking(datasets.GeneratorBasedBuilder):
|
|
| 156 |
def _generate_examples(self, filepaths, split):
|
| 157 |
# TODO: This method handles input defined in _split_generators to yield (key, example) tuples from the dataset.
|
| 158 |
# The `key` is for legacy reasons (tfds) and is not important in itself, but must be unique for each example.
|
|
|
|
| 159 |
for game_title, link in filepaths.items():
|
| 160 |
-
moment_id = 0
|
| 161 |
with open(link, encoding="utf-8") as fp:
|
| 162 |
game = json.load(fp)
|
| 163 |
game_id = game["gameid"]
|
|
|
|
| 156 |
def _generate_examples(self, filepaths, split):
|
| 157 |
# TODO: This method handles input defined in _split_generators to yield (key, example) tuples from the dataset.
|
| 158 |
# The `key` is for legacy reasons (tfds) and is not important in itself, but must be unique for each example.
|
| 159 |
+
moment_id = 0
|
| 160 |
for game_title, link in filepaths.items():
|
|
|
|
| 161 |
with open(link, encoding="utf-8") as fp:
|
| 162 |
game = json.load(fp)
|
| 163 |
game_id = game["gameid"]
|