dcayton commited on
Commit
0f62d2c
1 Parent(s): 3274530

still attempting to get subset of games

Browse files
Files changed (1) hide show
  1. nba_tracking_data_15_16.py +2 -3
nba_tracking_data_15_16.py CHANGED
@@ -14,7 +14,6 @@
14
  # TODO: Address all TODOs and remove all explanatory comments
15
  """This is tracking data of the 2015-2016 NBA season"""
16
 
17
-
18
  import csv
19
  import json
20
  import os
@@ -45,8 +44,9 @@ res = requests.get(_URL)
45
 
46
  items = res.json()['payload']['tree']['items']
47
 
 
48
  _URLS = {}
49
- for game in items:
50
  name = game['name'][:-3]
51
  _URLS[name] = _URL + "/" + name + ".7z"
52
 
@@ -153,7 +153,6 @@ class NbaTracking(datasets.GeneratorBasedBuilder):
153
  # By default the archives will be extracted and a path to a cached folder where they are extracted is returned instead of the archive
154
  # urls = _URLS[self.config.name]
155
  urls = self._URLS # trying Ouwen's format
156
- urls = dict(list(urls.items())[0:1]) # quick test
157
  data_dir = dl_manager.download_and_extract(urls)
158
 
159
  all_file_paths = {}
 
14
  # TODO: Address all TODOs and remove all explanatory comments
15
  """This is tracking data of the 2015-2016 NBA season"""
16
 
 
17
  import csv
18
  import json
19
  import os
 
44
 
45
  items = res.json()['payload']['tree']['items']
46
 
47
+ # trying subset of games
48
  _URLS = {}
49
+ for game in items[0:3]:
50
  name = game['name'][:-3]
51
  _URLS[name] = _URL + "/" + name + ".7z"
52
 
 
153
  # By default the archives will be extracted and a path to a cached folder where they are extracted is returned instead of the archive
154
  # urls = _URLS[self.config.name]
155
  urls = self._URLS # trying Ouwen's format
 
156
  data_dir = dl_manager.download_and_extract(urls)
157
 
158
  all_file_paths = {}