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

editoast: speed up layer generation #4607

Merged
merged 1 commit into from
Jul 20, 2023
Merged

Conversation

flomonster
Copy link
Contributor

@flomonster flomonster commented Jul 18, 2023

Uses track section layer avoiding using st_transform.

Benchmark

Old Version New version
Track section 3.99s 4.43s
Speed section 160.21s 60.99s
Signal 3.17s 3.43s
Switch 2.13s 0.52s
Buffer stop 0.35s 0.20s
Catenary 10.02s 3.96s
Detector 11.11s 3.17s
Operational point 4.53s 1.42s
Track link 1.25s 0.29s
Lpv panel 5.08s 2.21s
Dead section 1.22s 0.63s
TOTAL 203s 81.2s

@codecov
Copy link

codecov bot commented Jul 18, 2023

Codecov Report

Merging #4607 (2697454) into dev (84556c5) will decrease coverage by 0.01%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##                dev    #4607      +/-   ##
============================================
- Coverage     19.91%   19.91%   -0.01%     
  Complexity     2316     2316              
============================================
  Files           865      865              
  Lines         88144    88144              
  Branches       2277     2277              
============================================
- Hits          17553    17552       -1     
- Misses        69335    69336       +1     
  Partials       1256     1256              
Flag Coverage Δ
editoast 61.22% <ø> (-0.03%) ⬇️

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

see 1 file with indirect coverage changes

@flomonster flomonster force-pushed the fam/speed-up-layer-generation branch from 214e3fd to d94dc80 Compare July 19, 2023 13:42
Uses track section layer avoiding using st_transform
@flomonster flomonster force-pushed the fam/speed-up-layer-generation branch from d94dc80 to 2697454 Compare July 19, 2023 14:17
@flomonster flomonster marked this pull request as ready for review July 19, 2023 14:17
@flomonster flomonster requested a review from a team as a code owner July 19, 2023 14:17
Copy link
Contributor

@leovalais leovalais left a comment

Choose a reason for hiding this comment

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

Shouldn't the search engine responses be updated as well?

https://github.com/osrd-project/osrd/blob/84556c5528d0a7604dc7c5de156dc83672e1b398/editoast/search.yml#L22-L23

(The geometry 4326 might be wrong as well...)

@flomonster
Copy link
Contributor Author

flomonster commented Jul 19, 2023

Shouldn't the search engine responses be updated as well?

https://github.com/osrd-project/osrd/blob/84556c5528d0a7604dc7c5de156dc83672e1b398/editoast/search.yml#L22-L23

(The geometry 4326 might be wrong as well...)

This part is correct, the geometry stored in layers uses 3857 SRID (I haven't changed it). So we need to transform it to 4326 to match the required projection for geojson.

@flomonster flomonster requested a review from leovalais July 19, 2023 15:35
Copy link
Contributor

@Tguisnet Tguisnet left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@leovalais leovalais left a comment

Choose a reason for hiding this comment

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

LGTM

@flomonster flomonster merged commit 130ff62 into dev Jul 20, 2023
@flomonster flomonster deleted the fam/speed-up-layer-generation branch July 20, 2023 07:26
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