Skip to content

SAM 2102 PV Sizing macro annual values issue - #2103

Merged
cpaulgilman merged 2 commits into
developfrom
sam-2102-pv-sizing-macro-annual
Sep 10, 2025
Merged

cpaulgilman merged 2 commits into
developfrom
sam-2102-pv-sizing-macro-annual

Conversation

@cpaulgilman

Copy link
Copy Markdown
Collaborator

Pull Request Template

Description

Fixes issues with PV system sizing macro:

  • Report average annual values of losses instead of total lifetime losses.
  • Add plot of annual inverter power limiting loss to show effect of degradation.
  • Fix handling of image files for plots to delete files when not needed, or store them with html file when HTML is exported.

Fixes #2102

Corresponding branches and PRs:

None

Unit Test Impact:

None

Checklist

  • requires help revision and I added that label
  • adds, removes, modifies, or deletes variables in existing compute modules
  • adds a new compute module
  • changes defaults
  • I've tagged this PR to a milestone

* Report average annual totals for clipping and power limiting losses -- note that SAM shows year 1 values, so macro results will differ from SAM results.
* Add graph showing annual inverter power limiting losses -- this is useful to show how losses decrease over time due to array DC degradation.
* Delete image files after displaying macro results window.
* Prompt for a folder for save to HTML option and save image files to same folder as HTML file to avoid files being saved in SAM application folder.
* Fix some minor HTML syntax issues.

Note that `cwd()` function from macro returns SAM application folder instead of folder containing .sam file.

Fixes #2102
Remove from PVWatts Wind Battery Hybrid folder -- macro requires Detailed PV model.
@cpaulgilman cpaulgilman self-assigned this Aug 19, 2025
@cpaulgilman cpaulgilman changed the title Sam 2102 pv sizing macro annual SAM 2102 PV Sizing macro annual values issue Aug 19, 2025
@brtietz

brtietz commented Sep 10, 2025

Copy link
Copy Markdown
Collaborator

@cpaulgilman are you sure this was based off of patch? This looks like it came from develop:

image

@cpaulgilman
cpaulgilman changed the base branch from patch to develop September 10, 2025 21:54
@cpaulgilman
cpaulgilman merged commit a667b8b into develop Sep 10, 2025
8 checks passed
@cpaulgilman
cpaulgilman deleted the sam-2102-pv-sizing-macro-annual branch September 10, 2025 21:54
@brtietz brtietz added this to the SAM 2026 Release milestone Jun 25, 2026
@cpaulgilman cpaulgilman added the added to release notes PR and/or issue has been added to release notes for a public release label Jun 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

added to release notes PR and/or issue has been added to release notes for a public release bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PV sizing macro power limiting losses issue

3 participants