Repository navigation
Design input feature - #263
Draft
yoelcortes wants to merge 9 commits into
Draft
yoelcortes wants to merge 9 commits into
yoelcortes wants to merge 9 commits into
Conversation
added 5 commits
November 10, 2026 07:52
Member
|
I'll take a look over the weekend. Interesting feature, I'll test it with QSDsan to see if there's any updates needed. On a not-so-relevant note, is there checks on |
Member
Author
|
@yalinli2, OK! Yeah, hensmith broke with the new update. I will fix the issue with biosteam. Heads up, I also updated the code in Unit.init, so we will need to update QSDsan to enable the default feature for Thanks, |
yoelcortes
marked this pull request as draft
November 12, 2026 20:14
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
@yalinli2, @sarangbhagwat,
This pull is huge, but don't let that scare you; it's actually just one new function
design_inputthat provides a standard way to define input parameters for unit operations. The main benefits include defaults, value checks, auto-assigning cost factors (e.g., material factors), automatic documentation, and have them appear in<Unit>.results().It generates Python property objects (with default getter/setter) but you can also define the getter/setter yourself. Here is an example:
The documentation looks like this:
design_input P: float
Operating pressure [Pa]. Defaults to 101325 Pa.
design_input T: float
Operating temperature [K]. Defaults to 350 K.
design_input V_wf: float
Working volume fraction. Defaults to 0.8.
design_input material: str
Construction material. Defaults to 'Carbon steel'
design_input orientation: str
Orientation. Defaults to 'Vertical'
design_input tau: float
Residence time [hr].
Here is chatgpt's summary of the key features: