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

[Feature] FFC/FeatureFinderAlgorithmPicked speedup #4701

Merged
merged 10 commits into from May 7, 2020

Conversation

IceFreez3r
Copy link
Contributor

Worked once more at FeatureFinderCentroided.
As the main runtime goes into run(), I focused on that. For exact changes look into the single commits. I think they explain quiet good, what happened.

As a result the runtime reduced from 1:21:54 to 1:07:29 (Wall)
I compared the output file from the "develop"-Branch and from my "ffc-testzone"-Featurebranch with FuzzyFinder. For some reason the representation of the intensities changed in the output. This lead to some decimal points being cut off and to a slightly changed output:

PASSED.

  relative_max:        1
  relative_acceptable: 1

  absolute_max:        0.009062
  absolute_acceptable: 0.01

  whitelist cases:
    "completion_time"      1x
    "feature id"         70791x
    "featureMap version"   1x
    "parameter"            1x
    "software name"        1x

Maximum relative error was attained at these lines, enclosed in "":

./F_QC_20140521_2.featureXML:2307927:
"                       <intensity>1.040731e04</intensity>"     <-- from ffc-testzone

./R_QC_20140521_2.featureXML:2307927:
"                       <intensity>10407.311523</intensity>"    <-- from develop

I also ran all the tests and they all passed.

If someone is interested in working on this in the future again: I refactored the individual steps in run(), so that they appear in perf and one can see where the runtime disappears.
Step
StepThree
StepThreeThree

Removed scores-vector. Working on the trace_score (double) should be sufficient here.
Stored map[s +- i] in next_spectrum to prevent multiple accesses. Was probably already optimized by the compiler.

Not tested!
Changed all for-Loops to ranged based for-Loops where CLion recommended it
Removed checks for OMP: #pragma omp parallel does nothing without OMP

Changed a few occurences of push_back to emplace_back where possible
Small changes similar to the commits before
Instead of changing feature_ok to false and returning it at the end, just instant return false. Prevents multiple if(feature_ok) branches.
There werde multiple occurences of commented continue()-s. Now there are uncommented and the following else parts aren't necessary anymore and were removed
@IceFreez3r IceFreez3r changed the title FFC/FeatureFinderAlgorithmPicked speedup [Feature] FFC/FeatureFinderAlgorithmPicked speedup May 5, 2020
@cbielow
Copy link
Contributor

cbielow commented May 6, 2020

someone else wants to have a look?
Otherwise we merge :)

@cbielow cbielow merged commit 759e535 into OpenMS:develop May 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants