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: memoize simulateBlock #5284

Merged
merged 1 commit into from
Oct 12, 2023

Conversation

Erashin
Copy link
Contributor

@Erashin Erashin commented Oct 11, 2023

Add computed block envelopes to STDCMGraph. Only compute block envelopes which have not been already computed.
Makes this test pass in 3mn8s (was not passing beforehand).

@eckter eckter force-pushed the ech/add-large-timetable-tests branch from 03f1386 to 370ec64 Compare October 11, 2023 09:23
@Erashin Erashin force-pushed the alch/memoize-simulated-block-envelopes branch from b4ca116 to 33ae0fc Compare October 11, 2023 10:10
@Erashin Erashin changed the base branch from ech/add-large-timetable-tests to dev October 11, 2023 10:11
@Erashin Erashin linked an issue Oct 11, 2023 that may be closed by this pull request
@Erashin Erashin added area:core Work on Core Service module:stdcm Short-Term DCM labels Oct 11, 2023
@Erashin Erashin force-pushed the alch/memoize-simulated-block-envelopes branch from 33ae0fc to 109fd5c Compare October 11, 2023 10:17
@codecov
Copy link

codecov bot commented Oct 11, 2023

Codecov Report

Merging #5284 (9c9cabd) into dev (8775fea) will increase coverage by 0.01%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##                dev    #5284      +/-   ##
============================================
+ Coverage     18.73%   18.74%   +0.01%     
- Complexity     2318     2322       +4     
============================================
  Files           852      853       +1     
  Lines        103510   103524      +14     
  Branches       2402     2402              
============================================
+ Hits          19396    19410      +14     
  Misses        82774    82774              
  Partials       1340     1340              
Flag Coverage Δ
core 78.99% <100.00%> (+0.02%) ⬆️

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

Files Coverage Δ
...cf/osrd/stdcm/graph/BlockSimulationParameters.java 100.00% <100.00%> (ø)
...ava/fr/sncf/osrd/stdcm/graph/STDCMEdgeBuilder.java 90.90% <100.00%> (ø)
...main/java/fr/sncf/osrd/stdcm/graph/STDCMGraph.java 97.05% <100.00%> (+0.08%) ⬆️
...ava/fr/sncf/osrd/stdcm/graph/STDCMSimulations.java 98.24% <100.00%> (+0.46%) ⬆️
...implementation/BlockAvailabilityLegacyAdapter.java 96.10% <100.00%> (ø)

@Erashin Erashin force-pushed the alch/memoize-simulated-block-envelopes branch from 109fd5c to 0b583ee Compare October 11, 2023 12:11
@Erashin Erashin marked this pull request as ready for review October 11, 2023 12:16
@Erashin Erashin requested a review from a team as a code owner October 11, 2023 12:16
Copy link
Contributor

@Khoyo Khoyo left a comment

Choose a reason for hiding this comment

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

LGTM

Add computed block envelopes to STDCMGraph. Only compute block envelopes which have not been already computed.
@Erashin Erashin force-pushed the alch/memoize-simulated-block-envelopes branch from 0b583ee to 9c9cabd Compare October 12, 2023 08:21
@Erashin Erashin enabled auto-merge October 12, 2023 08:21
@Erashin Erashin added this pull request to the merge queue Oct 12, 2023
Merged via the queue into dev with commit 444b5e9 Oct 12, 2023
@Erashin Erashin deleted the alch/memoize-simulated-block-envelopes branch October 12, 2023 08:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:core Work on Core Service module:stdcm Short-Term DCM
Projects
None yet
Development

Successfully merging this pull request may close these issues.

stdcm: core: memoize simulateBlock
3 participants