Non-residential Efficiency Component

class aaem.components.non_residential.component.CommunityBuildings(community_data, forecast, diag=None, prerequisites={})[source]

Bases: aaem.components.annual_savings.annual_savings.AnnualSavings

Non-residential efficiency component of the Alaska Affordable Energy Model: This module estimates potential improvements in heating and electrical efficiency to non-residential buildings (commercial, education, health care, etc.). Consumption and savings are based on estimated square footage per building that may be retrofit and prices of fuels (electricity, biomass, diesel, etc.). The cost to retrofit each non-residential building is also calculated.

Parameters:

community_data : CommunityData

CommunityData Object for a community

forecast : Forecast

forecast for a community

diagnostics : diagnostics, optional

diagnostics for tracking error/warning messages

prerequisites : dictionary of components, optional

prerequisite component data this component has no prerequisites leave empty

See also

aaem.community_data
community data module, see information on CommintyData Object
aaem.forecast
forecast module, see information on Forecast Object
aaem.diagnostics
diagnostics module, see information on diagnostics Object

Attributes

diagnostics (diagnostics) for tracking error/warning messages initial value: diag or new diagnostics object
forecast (forecast) community forecast for estimating future values initial value: forecast
cd (dictionary) general data for a community. Initial value: ‘community’ section of community_data
comp_specs (dictionary) component specific data for a community. Initial value: ‘Non-Residential Buildings’ section of community_data

Methods

add_additional_buildings(num_not_heated=0)[source]

adds additional buildings to the building DataFrame (self.comp_specs[‘building inventory’]) if needed.

calc_annual_electric_savings(scalers)[source]

calculate annual electric savings created by the project

Attributes

baseline_kWh_cost (np.array) baseline cost ($/year)
proposed_kWh_cost (np.array) proposed cost ($/year)
annual_electric_savings (np.array) electric savings ($/year) are the difference in the base
and proposed fuel costs  
calc_annual_heating_savings()[source]

calculate annual heating savings created by the project

Attributes

baseline_HF_cost (np.array) baseline heating cost ($/year)
proposed_HF_cost (np.array) proposed heating cost ($/year)
annual_heating_savings (np.array) heating savings ($/year)
calc_baseline_HF_consumption()[source]

Calculate base line heating fuel consumption by type from known values and estimates(updates values for each building). Estimates are assumed to be from heating oil, except where natural gas is used.

Attributes

baseline_HF_consumption (float) total heating consumption (mmbtu/year)
baseline_fuel_Hoil_consumption (float) heating oil consumption for heating (gal/year)
baseline_fuel_hr_consumption (float) heat recovery consumption for heating (gal/year)
baseline_fuel_lng_consumption (float) natural gas consumption for heating (Mcf/year)
baseline_fuel_propane_consumption (float) propane consumption for heating (gal/year)
baseline_fuel_biomass_consumption (float) biomass consumption for heating (cords/year)
calc_baseline_kWh_consumption(scalers)[source]

calculate baseline electricity use from all buildings in community (or intertie) from measured values and estimates(updates values for each building)

Attributes

baseline_kWh_consumption (float) baseline electricity consumption (kWh/year).
calc_capital_costs()[source]

Calculate the capital costs. Taken as sum of known building refit costs and estimated refit costs (updates values for each building).

Attributes

capital_costs (float) total cost of improvements ($)
calc_proposed_HF_consumption()[source]

Calculate proposed HF consumption from known values and estimates(updates values for each building)

Attributes

proposed_HF_consumption (float) total heating consumption (mmbtu/year)
proposed_fuel_Hoil_consumption (float) heating oil consumption for heating (gal/year)
proposed_fuel_hr_consumption (float) heat recovery consumption for heating (gal/year)
proposed_fuel_lng_consumption (float) natural gas consumption for heating (Mcf/year)
proposed_fuel_propane_consumption (float) propane consumption for heating (gal/year)
proposed_fuel_biomass_consumption (float) biomass consumption for heating (cords/year)
calc_proposed_kWh_consumption()[source]

Calculate proposed electric consumption from known values and estimates(updates values for each building)

Attributes

proposed_kWh_consumption (float) (kWh/year)
calc_total_sqft_to_retrofit()[source]

estimates(updates values for each building) building square footage were needed, and total calculate retrofit square feet.

Attributes

total_sqft_to_retrofit (float) sum of all building square footage
get_fuel_total_saved()[source]

get total fuel saved

Returns:

float

the total fuel saved in gallons

get_total_energy_produced()[source]

get total energy produced

Returns:

dict

electric ‘kWh’, and heating ‘MMBtu’ savings keys with tuple

(savings, % of energy used) values

run(scalers={'kWh consumption': 1.0, 'capital costs': 1.0}, calc_sqft_only=False, for_prereq=False)[source]

runs the component. The Annual Total Savings,Annual Costs, Annual Net Benefit, NPV Benefits, NPV Costs, NPV Net Benefits, Benefit Cost Ratio, Levelized Cost of Energy, and Internal Rate of Return will all be calculated. There must be a known Heat Recovery project for this component to run.

Parameters:

scalers: dictionary of valid scalers, optional

Scalers to adjust normal run variables. See note on accepted scalers

Notes

Accepted scalers: capital costs.

Attributes

run (bool) True in the component runs to completion, False otherwise
reason (string) lists reason for failure if run == False
save_additional_output(path)[source]

save additional out put for component

Parameters:

path : path

location to save files at

save_building_summary(file_name)[source]

save building summary for community

Parameters:

file_name: path

name of file to save (.csv)

update_num_buildings()[source]

This function compares the counted buildings with the estimated buildings

Attributes

num_buildings (int) # buildings estimated
additional_buildings (int) difference in estimated buildings as # in inventory

Non-residential Efficiency configuration

Contains configuration info for community data yaml file, and
other set-up requirements

Non-Residential Efficiency inputs

input functions for Non-Residential Efficiency component

aaem.components.non_residential.inputs.load_building_data(data_dir)

Load building inventory data from community_buildings.csv

Parameters:

data_dir: path

path to data directory for community

Returns:

DataFrame

data from inventory

aaem.components.non_residential.inputs.load_building_estimates(data_dir)

load consumption estimates

Parameters:

data_dir: path

path to data directory for community

Returns:

DataFrame

estimate data

aaem.components.non_residential.inputs.load_num_buildings(data_dir)

load estimated # of buildings in community

Parameters:

data_dir: path

path to data directory for community

Returns:

int

number of buildings

Non-residential Efficiency outputs

output functions for Non-residential Efficiency component

aaem.components.non_residential.outputs.communities_summary(coms, res_dir)[source]

Saves the summary by: community non-residential_building_summary.csv

Parameters:

coms : dictionary

results from the model, dictionary with each community or project as key

res_dir : path

location to save file

aaem.components.non_residential.outputs.component_summary(results, res_dir)[source]

Creates the regional and communities summary for the component in provided

directory

Parameters:

results : dictionary

results from the model, dictionary with each community or project as key

res_dir : path

location to save file

aaem.components.non_residential.outputs.create_regional_summary(results)[source]

Creates the regional summary

Parameters:

results : dictionary

results from the model, dictionary with each community or project as key

Returns:

DataFrame

containing regional results

aaem.components.non_residential.outputs.save_regional_summary(summary, res_dir)[source]

Saves the summary by region

Parameters:

summary : DataFrame

compiled regional results

res_dir : path

location to save file

Non-Residential Efficiency preprocessing

preprocessing functions for Non-residential Efficiency component

aaem.components.non_residential.preprocessing.get_building_inventory(community, data_dir, diagnostics, **kwargs)[source]

load the building inventory

Parameters:

community: list

list of community ids (community names)

data_dir: path

path to datafile

diagnostics: Diagnostics

diagnostics object

Returns:

DataFrame

building inventory

aaem.components.non_residential.preprocessing.get_consumption_estimates(data_dir, population, diagnostics)[source]

Get consumption estimates

Parameters:

data_dir: path

path to datafile

population: int

population size for estimates

diagnostics: Diagnostics

diagnostics object

Returns:

DataFrame

estimate data

aaem.components.non_residential.preprocessing.get_number_buildings(community, data_dir, diagnostics)[source]

Load # buildings from file

Parameters:

community: list

list of community ids (community names)

data_dir: path

path to data file

diagnostics: Diagnostics

diagnostics object

Returns:

int:

# buildings in community

aaem.components.non_residential.preprocessing.preprocess(preprocessor, **kwargs)[source]

Preprocess Non-residential data

Parameters:

preprocessor: aaem.preprocessor.Preprocessor object

Returns:

dict

data for component configuration