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

Hybrids in PySAM #162

Merged
merged 16 commits into from
Mar 13, 2024
Merged

Hybrids in PySAM #162

merged 16 commits into from
Mar 13, 2024

Conversation

dguittet
Copy link
Collaborator

@dguittet dguittet commented Mar 13, 2024

Adds Hybrids models in Python via a Wrapper in Python, HybridBase and HybridSystem.

  • HybridSystem contains each technology and financial Module as properties for direct access
    • Defaults will be loaded into the appropriate Module (wrapped around HybridGenerator)
    • Each technology module will have separate data
    • All the financial modules will share data (from_existing)
    • During call to execute, all the inputs will be copied from the technology and financial modules into the Hybrid module. Then after simulation of the Hybrid module, all the inputs and outputs will be copied back out into each of the technology and financial modules
    • Each technology subsystem has a HybridCost group that contains the required cost inputs

Updates to PySSC

PySAM modules have get_data_ptr function that provides the pointer to the underlying ssc_data_t. Almost the opposite functionality of wrap except wrap takes over ownership of the data_ptr but get_data_ptr doesn't release ownership.

Add tests/test_hybrid.py that reproduces tests and results in NREL/ssc/ssc/tests

@dguittet dguittet merged commit b38e0f3 into dev Mar 13, 2024
0 of 15 checks passed
dguittet added a commit that referenced this pull request Mar 18, 2024
* Hybrids in PySAM (#162)

* add tests for updated PySSC

* add hybrids

* update hybrids and add tests

* remove set_data_ptr

* update ctypes and PySSC

* add yml for github actions CI

* update yml

* update yml

* update yml

* update yml

* update yml

* update yml

* update yml

* update yml

* remove hybrid_sandbox

* update files

* update test_hybrids

* update CI yml

* remove M1 mac test for now

* update test_pysam_all

* update test

* add back M1 mac test

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml

* fix mem leak in test_pyssc

* update yml for CI

* update build scripts

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml

* update test_pkg.yml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant