napsternxg commited on
Commit
39c7f3b
1 Parent(s): d4abaff

Update nyt_ingredients.py

Browse files
Files changed (1) hide show
  1. nyt_ingredients.py +2 -2
nyt_ingredients.py CHANGED
@@ -107,11 +107,11 @@ class NYTIngredients(datasets.GeneratorBasedBuilder):
107
 
108
  def _split_generators(self, dl_manager):
109
  """Returns SplitGenerators."""
110
- data_dir = dl_manager.download_and_extract(_URLS)
111
  return [
112
  datasets.SplitGenerator(
113
  name=datasets.Split.TRAIN,
114
- gen_kwargs={"filepath": f"{data_dir['train']}/nyt-ingredients.crf.jsonl"},
115
  ),
116
  ]
117
 
 
107
 
108
  def _split_generators(self, dl_manager):
109
  """Returns SplitGenerators."""
110
+ downloaded_files = dl_manager.download_and_extract(_URLS)
111
  return [
112
  datasets.SplitGenerator(
113
  name=datasets.Split.TRAIN,
114
+ gen_kwargs={"filepath": downloaded_files["train"]},
115
  ),
116
  ]
117