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

core: stdcm: standard allowance bugfixes #2866

Merged
merged 3 commits into from
Jan 13, 2023
Merged

Conversation

eckter
Copy link
Contributor

@eckter eckter commented Jan 12, 2023

  • Handle exceptions that happen inside the binary search, when we can handle them
  • Use the given standard allowance to consider the fastest run time
  • Remove an assert that could be triggered in linear allowances

@eckter eckter requested a review from a team as a code owner January 12, 2023 14:45
@eckter eckter requested a review from a team as a code owner January 12, 2023 15:28
@codecov
Copy link

codecov bot commented Jan 12, 2023

Codecov Report

Merging #2866 (833ff30) into dev (88dd7ae) will increase coverage by 0.02%.
The diff coverage is 72.00%.

@@             Coverage Diff              @@
##                dev    #2866      +/-   ##
============================================
+ Coverage     38.00%   38.03%   +0.02%     
+ Complexity     1699     1698       -1     
============================================
  Files           585      585              
  Lines         17969    17987      +18     
  Branches       2475     2478       +3     
============================================
+ Hits           6829     6841      +12     
- Misses        10742    10746       +4     
- Partials        398      400       +2     
Flag Coverage Δ
core 83.67% <72.00%> (-0.06%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...in/java/fr/sncf/osrd/envelope/EnvelopePhysics.java 86.31% <ø> (+0.89%) ⬆️
...ain/java/fr/sncf/osrd/api/stdcm/STDCMEndpoint.java 76.92% <50.00%> (-1.75%) ⬇️
...pe_sim/allowances/AbstractAllowanceWithRanges.java 89.82% <70.58%> (-1.77%) ⬇️
...llowances/utils/AllowanceConvergenceException.java 80.00% <100.00%> (+13.33%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

In some cases we can't even build a valid envelope during the
binary search, but the error is only caused by input values.
We can catch these errors to continue the search.
This commit also contains a new STDCM test that reproduces the case
@eckter eckter merged commit 792a150 into dev Jan 13, 2023
@eckter eckter deleted the ech/fix-stdcm-allowance branch January 13, 2023 09:44
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.

3 participants