Skip to content

Conversation

@mjwitte
Copy link
Contributor

@mjwitte mjwitte commented Sep 12, 2024

Pull request overview

Pull Request Author

Add to this list or remove from it as applicable. This is a simple templated set of guidelines.

  • Title of PR should be user-synopsis style (clearly understandable in a standalone changelog context)
  • Label the PR with at least one of: Defect, Refactoring, NewFeature, Performance, and/or DoNoPublish
  • Pull requests that impact EnergyPlus code must also include unit tests to cover enhancement or defect repair
  • Author should provide a "walkthrough" of relevant code changes using a GitHub code review comment process
  • If any diffs are expected, author must demonstrate they are justified using plots and descriptions
  • If changes fix a defect, the fix should be demonstrated in plots and descriptions
  • If any defect files are updated to a more recent version, upload new versions here or on DevSupport
  • If IDD requires transition, transition source, rules, ExpandObjects, and IDFs must be updated, and add IDDChange label
  • If structural output changes, add to output rules file and add OutputChange label
  • If adding/removing any LaTeX docs or figures, update that document's CMakeLists file dependencies

Reviewer

This will not be exhaustively relevant to every PR.

  • Perform a Code Review on GitHub
  • If branch is behind develop, merge develop and build locally to check for side effects of the merge
  • If defect, verify by running develop branch and reproducing defect, then running PR and reproducing fix
  • If feature, test running new feature, try creative ways to break it
  • CI status: all green or justified
  • Check that performance is not impacted (CI Linux results include performance check)
  • Run Unit Test(s) locally
  • Check any new function arguments for performance impacts
  • Verify IDF naming conventions and styles, memos and notes and defaults
  • If new idf included, locally check the err file and other outputs

@mjwitte mjwitte added NewFeature Includes code to add a new feature to EnergyPlus NotIDDChange Code does not impact IDD (can be merged after IO freeze) labels Sep 12, 2024
@mjwitte mjwitte added this to the EnergyPlus 24.2 milestone Sep 12, 2024
@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit aaf7933

Regression Summary
  • ESO Big Diffs: 1

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 5631bbf

Regression Summary
  • ESO Big Diffs: 1

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit ce39eda

Regression Summary
  • Table Big Diffs: 2
  • ESO Big Diffs: 1

auto &spCLDayTS = state.dataOutRptTab->spCompLoads[iSpace - 1].day[state.dataSize->CurOverallSimDay - 1].ts[TimeStepInDay - 1];
gatherCompLoadIntGain2(state, spCLDayTS, state.dataHeatBal->space(iSpace).zoneNum, iSpace);
}
}
Copy link
Contributor

@rraustad rraustad Sep 21, 2024

Choose a reason for hiding this comment

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

I recall something about if space heat balance is active, then the zone HB results are overwritten with the sum of the spaces. If that's true then why bother processing the zones at all (line 9511) if those results are overwritten by 9516? Is line 9516 iSpace = 1 to NumOfZones, or 1 to numSpaces?

If (state.dataHeatBal->doSpaceHeatBalanceSizing) {
    gather spaces, 9516 to 9519
} else {
    gather zones, 9511 to 9514
}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That's possible. Baby steps at this point. Just trying to find all of the places that apply so that the space results are really just for the space.

Copy link
Contributor

Choose a reason for hiding this comment

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

@mjwitte you never answered "Is line 9516 iSpace = 1 to NumOfZones, or 1 to numSpaces?" and I still see that in develop.

I see it as line 8986 now. Should be 1 to NumOfSpaces?

        if (state.dataHeatBal->doSpaceHeatBalanceSizing) {
            for (int iSpace = 1; iSpace <= state.dataGlobal->NumOfZones; ++iSpace) {

Copy link
Contributor Author

Choose a reason for hiding this comment

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

for (int iSpace = 1; iSpace <= state.dataGlobal->NumOfZones;

@rraustad Yikes! This pasteo is in the code three times . . .
image

I'll open branch to fix this. Thanks for remembering this.

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 912635e

Regression Summary
  • Table Big Diffs: 2

Copy link
Contributor Author

@mjwitte mjwitte left a comment

Choose a reason for hiding this comment

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

Space component loads walkthru . . .

Comment on lines +2278 to +2289
for (int zoneNum = 1; zoneNum <= state.dataGlobal->NumOfZones; ++zoneNum) { // Start of zone loads report variable update loop ...
auto &zone = state.dataHeatBal->Zone(zoneNum);
auto &znAirRpt = state.dataHeatBal->ZnAirRpt(zoneNum);
auto &znEquipConfig = state.dataZoneEquip->ZoneEquipConfig(zoneNum);
reportAirHeatBal1(state, znAirRpt, znEquipConfig, zoneNum);
}
if (state.dataHeatBal->doSpaceHeatBalance) {
for (int spaceNum = 1; spaceNum <= state.dataGlobal->numSpaces; ++spaceNum) {
auto &spAirRpt = state.dataHeatBal->spaceAirRpt(spaceNum);
auto &spEquipConfig = state.dataZoneEquip->spaceEquipConfig(spaceNum);
int zoneNum = state.dataHeatBal->space(spaceNum).zoneNum;
reportAirHeatBal1(state, spAirRpt, spEquipConfig, zoneNum, spaceNum);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Break up ReportAirHeatBalance into smaller functions that can be re-used for zones and spaces.

Comment on lines -143 to -144
Array1D<Real64> MixSenLoad; // Mixing sensible loss or gain
Array1D<Real64> MixLatLoad; // Mixing latent loss or gain
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Moved to DataHeatBalance::AirReportVars.

// Following used for reporting
state.dataHeatBal->ZnAirRpt.allocate(state.dataGlobal->NumOfZones);
if (state.dataHeatBal->doSpaceHeatBalanceSimulation) {
if (state.dataHeatBal->doSpaceHeatBalance) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Hmm, this is wrong, should be doSpaceHeatBalanceSimulation || doSpaceHeatBalanceSizing. It might be ok, but not safe if sizing is false and simulation is true. Will fix.

Comment on lines 14744 to 14747
for (int iZoneGCLH = 1; iZoneGCLH <= state.dataGlobal->NumOfZones; ++iZoneGCLH) {
auto &znCompLoadDayTSZone = znCompLoadDayTS.spacezone[iZoneGCLH - 1];
auto &zoneAirRpt = state.dataHeatBal->ZnAirRpt(iZoneGCLH);
gatherSpaceZoneCompLoadsHVAC(znCompLoadDayTSZone, zoneAirRpt, state.dataHVACGlobal->TimeStepSysSec);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Another breakup into smaller functions.

int zoneNum = state.dataHeatBal->space(iSpace).zoneNum;
if (!state.dataZoneEquip->ZoneEquipConfig(zoneNum).IsControlled) continue;
if (allocated(state.dataSize->CalcFinalSpaceSizing)) {
computeSpaceZoneCompLoads(state,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This pattern repeats several times, called for either space of zone.

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 85bf54b

Regression Summary
  • Table Big Diffs: 5

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 7957607

Regression Summary
  • Table Big Diffs: 5

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit d8e14ca

Regression Summary
  • Table Big Diffs: 5

@Myoldmopar Myoldmopar self-assigned this Dec 4, 2024
@nrel-bot-2
Copy link

@Myoldmopar @mjwitte it has been 16 days since this pull request was last updated.

@nrel-bot-2
Copy link

@Myoldmopar @mjwitte it has been 7 days since this pull request was last updated.

1 similar comment
@nrel-bot-2
Copy link

@Myoldmopar @mjwitte it has been 7 days since this pull request was last updated.

@github-actions
Copy link

github-actions bot commented Jan 7, 2025

⚠️ Regressions detected on macos-14 for commit 760f08a

Regression Summary
  • Table Big Diffs: 5

@Myoldmopar
Copy link
Member

Pulled in develop to get the license year fixed. Everything is passing locally so I expect this to be back to what it was before with just a few table diffs. If so, I think this is probably ready to go in. Any final thoughts from @mjwitte or anyone else?

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit c3fc21c

Regression Summary
  • Table Big Diffs: 5

@mjwitte
Copy link
Contributor Author

mjwitte commented Jan 10, 2025

Pulled in develop to get the license year fixed. Everything is passing locally so I expect this to be back to what it was before with just a few table diffs. If so, I think this is probably ready to go in. Any final thoughts from @mjwitte or anyone else?

Nothing more from me.

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 41880e8

Regression Summary
  • Table Big Diffs: 5

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 66036d4

Regression Summary
  • Table Big Diffs: 5

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 6c63cb3

Regression Summary
  • Table Big Diffs: 5

@github-actions
Copy link

⚠️ Regressions detected on macos-14 for commit 892dd35

Regression Summary
  • Table Big Diffs: 5

@Myoldmopar
Copy link
Member

Fully happy still with latest develop, merging. Thanks @mjwitte !

@Myoldmopar Myoldmopar merged commit c33b4f0 into develop Feb 4, 2025
9 checks passed
@Myoldmopar Myoldmopar deleted the spaceCompLoads branch February 4, 2025 14:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Defect Includes code to repair a defect in EnergyPlus NewFeature Includes code to add a new feature to EnergyPlus NotIDDChange Code does not impact IDD (can be merged after IO freeze) Refactoring Includes code changes that don't change the functionality of the program, just perform refactoring

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Zone Component Loads Report may be incorrect when Zones and Enclosures are not the same

8 participants