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

Need Dynamic y-axis, Else outliers take over #5

Open
davodogster opened this issue Aug 20, 2020 · 2 comments
Open

Need Dynamic y-axis, Else outliers take over #5

davodogster opened this issue Aug 20, 2020 · 2 comments

Comments

@davodogster
Copy link

Hi again @Dubrzr

Some of my signals have outliers which means that zooming into other parts of the series doesn't actually help because the y axis is based on the max and min value of the whole series. It would be super helpful if users could zoom into any part of the signal and have some of the values go outside the visible range of the y axis so that correct annotation can be performed.

image

Cheers

@Dubrzr
Copy link
Owner

Dubrzr commented Aug 21, 2020

Hi Sam,

This is something I also thought about, and something that I think I already tested here:

//const vals = this._normalize(this.sig_vals.slice(offsetPts, end), 0, this.h);

Try to uncomment this line in your annotator.js file, it should be doing what you want.

The only thing that might me a problem is performance because for each move on the signal, more computations are made:

  • compute the local min and max
  • multiply each value by a new ratio

Which mean 3 more passes on all values that are displayed, lots of optimizations are possible, for example, replace Math.min.apply and Math.max.apply by custom function that only make a single pass and is faster (https://stackoverflow.com/a/13440842/3157230)

Might be cool if you can contact me Sam so that we can talk a little more about this. My mail = firstname + "." + lastname + "@aphp.fr".

@davodogster
Copy link
Author

Thanks, uncommenting that line seems to do what I wanted! 👍
Sorry I keep mentioning it but.. the ability to be able to upload annotations (preferably from a csv but Json will work) would be super helpful because I could generate some noisy labels in python and then refine them in your app.

Thanks for the contact, will try to keep things on Github for now.

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

2 participants