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

speed #25

Open
lpatiny opened this issue Jul 16, 2020 · 3 comments
Open

speed #25

lpatiny opened this issue Jul 16, 2020 · 3 comments
Assignees

Comments

@lpatiny
Copy link
Member

lpatiny commented Jul 16, 2020

There seems to be 2 limiting steps:

  • deco.js
  • measureSymShift.js

In node to get profiling you can do:

node -r esm --inspect-brk examples/ddd.js

And the in the browser enter the url chrome://inspect to profile the code.

@lpatiny lpatiny self-assigned this Jul 16, 2020
@targos
Copy link
Member

targos commented Aug 31, 2021

measureSymShift is extremely slow.

Example with the first peak of the "1H spectrum test" data in NMRium:

image
image

@lpatiny
Copy link
Member Author

lpatiny commented Mar 4, 2022

Here is a testcase that is too slow:

72a117f

@djeanner
Copy link
Collaborator

djeanner commented Mar 4, 2022

It is slow because a lot of empty space is taken at both sides of the mutliplets - when intepolating it requires very large arrey.

The multiplet could go through a checkof the quality of the cut of the multiplet.
It would chop off the sides with no signals.

Algorithm: The integral of the region could be calculated (sum of all points or sum of abs of all points), and then and scaled to 100%. Then, keep only the part of the spectrum where (say) 98% of the integral is found, plus a margin of (say) 5 Hz. More implementationally: run from the sides and discard until the cumulated integral reach 1%, then go back (say) 10 Hz (to avoid chopping the lineshape... which is bad for deconvolution).

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

No branches or pull requests

3 participants