Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Panels Final #1232

Open
wants to merge 63 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
dc15485
Merge in 120V HPWH branch of OS-HPXML
jmaguire1 Apr 18, 2024
a60145e
Add 120V HPWH options, triggered by high UEF (COP is overwritten later)
jmaguire1 Apr 18, 2024
9e4751c
schedule based appliance and panel run update
Apr 18, 2024
28669c9
Update 120V HPWH option names to include shared circuit versions
jmaguire1 Apr 18, 2024
ad5bbd5
Fixed an issue with showers and how 120V is triggered
jmaguire1 Apr 18, 2024
7a9ae66
upgrades yml fileexit
Apr 19, 2024
04a08be
test run
Apr 19, 2024
c179914
utility
Apr 19, 2024
41ac090
conflict
Apr 19, 2024
4f4924d
test run
Apr 19, 2024
4882bc4
panel run
Apr 19, 2024
ac9e00f
panel run
Apr 19, 2024
04bf18a
Oops, our 65 gal HPWH was actually 66 gal
jmaguire1 Apr 25, 2024
a58466c
Merge branch 'panels_final' of https://github.com/NREL/resstock into …
jmaguire1 Apr 25, 2024
31a65d9
update bills State lookup
lixiliu Apr 29, 2024
39a9640
update national_upgrades yml for hpwh test run
lixiliu May 1, 2024
6e85b58
adjust Hot Water Fixtures by 1.125/0.86
lixiliu May 1, 2024
9a6eb0b
fix national_upg yml
lixiliu May 1, 2024
7203670
fix national_upg yml
lixiliu May 1, 2024
c42ff14
update thermal conduct in opt lkup
lixiliu May 1, 2024
adb2b53
sign change on unmet energy calcs for WHs
jmaguire1 May 3, 2024
ff8f565
Merge branch 'panels_final' of https://github.com/NREL/resstock into …
jmaguire1 May 3, 2024
0103da4
update yaml and bills to 2023
lixiliu May 6, 2024
641e741
add missing costs and lifetimes
lixiliu May 13, 2024
f6b5ac1
generate summary file
lixiliu May 15, 2024
b4dc6d2
update ref table gen
lixiliu Jun 8, 2024
83f9244
add reduce_files script
lixiliu Jun 14, 2024
081e451
mod note
lixiliu Jun 14, 2024
09790ee
add the cost multipliers into the baseline file
Jun 27, 2024
4d6914f
add the cost multipliers into the baseline file
Jun 27, 2024
66761e6
Add upgrade cost by category in postprocessing
Jul 18, 2024
03cafa1
Add upgrade cost by category in postprocessing
Jul 18, 2024
95a0864
failed building id
Jul 24, 2024
926fae0
new yml file for 19 upgrades
Jul 24, 2024
4bfc9f3
new yml file for 19 upgrades
Jul 24, 2024
c279180
extract model
Jul 26, 2024
d2da333
extract model
Jul 26, 2024
87a61d3
exttract model
Jul 29, 2024
810629e
model extraction
Aug 1, 2024
ebbc0ae
model extraction
Aug 1, 2024
95d0123
extract model
Aug 1, 2024
0113cee
extract model
Aug 1, 2024
7a414ad
model extraction
Aug 1, 2024
15413a2
model extraction
Aug 2, 2024
5528714
update up08 existing heating backup to use emergency bkup sizing
lixiliu Aug 7, 2024
963ea3e
cost update except hpwh
yingli-NREL Aug 7, 2024
b3e67ba
data postprocessing for new run
yingli-NREL Aug 7, 2024
0b2e114
existing backup
yingli-NREL Aug 9, 2024
2f11f38
Unit conversion for unmet showers. Before they were a rate/timestep, …
jmaguire1 Aug 12, 2024
c280a87
550k rerun
Aug 13, 2024
9619b07
120V appliancd
Aug 13, 2024
d393b1d
revert option_lookup change for 120V
lixiliu Aug 13, 2024
aebc9e0
update costs to Brennan file v3
lixiliu Aug 13, 2024
bc39c06
Fix low power (hpwh, dryer only) electrification packages
lixiliu Aug 13, 2024
0beaa9c
data postprocessing
Aug 20, 2024
befee7d
update generate_upgrade_ref_table
lixiliu Aug 22, 2024
8971efd
update scripts
lixiliu Sep 4, 2024
629bbe1
model extraction
Sep 4, 2024
cf94b53
new control
Sep 18, 2024
71f5eea
update remove vacant units file
lixiliu Sep 19, 2024
937daff
Merge branch 'panels_final' of github.com:NREL/resstock into panels_f…
lixiliu Sep 19, 2024
e784c33
update dashboard processing file
lixiliu Oct 15, 2024
71f0c36
final run
Nov 7, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
94,849 changes: 94,187 additions & 662 deletions measures/ApplyUpgrade/README.md

Large diffs are not rendered by default.

400,195 changes: 399,335 additions & 860 deletions measures/ApplyUpgrade/measure.xml

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions measures/ApplyUpgrade/resources/constants.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

class Constants
def self.NumApplyUpgradeOptions
return 25
return 60
end

def self.NumApplyUpgradesCostsPerOption
return 2
return 60
end

def self.CostMultiplierChoices
Expand Down
155 changes: 155 additions & 0 deletions measures/BuildExistingModel/measure.rb
Original file line number Diff line number Diff line change
Expand Up @@ -744,6 +744,161 @@ def run(model, runner, user_arguments)
end
end

#report sechedule
require 'csv'
schedule_csv_file_path = measures['BuildResidentialScheduleFile'][0]['output_csv_path']

# calculate the time that each value represent in hour
if File.exist?(schedule_csv_file_path)
@tmp_schedules = CSV.table(schedule_csv_file_path)
hour_each_value = 8760.0 / @tmp_schedules.length

cooking_range_max_value = nil
cooking_range_full_load_operation = 0
cooking_range_operation = 0
cooking_range_event_num = 0

dishwasher_max_value = nil
dishwasher_full_load_operation = 0
dishwasher_operation = 0
dishwasher_event_num = 0

clothes_washer_max_value = nil
clothes_washer_full_load_operation = 0
clothes_washer_operation = 0
clothes_washer_event_num = 0

clothes_dryer_max_value = nil
clothes_dryer_full_load_operation = 0
clothes_dryer_operation = 0
clothes_dryer_event_num = 0

#peak power
CSV.foreach(schedule_csv_file_path, headers: true) do |row|
cooking_range_column_value = row['cooking_range'].to_f
dishwasher_column_value = row['dishwasher'].to_f
clothes_washer_column_value = row['clothes_washer'].to_f
clothes_dryer_column_value = row['clothes_dryer'].to_f

if cooking_range_max_value.nil? || cooking_range_column_value > cooking_range_max_value
cooking_range_max_value = cooking_range_column_value
end

if dishwasher_max_value.nil? || dishwasher_column_value > dishwasher_max_value
dishwasher_max_value = dishwasher_column_value
end

if clothes_washer_max_value.nil? || clothes_washer_column_value > clothes_washer_max_value
clothes_washer_max_value = clothes_washer_column_value
end

if clothes_dryer_max_value.nil? || clothes_dryer_column_value > clothes_dryer_max_value
clothes_dryer_max_value = clothes_dryer_column_value
end
end

#number of events and operation hour
cooking_range_previous_row_value = nil
dishwasher_previous_row_value = nil
clothes_washer_previous_row_value = nil
clothes_dryer_previous_row_value = nil
CSV.foreach(schedule_csv_file_path, headers: true) do |row|
cooking_range_column_value = row['cooking_range'].to_f
dishwasher_column_value = row['dishwasher'].to_f
clothes_washer_column_value = row['clothes_washer'].to_f
clothes_dryer_column_value = row['clothes_dryer'].to_f

if cooking_range_previous_row_value.nil?
cooking_range_previous_row_value = cooking_range_column_value
else
if cooking_range_previous_row_value == 0 && cooking_range_column_value > 0
cooking_range_event_num += 1
end
end
cooking_range_previous_row_value = cooking_range_column_value
if cooking_range_column_value == cooking_range_max_value
cooking_range_full_load_operation += 1
end
if cooking_range_column_value > 0
cooking_range_operation += 1
end

if dishwasher_previous_row_value.nil?
dishwasher_previous_row_value = dishwasher_column_value
else
if dishwasher_previous_row_value == 0 && dishwasher_column_value > 0
dishwasher_event_num += 1
end
end
dishwasher_previous_row_value = dishwasher_column_value
if dishwasher_column_value == dishwasher_max_value
dishwasher_full_load_operation += 1
end
if dishwasher_column_value > 0
dishwasher_operation += 1
end

if clothes_washer_previous_row_value.nil?
clothes_washer_previous_row_value = clothes_washer_column_value
else
if clothes_washer_previous_row_value == 0 && clothes_washer_column_value > 0
clothes_washer_event_num += 1
end
end
clothes_washer_previous_row_value = clothes_washer_column_value
if clothes_washer_column_value == clothes_washer_max_value
clothes_washer_full_load_operation += 1
end
if clothes_washer_column_value > 0
clothes_washer_operation += 1
end

if clothes_dryer_previous_row_value.nil?
clothes_dryer_previous_row_value = clothes_dryer_column_value
else
if clothes_dryer_previous_row_value == 0 && clothes_dryer_column_value > 0
clothes_dryer_event_num += 1
end
end
clothes_dryer_previous_row_value = clothes_dryer_column_value
if clothes_dryer_column_value == clothes_dryer_max_value
clothes_dryer_full_load_operation += 1
end
if clothes_dryer_column_value > 0
clothes_dryer_operation += 1
end
end

#register outputs
cooking_range_full_load_operation_hour = (cooking_range_full_load_operation * hour_each_value).to_s
cooking_range_operation_hour = (cooking_range_operation * hour_each_value).to_s
cooking_range_event_num = (cooking_range_event_num).to_s
register_value(runner, 'cooking_range_full_load_operation_hour', cooking_range_full_load_operation_hour)
register_value(runner, 'cooking_range_operation_hour', cooking_range_operation_hour)
register_value(runner, 'cooking_range_event_num', cooking_range_event_num)

dishwasher_full_load_operation_hour = (dishwasher_full_load_operation * hour_each_value).to_s
dishwasher_operation_hour = (dishwasher_operation * hour_each_value).to_s
dishwasher_event_num = (dishwasher_event_num).to_s
register_value(runner, 'dishwasher_full_load_operation_hour', dishwasher_full_load_operation_hour)
register_value(runner, 'dishwasher_operation_hour', dishwasher_operation_hour)
register_value(runner, 'dishwasher_event_num', dishwasher_event_num)

clothes_washer_full_load_operation_hour = (clothes_washer_full_load_operation * hour_each_value).to_s
clothes_washer_operation_hour = (clothes_washer_operation * hour_each_value).to_s
clothes_washer_event_num = (clothes_washer_event_num).to_s
register_value(runner, 'clothes_washer_full_load_operation_hour', clothes_washer_full_load_operation_hour)
register_value(runner, 'clothes_washer_operation_hour', clothes_washer_operation_hour)
register_value(runner, 'clothes_washer_event_num', clothes_washer_event_num)

clothes_dryer_full_load_operation_hour = (clothes_dryer_full_load_operation * hour_each_value).to_s
clothes_dryer_operation_hour = (clothes_dryer_operation * hour_each_value).to_s
clothes_dryer_event_num = (clothes_dryer_event_num).to_s
register_value(runner, 'clothes_dryer_full_load_operation_hour', clothes_dryer_full_load_operation_hour)
register_value(runner, 'clothes_dryer_operation_hour', clothes_dryer_operation_hour)
register_value(runner, 'clothes_dryer_event_num', clothes_dryer_event_num)
end

# Copy existing.xml to home.xml for downstream HPXMLtoOpenStudio
# We need existing.xml (and not just home.xml) for UpgradeCosts
in_path = File.expand_path('../home.xml')
Expand Down
22 changes: 13 additions & 9 deletions project_national/national_baseline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,36 +3,40 @@ os_version: 3.7.0
os_sha: d5269793f1
buildstock_directory: ../ # Relative to this file or absolute
project_directory: project_national # Relative to buildstock_directory
output_directory: national_baseline
output_directory: model_extraction/upgrade6
weather_files_url: https://data.nrel.gov/system/files/156/Buildstock_TMY3_FIPS-1678817889.zip
# weather_files_path: c:/OpenStudio/BuildStock_TMY3_FIPS.zip

sampler:
type: residential_quota
type: precomputed
args:
n_datapoints: 250
sample_file: ../technoeconomic_analysis/Postprocessing/data_/upgrade_buildstock_csv/buildstock_30k_6_5.csv

workflow_generator:
type: residential_hpxml
args:
build_existing_model:
simulation_control_timestep: 60
simulation_control_timestep: 2
simulation_control_run_period_begin_month: 1
simulation_control_run_period_begin_day_of_month: 1
simulation_control_run_period_end_month: 12
simulation_control_run_period_end_day_of_month: 31
simulation_control_run_period_calendar_year: 2007

emissions:
- scenario_name: LRMER_MidCase_15
- scenario_name: LRMER_LowRECost_25
type: CO2e
elec_folder: data/emissions/cambium/2022/LRMER_MidCase_15
elec_folder: data/emissions/cambium/2022/LRMER_LowRECost_25
gas_value: 147.3
propane_value: 177.8
oil_value: 195.9

utility_bills:
- scenario_name: Bills
- scenario_name: Utility Rates - Fixed + Variable
simple_filepath: data/utility_bills/simple_rates/State.tsv

simulation_output_report:
timeseries_frequency: hourly
timeseries_frequency: timestep
include_timeseries_total_consumptions: true
include_timeseries_fuel_consumptions: true
include_timeseries_end_use_consumptions: true
Expand All @@ -56,7 +60,7 @@ workflow_generator:
retain_schedules_csv: false

baseline:
n_buildings_represented: 139647020 # American Community Survey 2021 5-year, B25001, does not include territories ( 138765649 without AK and HI )
n_buildings_represented: 140382740 # American Community Survey 2022 5-year, B25001, contiguous US + AK

eagle:
n_jobs: 3
Expand Down
Loading