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

Expand 90.1 Lighting data #51

Merged
merged 6 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
1,062 changes: 1,062 additions & 0 deletions building_energy_standards_data/database_files/level_2_lighting_space_types.json

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

2,482 changes: 2,482 additions & 0 deletions building_energy_standards_data/database_files/level_3_lighting_90_1_2022.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions building_energy_standards_data/database_tables/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
"hvac_minimum_requirement_furnaces_90_1",
"hvac_minimum_requirement_furnaces_90_1_prm",
"hvac_minimum_requirement_furnaces_IECC",
"level_3_lighting_90_1_2022",
"level_3_lighting_90_1_2019",
"level_3_lighting_90_1_2016",
"level_3_lighting_90_1_2013",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
import sqlite3

from building_energy_standards_data.database_tables.level_3_lighting_90_1_definition import (
LightDef901,
)

TABLE_NAME = "level_3_lighting_90_1_2022"


class LightDef9012022Table(LightDef901):
def __init__(self):
super(LightDef9012022Table, self).__init__(
table_name=TABLE_NAME,
initial_data_directory=f"building_energy_standards_data/database_files/{TABLE_NAME}",
)
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,10 @@
method: [BA, CS, SS]
lighting_primary_space_type: TEXT
lighting_secondary_space_type: TEXT
lighting_per_area: REAL
lighting_power_density: REAL
lighting_power_density_unit: TEXT
supplemental_lighting_power_density: REAL
supplemental_lighting_power_density_unit: TEXT
rcr_threshold: NUMERIC
automatic_daylight_responsive_controls_for_sidelighting: TEXT
automatic_daylight_responsive_controls_for_toplighting: TEXT
Expand All @@ -30,6 +32,8 @@
lighting_secondary_space_type TEXT,
lighting_power_density NUMERIC NOT NULL,
lighting_power_density_unit TEXT DEFAULT 'w/ft2' NOT NULL,
supplemental_lighting_power_density NUMERIC,
supplemental_lighting_power_density_unit TEXT,
rcr_threshold NUMERIC,
automatic_daylight_responsive_controls_for_sidelighting TEXT,
automatic_daylight_responsive_controls_for_toplighting TEXT,
Expand All @@ -47,6 +51,8 @@
lighting_secondary_space_type,
lighting_power_density,
lighting_power_density_unit,
supplemental_lighting_power_density,
supplemental_lighting_power_density_unit,
rcr_threshold,
automatic_daylight_responsive_controls_for_sidelighting,
automatic_daylight_responsive_controls_for_toplighting,
Expand All @@ -55,7 +61,7 @@
scheduled_shutoff,
annotation
)
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?);
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?);
"""

RECORD_TEMPLATE = {
Expand All @@ -64,6 +70,8 @@
"lighting_secondary_space_type": "",
"lighting_power_density": 0.0,
"lighting_power_density_unit": "W/ft2",
"supplemental_lighting_power_density": 0.0,
"supplemental_lighting_power_density_unit": "W/ft2",
"rcr_threshold": 0.0,
"automatic_daylight_responsive_controls_for_sidelighting": "",
"automatic_daylight_responsive_controls_for_toplighting": "",
Expand Down Expand Up @@ -116,6 +124,8 @@ def _preprocess_record(self, record):
getattr_either("lighting_secondary_space_type", record),
getattr_either("lighting_power_density", record),
getattr_either("lighting_power_density_unit", record, "W/ft2"),
getattr_either("supplemental_lighting_power_density", record),
getattr_either("supplemental_lighting_power_density_unit", record, "W/ft2"),
getattr_either("rcr_threshold", record),
getattr_either(
"automatic_daylight_responsive_controls_for_sidelighting", record
Expand Down
Loading