Repository navigation
Allow different mapping from annotations to annotated files - #572
Merged
Merged
Conversation
Removes repeated `if annot_list` code block inside `audio.to_spect` function. There were two places that check if there's a list of annotations, and then call `map_annotated_to_annot`, to map the annotation to `audio_files`. The first in the `if audio_files` code block, and the second in the `if audio_dir` code block right under the first. But after both code blocks we end up with a list of `audio_files`. So we can just wait until after and then check `if annot_list` and (if there is an `annot_list`) finally call `map_annotated_to_annot`. This commit changes the function to do so.
Step towards allowing a different mapping from annotation files to annotated, by removed the annotations extension and replacing with the annotated. Split 'map_annotated_to_annot' into two helper functions. Also add type annotations.
- Add fixtures for TextGrid annotations - Add fixtures for 'simple-seq' annotations
- Add links to howto_prep_annotate
+ at top of page and in middle,
linking to "how vak associates annotations with
files they annotate"
- Fix formatting of file extension + library names
to explain the two valid ways of naming derived files with one-to-one mappings from audio file to derived file, i.e., some annotation file formats and array files containing spectrograms.
Revise file naming convention section, and add link there to updated page on naming conventions.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #572 +/- ##
==========================================
- Coverage 92.98% 92.94% -0.05%
==========================================
Files 65 65
Lines 2295 2367 +72
==========================================
+ Hits 2134 2200 +66
- Misses 161 167 +6 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
Adds the simpler way of mapping from annotations to annotated: by simply replacing the annotation extension with the extension of the annotated file.
We check for both ways: the original way, including the source audio file, and this new way.
Fixes #563