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

Pyomo doe refactor #3317

Merged
merged 203 commits into from
Aug 19, 2024
Merged
Changes from 1 commit
Commits
Show all changes
203 commits
Select commit Hold shift + click to select a range
e32f29e
Adding new DoE object and skeleton functions
djlaky Jun 20, 2024
c7a4da0
Refactoring scenario generation
djlaky Jun 20, 2024
6631c48
Further progress on generating FD scenarios
djlaky Jun 20, 2024
9535062
Scenario generator appears to work
djlaky Jun 20, 2024
ea1b2d6
Added a check_model_labels function
djlaky Jun 25, 2024
caa1949
Cleaned and standardized scenario generation
djlaky Jun 25, 2024
37e554b
Fixed forward and backward case for scenario generation
djlaky Jun 25, 2024
125ce85
More cleanup
djlaky Jun 25, 2024
5ba9576
Removed unnecessary function
djlaky Jun 25, 2024
e5d62f3
Updating create model
djlaky Jun 25, 2024
097638d
Added comment
djlaky Jun 25, 2024
1379aba
Added checks for input FIM, jacobian, labels
djlaky Jun 26, 2024
bb26bdf
Update Jacobian representation
djlaky Jun 26, 2024
258ebfd
Added functionality for incoming block-models
djlaky Jun 26, 2024
b13826c
Slight language update for readability
djlaky Jun 26, 2024
c2ffbe5
Slight cleaning
djlaky Jun 26, 2024
516d52c
Updating refactor test functions
djlaky Jun 26, 2024
0644b02
Small typo fix in create_doe_model
djlaky Jun 27, 2024
51026f7
Create objective functionadded
djlaky Jul 1, 2024
c3247e3
Blank space removal
djlaky Jul 1, 2024
4ed74f3
Moved most attributes to constructor
djlaky Jul 1, 2024
7defa33
Updating example to compare against old code
djlaky Jul 1, 2024
bf81b6c
Updated run_doe to perform experimental design
djlaky Jul 1, 2024
eb08ba7
Added FIM prior update function
djlaky Jul 2, 2024
d5a9dbc
Started adding full factorial exploration function.
djlaky Jul 2, 2024
e050d4e
Adding kaug functionality to new interface
djlaky Jul 2, 2024
7e37cc2
Fixed k_aug method for new interface
djlaky Jul 2, 2024
4930c95
Simplified kaug method and added obj cons block
djlaky Jul 3, 2024
2f4c5bd
Added compute_FIM method
djlaky Jul 3, 2024
f136602
Added description for rescale_FIM
djlaky Jul 3, 2024
fc6cbac
Made compute_FIM more flexible
djlaky Jul 3, 2024
5592723
Added full factorial design space exploration
djlaky Jul 3, 2024
5dd133c
Fixed Cholesky bug, added L initiailization
djlaky Jul 4, 2024
6724fbe
Added small check for FIM rescaling function
djlaky Jul 5, 2024
d98ce6a
Added sequential compute_FIM method.
djlaky Jul 5, 2024
45ba264
Merge branch 'Pyomo:main' into pyomo-doe-refactor
djlaky Jul 5, 2024
1b9b08f
Updated grid search
djlaky Jul 5, 2024
14ee132
Made the full factorial return the data structure
djlaky Jul 5, 2024
e2f16d0
Added results object
djlaky Jul 5, 2024
08a9630
Fixed bug in sequential compute FIM
djlaky Jul 6, 2024
5ba54c8
Refactored factorial design plotting function
djlaky Jul 6, 2024
16aa150
Small updates on results and objective naming
djlaky Jul 10, 2024
0822e0d
Removing deprecated code
djlaky Jul 11, 2024
18e3bd2
Updated init.py to remove deprecated dependencies
djlaky Jul 11, 2024
f46f06d
Updated variable names to be more readable
djlaky Jul 11, 2024
2476c3b
Updated test file with naming changes
djlaky Jul 11, 2024
9a71ad7
Added more results data
djlaky Jul 11, 2024
4c50c64
Removed stale imports, updated ordering
djlaky Jul 11, 2024
43ae0ba
Ran Black
djlaky Jul 11, 2024
37e3899
Removing old files
djlaky Jul 11, 2024
936cc4c
Removing more files
djlaky Jul 11, 2024
3e8c5e0
Wrote solving tests
djlaky Jul 11, 2024
53384ae
Adding placeholder files for other tests
djlaky Jul 11, 2024
25753d4
Added checks that FIM, Q, and L are consistent after solve
djlaky Jul 12, 2024
cdebfe9
Added build testing functions
djlaky Jul 12, 2024
a751f96
Ran Black
djlaky Jul 12, 2024
ea528eb
Added user initialization check, Ran Black
djlaky Jul 12, 2024
85d116a
Merge branch 'Pyomo:main' into pyomo-doe-refactor
djlaky Jul 12, 2024
1113b67
Delete pyomo/contrib/doe/tests/test_reactor_example.py
djlaky Jul 12, 2024
7d5c562
Delete pyomo/contrib/doe/tests/test_example.py
djlaky Jul 12, 2024
7a9e0c9
Delete pyomo/contrib/doe/tests/test_fim_doe.py
djlaky Jul 12, 2024
ccc0be6
Corrected flags and added new test file for model building
djlaky Jul 12, 2024
31ede58
Added some error tests
djlaky Jul 12, 2024
a66bd62
Updated model to have good imports
djlaky Jul 12, 2024
fe74e73
Updated all asserts to be raises; Added tests
djlaky Jul 12, 2024
da285a9
Delete pyomo/contrib/doe/redesign directory
djlaky Jul 12, 2024
fa1615d
Ran Black
djlaky Jul 12, 2024
6871ba6
Fixed small typo
djlaky Jul 12, 2024
4a341f6
Delete pyomo/contrib/doe/examples/PyomoDoE-plots.ipynb
djlaky Jul 12, 2024
3ec88c0
Delete pyomo/contrib/doe/examples/debugging_compute_FIM.ipynb
djlaky Jul 12, 2024
de535f4
Delete pyomo/contrib/doe/examples/reactor_optimize_doe_DJL.py
djlaky Jul 12, 2024
c8ef2dd
Ran Black
djlaky Jul 12, 2024
65519e2
Merge branch 'pyomo-doe-refactor' of https://github.com/djlaky/pyomo …
djlaky Jul 12, 2024
5c89e4a
Ran Black with correct command with flags
Jul 15, 2024
8bbf084
Fixed typos
Jul 15, 2024
615329d
Ran Black again
Jul 15, 2024
5c82a57
Fixed another typo
Jul 15, 2024
d13f94b
Removing commented lines from example files
Jul 15, 2024
0625cec
Added ipopt check for build, which initializes the model using ipopt
Jul 15, 2024
ae34d07
Merge branch 'main' into pyomo-doe-refactor
mrmundt Jul 17, 2024
7670063
Added test for rescale FIM function
Jul 18, 2024
7ad1005
Fixed bug and added test for compute FIM seq with back/forw
Jul 18, 2024
2b645c7
Adding test for model that is poorly posed
Jul 18, 2024
f1ae5df
Ran Black
Jul 18, 2024
ce4d04c
Updated main
Jul 18, 2024
858aafc
Added tests for update_FIM
Jul 18, 2024
2555900
Add update_FIM error check
Jul 18, 2024
ca32fc5
Added tests for get values functions without blocks
Jul 18, 2024
5864e68
Adding tests for multi experiment not implemented and scenario buildi…
Jul 18, 2024
11af005
Adding tests for bad FD values
Jul 18, 2024
ae9d288
Added tests for bad objective builds
Jul 18, 2024
06a0f50
Changed one run to use objective type
Jul 18, 2024
cc4eec0
Added not implemented error for unknown parameter value updating
Jul 18, 2024
a389d4f
Delete pyomo/contrib/doe/examples directory
djlaky Jul 18, 2024
e6feef6
Add test for bad option in compute FIM method
Jul 18, 2024
f1df9be
Removed bad files, have to rewrite OnlineDocs soon
Jul 18, 2024
76e06c5
Fixed determinant obj without cholesky, added tests.
Jul 18, 2024
fe60179
Merge branch 'main' into pyomo-doe-refactor
mrmundt Jul 22, 2024
930ac20
Added scipy availability flag for kaug test
djlaky Jul 23, 2024
33121af
Fixed typo
djlaky Jul 23, 2024
9b0d416
Started updating documentation (doe.rst).
djlaky Jul 23, 2024
08884e3
Updated ParmEst reference
djlaky Jul 23, 2024
29d8d43
Fixed typo in doe.rst
djlaky Jul 23, 2024
3e3bfc5
Merge branch 'Pyomo:main' into pyomo-doe-refactor
djlaky Jul 23, 2024
f7b5f57
Added examples and figure saving capabilities
Jul 23, 2024
3211d4d
Fixed documentation, cleaned example files
Jul 23, 2024
462a75a
Fixing literalinclude statements
Jul 23, 2024
087eaad
Fixing literalinclude statements again
Jul 23, 2024
328bc83
Added examples to init
Jul 24, 2024
e3a00cf
Added missing init file
Jul 24, 2024
070ab31
Add experiment and result json file for examples
djlaky Jul 24, 2024
45b7f87
Add Pyomo disclaimer and clean examples codes
djlaky Jul 24, 2024
b203356
Added Pyomo statement to test files
djlaky Jul 24, 2024
52557f2
Add more Pyomo statements to test files
djlaky Jul 24, 2024
24c4d6e
Updated test files to use experiment class, Ran Black
djlaky Jul 24, 2024
834088f
Updated documentation with recent changes
djlaky Jul 24, 2024
b5992ec
Updated documentation typo
djlaky Jul 31, 2024
735c932
Adding functionality to use Params instead of Vars
djlaky Aug 2, 2024
f038bc2
Commented out new Param to Var code
djlaky Aug 2, 2024
087e7be
ran black and typos
Aug 2, 2024
e2e469b
Revert reactor experiment for update
djlaky Aug 5, 2024
ce6d92e
Updated experiment to be inherited from `parmest`
djlaky Aug 5, 2024
4d23cd8
Update experiment inputs key as None
djlaky Aug 5, 2024
19251d5
Simplify component identification in doe
djlaky Aug 5, 2024
e097811
Update variable fixing readability in doe
djlaky Aug 5, 2024
73140d8
Change setattr to add_component
djlaky Aug 5, 2024
96b0a99
Update import order
djlaky Aug 5, 2024
4679cb7
Added unique component naming if model is provided
djlaky Aug 5, 2024
20e5ae6
Added unique block addition to user models for doe tasks
djlaky Aug 5, 2024
c06bfa5
Fixed potential bug
djlaky Aug 5, 2024
cba2b47
Made L_LB more verbose
djlaky Aug 5, 2024
93706d0
Updated ``det`` to be more verbose
djlaky Aug 5, 2024
c36cedb
Made ``args`` more verbose
djlaky Aug 5, 2024
ddc8ec8
Added naming map for results object
djlaky Aug 5, 2024
2c22203
Updated import order for test files
djlaky Aug 5, 2024
c2967cd
Remove stale Enum structures
djlaky Aug 5, 2024
383cbc7
Ran black and typos
Aug 5, 2024
c28d103
Clean up init file
Aug 7, 2024
52433f4
Updating example with feedback
Aug 7, 2024
678b28d
Made imports explicit
Aug 9, 2024
1920965
Made imports explicit in other tests
Aug 9, 2024
afd01bb
Added shortcut function for test arguments
Aug 9, 2024
b66a6c5
Simplified decorator to class
Aug 9, 2024
c6aafd2
Cleaned up reactor experiment example
Aug 12, 2024
b8b911c
Added else to rescale function, commented params function
Aug 12, 2024
a9b1b03
Edited language in documentation
Aug 12, 2024
9d5fa4c
Fixed fragile line numbers for reactor exp in documentation
Aug 12, 2024
8d95492
Clarified text in documentation
Aug 12, 2024
26921e0
Remove more line number fragility in documentation
Aug 12, 2024
9462cee
Combined example files and updated documentation with change
Aug 12, 2024
77a1bc5
Add context manager, remove np.isclose in tests
Aug 12, 2024
ef5c9ba
Reused reactor experiment in tests, fixed bug in experiment
Aug 12, 2024
353e769
Edited small phrase in documentation
Aug 12, 2024
b2106a0
Removing unused import
Aug 12, 2024
16873d0
Remove tests result.json dependency
Aug 12, 2024
2b2c33f
Delete pyomo/contrib/doe/tests/experiment_class_example.py
djlaky Aug 12, 2024
c18f2c6
Delete pyomo/contrib/doe/tests/result.json
djlaky Aug 12, 2024
cb7d925
Delete pyomo/contrib/doe/experiment.py
djlaky Aug 12, 2024
e0226b0
Update pyomo/contrib/doe/tests/test_doe_build.py
djlaky Aug 12, 2024
27ed006
Revert "Update pyomo/contrib/doe/tests/test_doe_build.py"
djlaky Aug 12, 2024
451fdff
Revert "Delete pyomo/contrib/doe/tests/experiment_class_example.py"
djlaky Aug 12, 2024
514a032
Revert "Delete pyomo/contrib/doe/tests/result.json"
djlaky Aug 12, 2024
d078c4f
Revert "Delete pyomo/contrib/doe/experiment.py"
djlaky Aug 12, 2024
a8957a5
Removed string-based location of components
Aug 12, 2024
3f57d1c
Updated shoddy tests to check real values
Aug 12, 2024
e0c9a0b
Added depracation error message
Aug 12, 2024
2bb20b1
resolving merge conflict
djlaky Aug 12, 2024
a4d25c2
Fixed typo in doe.py
djlaky Aug 12, 2024
e78842a
Delete pyomo/contrib/doe/tests/test_example.py
djlaky Aug 12, 2024
b036e26
Delete pyomo/contrib/doe/tests/test_fim_doe.py
djlaky Aug 12, 2024
c5a4301
Delete pyomo/contrib/doe/tests/test_reactor_example.py
djlaky Aug 12, 2024
8ec6500
Delete pyomo/contrib/doe/tests/experiment_class_example.py
djlaky Aug 12, 2024
f6c3fcb
Delete pyomo/contrib/doe/tests/result.json
djlaky Aug 12, 2024
31f93e5
Delete pyomo/contrib/doe/experiment.py
djlaky Aug 12, 2024
4e771ec
Remove idaes import from documentation
djlaky Aug 13, 2024
94e981d
Update solving test file to have assertFoo
djlaky Aug 13, 2024
324146d
Moved has numpy decorator to class level
djlaky Aug 13, 2024
9c52690
Updated language in comments and URL
djlaky Aug 13, 2024
d8307a7
Removed safe naming for later discussion
djlaky Aug 13, 2024
ec93a2b
Added solver safeguarding TODO
djlaky Aug 13, 2024
3541460
Added TODOs and added error to unreachable code
djlaky Aug 13, 2024
b2899fb
Fixed out of scope 'model' references
djlaky Aug 13, 2024
137572a
Fixed more out of scope `model` references
djlaky Aug 13, 2024
b067bd1
Fixed check model labels function
djlaky Aug 13, 2024
f71d4c7
Added missing docstring inputs
djlaky Aug 13, 2024
08e6618
Added TODO for solve failure message on user model
djlaky Aug 13, 2024
fdd0583
Ran Black
djlaky Aug 13, 2024
1b9729a
Added more verbose TODO tasks
djlaky Aug 13, 2024
57a8a81
Delete .vs directory
djlaky Aug 13, 2024
0b08aef
Remove other user-defined model unique naming
djlaky Aug 13, 2024
7aab583
Revert accidental find and replace in tests
djlaky Aug 13, 2024
b1214a7
Updated documentation comment to be more verbose
djlaky Aug 13, 2024
6db5023
Change assertTrue to assertEqual in test build
djlaky Aug 13, 2024
0c566c9
Change assertTrue to assertEqual in test solve
djlaky Aug 13, 2024
485e0fc
Update test file with os.path and pyomo.fileutils
djlaky Aug 13, 2024
919f234
Moving deprecation error away from doe.py
djlaky Aug 13, 2024
ca1f39e
Add comments to tests that don't assert anything
djlaky Aug 14, 2024
f4ff8b7
Ran Black
djlaky Aug 14, 2024
fc00af0
Added deprecation warning/error for old interface
djlaky Aug 14, 2024
24bd55e
Remove URL for URL checker for now
djlaky Aug 14, 2024
ecc24bf
Reverting previous change.
djlaky Aug 14, 2024
6505f5b
Add solve to help with initialization of DoE model
djlaky Aug 16, 2024
3af9d47
Merge branch 'Pyomo:main' into pyomo-doe-refactor
djlaky Aug 16, 2024
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
3 changes: 2 additions & 1 deletion pyomo/contrib/doe/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"objects that label unknown parameters, experiment inputs, experiment outputs "
"and measurement error. This avoids string-based naming which is fragile. For "
"instructions to use the new interface, please see the Pyomo.DoE under the contributed "
"packages documentation at `https://pyomo.readthedocs.io/en/latest/contributed_packages/doe/doe.html`"
"packages documentation at "
# "`https://pyomo.readthedocs.io/en/latest/contributed_packages/doe/doe.html`"
blnicho marked this conversation as resolved.
Show resolved Hide resolved
)


Expand All @@ -29,7 +30,7 @@
)
class MeasurementVariables:
def __init__(self, *args):
raise RuntimeError(deprecation_message)

Check warning on line 33 in pyomo/contrib/doe/__init__.py

View check run for this annotation

Codecov / codecov/patch

pyomo/contrib/doe/__init__.py#L33

Added line #L33 was not covered by tests


@deprecated(
Expand All @@ -37,7 +38,7 @@
)
class DesignVariables:
def __init__(self, *args):
raise RuntimeError(deprecation_message)

Check warning on line 41 in pyomo/contrib/doe/__init__.py

View check run for this annotation

Codecov / codecov/patch

pyomo/contrib/doe/__init__.py#L41

Added line #L41 was not covered by tests


@deprecated(
Expand All @@ -45,4 +46,4 @@
)
class ModelOptionLib:
def __init__(self, *args):
raise RuntimeError(deprecation_message)

Check warning on line 49 in pyomo/contrib/doe/__init__.py

View check run for this annotation

Codecov / codecov/patch

pyomo/contrib/doe/__init__.py#L49

Added line #L49 was not covered by tests
Loading