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

Update 223P Templates #225

Merged
merged 27 commits into from
Mar 10, 2023
Merged
Show file tree
Hide file tree
Changes from 5 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
d7ff0cd
update test, templates
gtfierro Feb 25, 2023
4d6d8dd
update templates + ontology
gtfierro Feb 25, 2023
b10f679
remove expected failure
gtfierro Feb 25, 2023
b920f0e
update tests, fix templates
gtfierro Feb 25, 2023
fef245b
update docs.conf from pylama
gtfierro Feb 25, 2023
ff0ed69
Merge branch 'develop' into gtf-update-223p-templates
TShapinsky Mar 1, 2023
63845ab
repo-visualizer [skip actions]
repo-visualizer Mar 1, 2023
978a171
Merge remote-tracking branch 'origin/develop' into gtf-update-223p-te…
gtfierro Mar 1, 2023
e540c4a
Merge branch 'gtf-update-223p-templates' of github.com:NREL/BuildingM…
gtfierro Mar 1, 2023
addfeba
repo-visualizer [skip actions]
repo-visualizer Mar 1, 2023
eed1a3d
repo-visualizer [skip actions]
repo-visualizer Mar 1, 2023
f832c58
add README
gtfierro Mar 2, 2023
fa3bef5
repo-visualizer [skip actions]
repo-visualizer Mar 2, 2023
2f33204
repo-visualizer [skip actions]
repo-visualizer Mar 3, 2023
ad9a8e7
try to fix docs build?
gtfierro Mar 3, 2023
d00db5d
Merge branch 'gtf-update-223p-templates' of github.com:NREL/BuildingM…
gtfierro Mar 3, 2023
b027e90
repo-visualizer [skip actions]
repo-visualizer Mar 3, 2023
033248f
chagne build dir?
gtfierro Mar 3, 2023
dd1234d
Merge branch 'gtf-update-223p-templates' of github.com:NREL/BuildingM…
gtfierro Mar 3, 2023
ea8e7e7
repo-visualizer [skip actions]
repo-visualizer Mar 3, 2023
a15530f
update to newer doc build
gtfierro Mar 3, 2023
d188c17
Merge branch 'gtf-update-223p-templates' of github.com:NREL/BuildingM…
gtfierro Mar 3, 2023
0f468ba
Merge remote-tracking branch 'origin/develop' into gtf-update-223p-te…
gtfierro Mar 9, 2023
f4e3455
repo-visualizer [skip actions]
repo-visualizer Mar 9, 2023
515e392
remove output.ttl
gtfierro Mar 9, 2023
23cf8cc
Merge branch 'gtf-update-223p-templates' of github.com:NREL/BuildingM…
gtfierro Mar 9, 2023
82e4593
repo-visualizer [skip actions]
repo-visualizer Mar 9, 2023
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
10 changes: 5 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@ repos:
hooks:
- id: pylama
- repo: https://github.com/psf/black
rev: 22.3.0
rev: 23.1.0
hooks:
- id: black
entry: black --check
- repo: https://github.com/pycqa/isort
rev: 5.10.1
rev: 5.12.0
hooks:
- id: isort
entry: isort --check
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v0.931
rev: v1.0.1
hooks:
- id: mypy
args: ["--install-types", "--non-interactive", "--ignore-missing-imports"]
additional_dependencies: [sqlalchemy2-stubs <= 0.0.2a20, SQLAlchemy <= 1.4]
exclude: docs/conf.py
additional_dependencies: [sqlalchemy2-stubs <= 0.0.2a32, SQLAlchemy < 2.0]
exclude: docs/conf.py
93 changes: 70 additions & 23 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,35 +4,82 @@
# re-generate this one.
###############################################################################
add_module_names = False
author = 'NREL'
autodoc_default_options = {'members': True, 'member-order': 'bysource', 'undoc-members': True, 'private-members': False}
author = "NREL"
autodoc_default_options = {
"members": True,
"member-order": "bysource",
"undoc-members": True,
"private-members": False,
}
autosummary_generate = True
bibtex_bibfiles = ['bibliography.bib']
comments_config = {'hypothesis': False, 'utterances': False}
copyright = '2022'
exclude_patterns = ['**.ipynb_checkpoints', '.DS_Store', 'Thumbs.db', '_build']
bibtex_bibfiles = ["bibliography.bib"]
comments_config = {"hypothesis": False, "utterances": False}
copyright = "2022"
exclude_patterns = ["**.ipynb_checkpoints", ".DS_Store", "Thumbs.db", "_build"]
execution_allow_errors = False
execution_excludepatterns = []
execution_in_temp = False
execution_timeout = 30
extensions = ['sphinx_togglebutton', 'sphinx_copybutton', 'myst_nb', 'jupyter_book', 'sphinx_thebe', 'sphinx_comments', 'sphinx_external_toc', 'sphinx.ext.intersphinx', 'sphinx_design', 'sphinx_book_theme', 'sphinx.ext.autodoc', 'sphinx.ext.autosummary', 'sphinx.ext.viewcode', 'sphinxcontrib.bibtex', 'sphinx_jupyterbook_latex']
extensions = [
"sphinx_togglebutton",
"sphinx_copybutton",
"myst_nb",
"jupyter_book",
"sphinx_thebe",
"sphinx_comments",
"sphinx_external_toc",
"sphinx.ext.intersphinx",
"sphinx_design",
"sphinx_book_theme",
"sphinx.ext.autodoc",
"sphinx.ext.autosummary",
"sphinx.ext.viewcode",
"sphinxcontrib.bibtex",
"sphinx_jupyterbook_latex",
]
external_toc_exclude_missing = False
external_toc_path = '_toc.yml'
html_baseurl = ''
html_favicon = ''
html_logo = ''
html_sourcelink_suffix = ''
html_theme = 'sphinx_book_theme'
html_theme_options = {'search_bar_text': 'Search this book...', 'launch_buttons': {'notebook_interface': 'classic', 'binderhub_url': 'https://mybinder.org', 'jupyterhub_url': '', 'thebe': False, 'colab_url': ''}, 'path_to_docs': 'docs', 'repository_url': 'https://github.com/NREL/BuildingMOTIF', 'repository_branch': 'main', 'google_analytics_id': '', 'extra_navbar': 'Powered by <a href="https://jupyterbook.org">Jupyter Book</a>', 'extra_footer': '', 'home_page_in_toc': True, 'announcement': '⚠️ This is an ALPHA release for testing purposes only ⚠️', 'use_repository_button': True, 'use_edit_page_button': False, 'use_issues_button': True}
html_title = 'BuildingMOTIF Documentation'
jupyter_cache = ''
jupyter_execute_notebooks = 'force'
latex_engine = 'pdflatex'
myst_enable_extensions = ['colon_fence', 'dollarmath', 'linkify', 'substitution', 'tasklist']
myst_url_schemes = ['mailto', 'http', 'https']
nb_output_stderr = 'show'
external_toc_path = "_toc.yml"
html_baseurl = ""
html_favicon = ""
html_logo = ""
html_sourcelink_suffix = ""
html_theme = "sphinx_book_theme"
html_theme_options = {
"search_bar_text": "Search this book...",
"launch_buttons": {
"notebook_interface": "classic",
"binderhub_url": "https://mybinder.org",
"jupyterhub_url": "",
"thebe": False,
"colab_url": "",
},
"path_to_docs": "docs",
"repository_url": "https://github.com/NREL/BuildingMOTIF",
"repository_branch": "main",
"google_analytics_id": "",
"extra_navbar": 'Powered by <a href="https://jupyterbook.org">Jupyter Book</a>',
"extra_footer": "",
"home_page_in_toc": True,
"announcement": "⚠️ This is an ALPHA release for testing purposes only ⚠️",
"use_repository_button": True,
"use_edit_page_button": False,
"use_issues_button": True,
}
html_title = "BuildingMOTIF Documentation"
jupyter_cache = ""
jupyter_execute_notebooks = "force"
latex_engine = "pdflatex"
myst_enable_extensions = [
"colon_fence",
"dollarmath",
"linkify",
"substitution",
"tasklist",
]
myst_url_schemes = ["mailto", "http", "https"]
nb_output_stderr = "show"
numfig = True
pygments_style = 'sphinx'
suppress_warnings = ['myst.domains']
pygments_style = "sphinx"
suppress_warnings = ["myst.domains"]
use_jupyterbook_latex = True
use_multitoc_numbering = True
24 changes: 8 additions & 16 deletions libraries/ashrae/223p/nrel-templates/connections.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,27 +34,19 @@ air-inlet-cp:
s223:hasMedium s223:Medium-Air .
optional: ["mapsto"]

system-air-outlet-cp:
body: >
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:OutletSystemConnectionPoint ;
s223:hasMedium s223:Medium-Air .

system-air-inlet-cp:
body: >
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:InletSystemConnectionPoint ;
s223:hasMedium s223:Medium-Air .


duct:
body: >
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Duct ;
s223:cnx P:a, P:b .
s223:hasMedium s223:Medium-Air ;
s223:connectsAt P:a, P:b .
# issue here is that 'connectsAt' requires a,b to be conn points
# but we can't instantiate that class directly *and* being a conn point
# involves other properties that must be included (e.g. hasmedium).
# TODO: how to solve this?
# P:a a s223:ConnectionPoint .
# P:b a s223:ConnectionPoint .
gtfierro marked this conversation as resolved.
Show resolved Hide resolved

zone-air-inlet-cp:
body: >
Expand Down
88 changes: 71 additions & 17 deletions libraries/ashrae/223p/nrel-templates/devices.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ damper:

P:name a s223:Damper ;
s223:hasProperty P:command, P:feedback ;
s223:cnx P:in, P:out .
s223:hasConnectionPoint P:in, P:out .
dependencies:
- template: air-inlet-cp
args: {"name": "in"}
Expand All @@ -22,7 +22,7 @@ fan:
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Fan ;
s223:hasProperty P:start-cmd, P:motor-status, P:oa-flow-switch ;
s223:cnx P:in, P:out .
s223:hasConnectionPoint P:in, P:out .
dependencies:
- template: air-inlet-cp
args: {"name": "in"}
Expand All @@ -41,7 +41,7 @@ filter:
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Filter ;
s223:hasProperty P:differential-pressure ;
s223:cnx P:in, P:out .
s223:hasConnectionPoint P:in, P:out .
dependencies:
- template: air-inlet-cp
args: {"name": "in"}
Expand All @@ -59,7 +59,7 @@ heat-recovery-coil:
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:HeatRecoveryCoil ;
s223:hasProperty P:entering-air-temp, P:leaving-air-temp, P:supply-water-temp, P:return-water-temp ;
s223:cnx P:air-in, P:air-out, P:water-in, P:water-out .
s223:hasConnectionPoint P:air-in, P:air-out, P:water-in, P:water-out .
dependencies:
- template: air-inlet-cp
args: {"name": "air-in"}
Expand All @@ -83,7 +83,7 @@ chilled-water-coil:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:CoolingCoil ;
s223:cnx P:air-in, P:air-out, P:water-in, P:water-out ;
s223:hasConnectionPoint P:air-in, P:air-out, P:water-in, P:water-out ;
s223:contains P:pump, P:valve ;
s223:hasProperty P:entering-air-temp, P:leaving-air-temp, P:supply-water-temp,
P:return-water-temp, P:leaving-air-wetbulb-temp .
Expand Down Expand Up @@ -116,7 +116,7 @@ hot-water-coil:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:HeatingCoil ;
s223:cnx P:air-in, P:air-out, P:water-in, P:water-out ;
s223:hasConnectionPoint P:air-in, P:air-out, P:water-in, P:water-out ;
s223:contains P:valve, P:supply-water-temp-sensor, P:return-water-temp-sensor ;
s223:hasProperty P:supply-water-temp, P:return-water-temp .
dependencies:
Expand Down Expand Up @@ -144,10 +144,10 @@ chw-pump:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Pump ;
s223:cnx P:in, P:out ;
s223:hasConnectionPoint P:in, P:out ;
s223:hasMedium s223:Water-ChilledWater ;
s223:hasProperty P:onoff-cmd, P:onoff-sts .
optional: ["in", "out"]
#optional: ["in", "out"]
dependencies:
- template: start-command
args: {"name": "onoff-cmd"}
Expand All @@ -163,10 +163,10 @@ hw-pump:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Pump ;
s223:cnx P:in, P:out ;
s223:hasConnectionPoint P:in, P:out ;
s223:hasMedium s223:Water-HotWater ;
s223:hasProperty P:onoff-cmd, P:onoff-sts .
optional: ["in", "out"]
#optional: ["in", "out"]
dependencies:
- template: start-command
args: {"name": "onoff-cmd"}
Expand All @@ -183,9 +183,14 @@ chw-valve:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Valve ;
s223:hasConnectionPoint P:in, P:out ;
s223:hasMedium s223:Water-ChilledWater ;
s223:hasProperty P:command, P:feedback .
dependencies:
- template: water-inlet-cp
args: {"name": "in"}
- template: water-outlet-cp
args: {"name": "out"}
- template: start-command
args: {"name": "command"}
- template: run-status
Expand All @@ -196,9 +201,14 @@ hw-valve:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Valve ;
s223:hasConnectionPoint P:in, P:out ;
s223:hasMedium s223:Water-HotWater ;
s223:hasProperty P:command, P:feedback .
dependencies:
- template: water-inlet-cp
args: {"name": "in"}
- template: water-outlet-cp
args: {"name": "out"}
- template: start-command
args: {"name": "command"}
- template: run-status
Expand All @@ -210,7 +220,7 @@ sensor:
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Sensor ;
s223:hasMeasurementLocation P:where ;
s223:observesProperty P:property .
s223:observes P:property .
optional: ["where"]

differential-sensor:
Expand All @@ -219,7 +229,7 @@ differential-sensor:
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:Sensor ;
s223:hasMeasurementLocation P:whereA, P:whereB ;
s223:observesProperty P:property .
s223:observes P:property .
optional: ["whereA", "whereB"]

evaporative-cooler:
Expand All @@ -228,16 +238,20 @@ evaporative-cooler:
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:HeatExchanger ;
s223:hasRole s223:HeatExchanger-Evaporator ;
s223:cnx P:in, P:out ;
s223:hasConnectionPoint P:in, P:out, P:water-in, P:water-out ;
s223:hasProperty P:entering-air-temp, P:leaving-air-temp, P:leaving-air-humidity ;
s223:contains P:evap-cool-pump-2stage, P:evap-cool-sump-tank, P:evap-cool-fill-valve .
P:in s223:hasProperty P:entering-air-temp .
P:out s223:hasProperty P:leaving-air-temp, P:leaving-air-humidity .
dependencies:
- template: air-outlet-cp
args: {"name": "in"}
- template: air-inlet-cp
args: {"name": "in"}
- template: air-outlet-cp
args: {"name": "out"}
- template: water-outlet-cp
args: {"name": "water-in"}
- template: water-inlet-cp
args: {"name": "water-out"}
- template: air-temperature
args: {"name": "entering-air-temp"}
- template: air-temperature
Expand All @@ -256,7 +270,7 @@ tank:
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
P:name a s223:Device ;
P:name a s223:Equipment ;
rdfs:label "Tank" .
# TODO: high-level and low-level statuses

Expand All @@ -268,7 +282,7 @@ heat-exchanger:
P:name a s223:HeatExchanger ;
s223:contains P:chw-flow-sensor, P:A-chw-diff-press-sensor,
P:B-chw-diff-press-sensor ;
s223:cnx P:A-in, P:A-out, P:B-in, P:B-out ;
s223:hasConnectionPoint P:A-in, P:A-out, P:B-in, P:B-out ;
s223:hasProperty P:A-chw-diff-press, P:B-chw-diff-press,
P:chw-supply-temperature,
P:chw-return-temperature, P:chw-flow .
Expand All @@ -287,6 +301,8 @@ heat-exchanger:
args: {"name": "B-chw-diff-press"}
- template: water-temperature
args: {"name": "chw-supply-temperature"}
- template: water-temperature
args: {"name": "chw-return-temperature"}
- template: water-flow
args: {"name": "chw-flow"}
- template: differential-sensor
Expand All @@ -295,3 +311,41 @@ heat-exchanger:
args: {"name": "B-chw-diff-press-sensor", "property": "B-chw-diff-press", "whereA": "B-in", "whereB": "B-out"}
- template: sensor
args: {"name": "chw-flow-sensor", "property": "chw-flow"}

fcu:
# TODO: add s223:FCU
body: >
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
P:name a s223:FCU ;
s223:contains P:fan, P:cooling-coil ;
s223:hasConnectionPoint P:in, P:out .
dependencies:
- template: chilled-water-coil
args: {"name": "cooling-coil"}
- template: fan
args: {"name": "fan"}
- template: air-outlet-cp
args: {"name": "out"}
- template: air-inlet-cp
args: {"name": "in"}

unit-heater:
body: >
@prefix P: <urn:___param___#> .
@prefix s223: <http://data.ashrae.org/standard223#> .
@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
P:name a s223:UnitHeater, s223:Equipment ;
rdfs:label "Unit Heater" ;
s223:contains P:fan, P:heating-coil ;
s223:hasConnectionPoint P:in, P:out .
dependencies:
- template: hot-water-coil
args: {"name": "heating-coil"}
- template: fan
args: {"name": "fan"}
- template: air-outlet-cp
args: {"name": "out"}
- template: air-inlet-cp
args: {"name": "in"}

Loading