attempt to restructure this
Browse files
nba_tracking_data_15_16.py
CHANGED
@@ -80,6 +80,7 @@ class NbaTracking(datasets.GeneratorBasedBuilder):
|
|
80 |
"""Tracking data for all games of 2015-2016 season in forms of coordinates for players and ball at each moment."""
|
81 |
|
82 |
items = ITEMS
|
|
|
83 |
|
84 |
BUILDER_CONFIG_CLASS = NbaTrackingConfig
|
85 |
|
@@ -189,7 +190,7 @@ class NbaTracking(datasets.GeneratorBasedBuilder):
|
|
189 |
|
190 |
def _split_generators(self, dl_manager):
|
191 |
random.seed(9)
|
192 |
-
items = random.sample(items, self.config.samples)
|
193 |
|
194 |
_URLS = {}
|
195 |
for game in items:
|
@@ -197,7 +198,6 @@ class NbaTracking(datasets.GeneratorBasedBuilder):
|
|
197 |
_URLS[name] = _URL + "/" + name + ".7z"
|
198 |
|
199 |
_URLS = _URLS
|
200 |
-
_PBP_URL = _PBP_URL
|
201 |
|
202 |
urls = self._URLS
|
203 |
data_dir = dl_manager.download_and_extract(urls)
|
|
|
80 |
"""Tracking data for all games of 2015-2016 season in forms of coordinates for players and ball at each moment."""
|
81 |
|
82 |
items = ITEMS
|
83 |
+
_PBP_URL = _PBP_URL
|
84 |
|
85 |
BUILDER_CONFIG_CLASS = NbaTrackingConfig
|
86 |
|
|
|
190 |
|
191 |
def _split_generators(self, dl_manager):
|
192 |
random.seed(9)
|
193 |
+
items = random.sample(self.items, self.config.samples)
|
194 |
|
195 |
_URLS = {}
|
196 |
for game in items:
|
|
|
198 |
_URLS[name] = _URL + "/" + name + ".7z"
|
199 |
|
200 |
_URLS = _URLS
|
|
|
201 |
|
202 |
urls = self._URLS
|
203 |
data_dir = dl_manager.download_and_extract(urls)
|