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

Audio - detecting HTML loops containing audio links #17

Open
rvencu opened this issue Feb 16, 2022 · 0 comments
Open

Audio - detecting HTML loops containing audio links #17

rvencu opened this issue Feb 16, 2022 · 0 comments

Comments

@rvencu
Copy link
Owner

rvencu commented Feb 16, 2022

In order to get significant labels for audio a HTML loop detector should be employed. Below some examples
http://www.nemoapps.com/phrasebooks/cantonese - audio link -> audio -> td -> tr -> tbody (looping on tr)
https://sound-effects.bbcrewind.co.uk/search?cat=Nature - audio link -> audio -> div -> ... -> div (looping on div, responsive design)
https://freemusicarchive.org/home - audio link -> div while labels are inside looping div children tags

algorithm idea:
1 detect and count audiolinks
2 if multiple, go to first one, check parent tag (A)
3 check siblings of A if they contain audiolinks, if so A is the looping tag
4 if not go up one parent tag (B), repeat steps 3 and 4 until looping tag is detected
5 count if audiolinks match initial number (use fuzzy logic, like if over 90%), if so then stop looping
6 for each loop extract audiolink and labels as text inside children of looping tag or text inside attributes of the audio player (html5 audio tag)

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

1 participant