jpcorb20 commited on
Commit
373bc02
1 Parent(s): 271e4fc

Update medical_wikipedia.py

Browse files
Files changed (1) hide show
  1. medical_wikipedia.py +2 -2
medical_wikipedia.py CHANGED
@@ -70,8 +70,8 @@ class MedWikiDataset(datasets.GeneratorBasedBuilder):
70
  def _split_generators(self, dl_manager):
71
  urls = _URLS[self.config.name]
72
  dataset = datasets.load_dataset(urls, "en", trust_remote_code=True, cache_dir="/Users/jcorbeil/Documents/datasets/TEMP")
73
- dl_manager.download_and_extract("https://huggingface.co/datasets/jpcorb20/medical_wikipedia/resolve/main/med_topics.csv")
74
- df = pd.read_csv(os.path.join(self.cache_dir, "med_topics.csv"))
75
  med_wiki_ids = set(df["wiki_id"].values.tolist())
76
  return [
77
  datasets.SplitGenerator(
 
70
  def _split_generators(self, dl_manager):
71
  urls = _URLS[self.config.name]
72
  dataset = datasets.load_dataset(urls, "en", trust_remote_code=True, cache_dir="/Users/jcorbeil/Documents/datasets/TEMP")
73
+ path = dl_manager.download_and_extract("https://huggingface.co/datasets/jpcorb20/medical_wikipedia/resolve/main/med_topics.csv")
74
+ df = pd.read_csv(path[0])
75
  med_wiki_ids = set(df["wiki_id"].values.tolist())
76
  return [
77
  datasets.SplitGenerator(