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

RS/YJ/Rule 22-12 #1156

Merged
merged 5 commits into from
Oct 11, 2023
Merged

RS/YJ/Rule 22-12 #1156

merged 5 commits into from
Oct 11, 2023

Conversation

yunjoonjung-PNNL
Copy link
Collaborator

This rule was tested with Juan's TCD from PR #1155. I included the TCD here. Thanks!

Copy link
Collaborator

@weilixu weilixu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we do not need child class here, we will need to rewrite it.

if getattr_(heat_rejection_b, "heat_rejections", "loop")
in heat_rejection_loop_ids_b
]
)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Another way to do it could be:

number_of_baseline_heat_rejections_b = len(
            [
                heat_rejection_b
                for heat_rejection_b in find_all("$.heat_rejections[*]", rmd_b)
                if getattr_(heat_rejection_b, "heat_rejections", "loop")
                in heat_rejection_loop_ids_b
            ]
        )

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point! Addressed.

"number_of_baseline_heat_rejections_b": number_of_baseline_heat_rejections_b,
}

class HeatRejectionRule(RuleDefinitionBase):
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you need this nested class.
This can be done at the rule level.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good point! Addressed.

number_of_baseline_heat_rejections_b == 1
and len_heat_rejection_loop_ids_b > 1
):
FAIL_MSG = "There is more than one condenser loop for this building. There should only be one condenser loop attached to all chillers in the baseline chiller plant."
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should not be the building, but the project.

Let's update the message to:
"There is more than one condenser loop for this project. There should only be one condenser loop attached to all chillers in the baseline chiller plant."

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Addressed.

@weilixu weilixu merged commit f325d56 into develop Oct 11, 2023
2 checks passed
@yunjoonjung-PNNL yunjoonjung-PNNL deleted the RS/YJ/Rule_22-12 branch April 16, 2024 17:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants