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

Intermediate results loss reporting for Calibrate. Option for intermediate result reporting every integration step. #124

Merged
merged 11 commits into from
Oct 13, 2023

Conversation

jClugstor
Copy link
Collaborator

Adds callbacks for the solve of Calibrate so that optimization loss values and intermediate solutions can be reported. Added an option for intermediate results to be reported on every integration step instead of being time based. Added dispatches to the get_callback function to specialize on the type of the route inside of the OperationRequest.

Copy link
Collaborator

@joshday joshday left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparently we should remove any callback for simulate and focus solely on calibrate.

I added a few questions/comments.

Manifest.toml Outdated Show resolved Hide resolved
src/operations.jl Outdated Show resolved Hide resolved
src/operations.jl Outdated Show resolved Hide resolved

# callback for Simulate requests
function get_callback(o::OperationRequest, ::Type{Simulate})
DiscreteCallback((args...) -> true, IntermediateResults(o.id,every_iteration = true),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace every_iteration = true with every=Dates.Second(0)

src/operations.jl Outdated Show resolved Hide resolved
src/operations.jl Outdated Show resolved Hide resolved
unnecessary. Moved callbacks. Turned off
simulate intermediate reporting.
@jClugstor jClugstor requested a review from joshday October 12, 2023 19:07
@joshday joshday merged commit 7d7cd90 into DARPA-ASKEM:main Oct 13, 2023
2 checks passed
@jClugstor jClugstor deleted the IntermediateResultsLossReporting branch October 25, 2023 20:59
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.

2 participants