-
Notifications
You must be signed in to change notification settings - Fork 66
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
wip: loss factor variable #1238
base: main
Are you sure you want to change the base?
Conversation
Performance Results
|
@@ -385,6 +385,8 @@ _get_pf_result(::Type{PowerFlowLineActivePowerFromTo}, pf_data::PFS.PowerFlowDat | |||
PFS.get_branch_activepower_flow_from_to(pf_data) | |||
_get_pf_result(::Type{PowerFlowLineActivePowerToFrom}, pf_data::PFS.PowerFlowData) = | |||
PFS.get_branch_activepower_flow_to_from(pf_data) | |||
_get_pf_result(::Type{PowerFlowLossFactors}, pf_data::PFS.PowerFlowData) = | |||
[PFS.penalty_factors(aux_vars) for aux_vars in pf_data.aux_variables] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
First, a bit of syntactic sugar:
[PFS.penalty_factors(aux_vars) for aux_vars in pf_data.aux_variables] | |
PFS.penalty_factors.(pf_data.aux_variables) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Second, maybe the issue you're having here is that this is a vector of vectors rather than a matrix? Might need to do some reshaping (see hcat
, vcat
, etc.).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Third, it looks like we now have two different types of things called aux variables. That's going to get confusing.
Co-authored-by: Gabriel Konar-Steenberg <[email protected]>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Gabriel Konar-Steenberg <[email protected]>
No description provided.