[DRAFT] Zoom levels in Analysis#315
Draft
Gautzilla wants to merge 7 commits intoProject-OSmOSE:mainfrom
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🐳 Z🔎🔍M
This PR brings back the ability to export zoomed spectrograms to APLOSE.
It itends at being a bit more configurable than before:
🐬 User POV
From the user perspective, it would look like that:
The default
zoomed_fftsvalues would be, for a given zoom levelz, aShortTimeFFTinstance that is the same as the given sft for the unzoomed specification (the one given as thefftparameter to the analysis), with its hop divided by z:🐬 Exported data
Then, running the analysis with the specified zoom levels would export one SpectroDataset per zoom level, with the link between zoom analyses being specified in the
dataset.jsonfile:{ "datasets": { "original": { "analysis": "original", "class": "AudioDataset", "json": "data\\audio\\original\\original.json" }, "cool_analysis_audio": { "analysis": "cool_analysis", "class": "AudioDataset", "json": "data\\audio\\cool_analysis_audio\\cool_analysis_audio.json" }, "cool_analysis": { "analysis": "cool_analysis", "class": "SpectroDataset", "json": "processed\\cool_analysis\\cool_analysis.json", "zoom_level": 1, "zoom_reference": null }, "cool_analysis_x2": { "analysis": "cool_analysis", "class": "SpectroDataset", "json": "processed\\cool_analysis_x2\\cool_analysis_x2.json", "zoom_level": 2, "zoom_reference": "cool_analysis" } }, "depth": 0.0, "gps_coordinates": [ 0, 0 ], "instrument": null, "strptime_format": null, "timezone": null }Then, I'd add to the public API Dataset some methods to recover all zoomed datasets from the unzoomed version etc.
🐬 Note on AudioDatasets
As of now, I'm not sure there is a scenario in which exporting each "zoomed" audio split has any interest.
I think I'll just apply the zoom parameters to the spectral analysis, and in a scenario where the analysis includes
AnalysisType.AUDIO(audio export), I'll only export the unzoomed AudioDataset and link all zoomed SpectroDatasets to this exported audio.