test relative path in download manager
Browse files
zillow.py
CHANGED
@@ -132,12 +132,15 @@ class NewDataset(datasets.GeneratorBasedBuilder):
|
|
132 |
# By default the archives will be extracted and a path to a cached folder where they are extracted is returned instead of the archive
|
133 |
# urls = _URLS[self.config.name]
|
134 |
# data_dir = dl_manager.download_and_extract(urls)
|
|
|
|
|
|
|
135 |
return [
|
136 |
datasets.SplitGenerator(
|
137 |
name=datasets.Split.TRAIN,
|
138 |
# These kwargs will be passed to _generate_examples
|
139 |
gen_kwargs={
|
140 |
-
"filepath":
|
141 |
"split": "train",
|
142 |
},
|
143 |
),
|
@@ -145,7 +148,7 @@ class NewDataset(datasets.GeneratorBasedBuilder):
|
|
145 |
name=datasets.Split.VALIDATION,
|
146 |
# These kwargs will be passed to _generate_examples
|
147 |
gen_kwargs={
|
148 |
-
"filepath":
|
149 |
"split": "dev",
|
150 |
},
|
151 |
),
|
@@ -153,7 +156,7 @@ class NewDataset(datasets.GeneratorBasedBuilder):
|
|
153 |
name=datasets.Split.TEST,
|
154 |
# These kwargs will be passed to _generate_examples
|
155 |
gen_kwargs={
|
156 |
-
"filepath":
|
157 |
"split": "test",
|
158 |
},
|
159 |
),
|
|
|
132 |
# By default the archives will be extracted and a path to a cached folder where they are extracted is returned instead of the archive
|
133 |
# urls = _URLS[self.config.name]
|
134 |
# data_dir = dl_manager.download_and_extract(urls)
|
135 |
+
file_train = dl_manager.download(os.path.join('data/home_value_forecasts/', "Metro_zhvf_growth_uc_sfrcondo_tier_0.33_0.67_month.csv"))
|
136 |
+
file_test = dl_manager.download(os.path.join(self.config.name, "test.csv"))
|
137 |
+
file_eval = dl_manager.download(os.path.join(self.config.name, "valid.csv"))
|
138 |
return [
|
139 |
datasets.SplitGenerator(
|
140 |
name=datasets.Split.TRAIN,
|
141 |
# These kwargs will be passed to _generate_examples
|
142 |
gen_kwargs={
|
143 |
+
"filepath": file_train, # os.path.join(data_dir, "train.jsonl"),
|
144 |
"split": "train",
|
145 |
},
|
146 |
),
|
|
|
148 |
name=datasets.Split.VALIDATION,
|
149 |
# These kwargs will be passed to _generate_examples
|
150 |
gen_kwargs={
|
151 |
+
"filepath": file_train, # os.path.join(data_dir, "dev.jsonl"),
|
152 |
"split": "dev",
|
153 |
},
|
154 |
),
|
|
|
156 |
name=datasets.Split.TEST,
|
157 |
# These kwargs will be passed to _generate_examples
|
158 |
gen_kwargs={
|
159 |
+
"filepath": file_train, # os.path.join(data_dir, "test.jsonl"),
|
160 |
"split": "test",
|
161 |
},
|
162 |
),
|