Skip to content

Commit f4f57a7

Browse files
committed
read state from dataframe
1 parent 5ac2fd9 commit f4f57a7

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

01_data_sampling_example.ipynb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -161,6 +161,7 @@
161161
"source": [
162162
"# Only download 101 buildings for sampling purposes and testing this notebook/repo\n",
163163
"timeseries_to_download = df_sub.head(10)\n",
164+
"display(timeseries_to_download)\n",
164165
"print(f\"Downloading time series data for {len(timeseries_to_download)} buildings into {time_series_data_path}\")\n",
165166
"\n",
166167
"time_series_data_file_paths, building_ids = processor.process_building_time_series(\n",

comstock_processor.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ def download_task(row):
117117
return save_path, building_id
118118

119119
building_time_series_file = (
120-
f"{self.time_series_url}/by_state/upgrade={self.upgrade}/state={self.state}/{building_id}-{self.upgrade}.parquet"
120+
f"{self.time_series_url}/by_state/upgrade={self.upgrade}/state={row['in.state']}/{building_id}-{self.upgrade}.parquet"
121121
)
122122
self.download_file(building_time_series_file, save_path)
123123
return save_path, building_id

0 commit comments

Comments
 (0)