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

Fixing time signature preprocessing (time division mismatch) #132

Merged
merged 1 commit into from
Jan 19, 2024

Conversation

Natooz
Copy link
Owner

@Natooz Natooz commented Jan 19, 2024

Fixes #131
In _preprocess_time_signatures, the ticks_per_bar computations were made based on the tokenizer's time division instead of the MIDI's, which can be different depending on the time signatures in the MIDI and those supported by the tokenizer, resulting in erroneously shifted time signatures.
Now the MIDI's time signature is passed to _preprocess_time_signatures .


📚 Documentation preview 📚: https://miditok--132.org.readthedocs.build/en/132/

Copy link

codecov bot commented Jan 19, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (3cb6b97) 91.19% compared to head (7834595) 91.17%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #132      +/-   ##
==========================================
- Coverage   91.19%   91.17%   -0.03%     
==========================================
  Files          33       33              
  Lines        4886     4886              
==========================================
- Hits         4456     4455       -1     
- Misses        430      431       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Natooz Natooz merged commit e6bdebd into main Jan 19, 2024
15 checks passed
@Natooz Natooz deleted the fix-time-sig-preprocess branch January 19, 2024 09:06
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

Successfully merging this pull request may close these issues.

Incorrect Placement of Time Signatures
1 participant