IPS-LMU / EMU-webApp

The EMU-webApp is an online and offline web application for labeling, visualizing and correcting speech and derived speech data.
http://ips-lmu.github.io/EMU-webApp/
MIT License
51 stars 14 forks source link

SSFF track scaling behaves strangely when minMaxValLims differ from the data's true range #296

Closed samkirkham closed 2 years ago

samkirkham commented 3 years ago

From the 'ae' demo DB, here is an example of the 'fundFreq' track with no maxMinValLims specified. The cursor shows a f0 readout of 85.7 on the left (i.e. around the [w] segment), which is accurate to the SSFF file.

no lims

Here is the same track with minMaxValLims changed to 0,100. At roughly the same timepoint, this shows a value of ~124 Hz (whereas the true value around this point is actually ~85 Hz). The min/max values at the bottom/top of the SSFF track panel are the min/max of the original data, so this is where the values are coming from.

0,100

So it seems that minMaxValLims changes the range of the SSFF track shown, but the values displayed by the WebApp retain the scaling of the entire SSFF track. Is this expected behaviour?

It's not the biggest issue in the world, but it would be nice if the min/max values in the WebApp for each SSFF panel followed those set in minMaxValLims for the given track. Of course, it's inconsequential for the demo example here, but I have examples where the file onset contains extreme values and changing the range to exclude these would be helpful. Alternatively, apologies in advance if I've misunderstood the appropriate usage of minMaxValLims!

raphywink commented 3 years ago

Nope this is not expected behaviour.... damn... must have 4gotten to check for the minMaxValLims when drawing those values. Will look at this ASAP... thanks 4 reporting!

samgregory commented 2 years ago

Hi @samkirkham - I've fixed this bug. Hopefully it will get included in the version being rolled out next week.

MJochim commented 2 years ago

Thans @samgregory for your fix. I've included it in the master branch. I'm still wondering why your addition of the unit field to the DBconfig – which I like – doesn’t trigger a validation warning when the database is loaded in the EMU-webApp. However, that’s a separate issue.

samgregory commented 2 years ago

Hi @MJochim - yup, the unit field was a simple aesthetic fix that made sense to me. I also noticed that it didn't trigger a validation warning and I think the reason is that emuwebappConfigScheme allows for additionalProperties in the signalCanvases object.

https://github.com/IPS-LMU/EMU-webApp/blob/master/src/schemaFiles/emuwebappConfigSchema.json#L317

Thanks for working on this update - it'll be nice to see a few of those long standing issues closed.

MJochim commented 2 years ago

This fix is also included the 1.4.0 release I made today, so I’ll close this issue. Feel free to re-open if it doesn’t work as intended.

The validation can be discussed in the separate issue.