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

feat: Tonality ECMA418-2 #208

Open
wants to merge 10 commits into
base: main
Choose a base branch
from
Open

feat: Tonality ECMA418-2 #208

wants to merge 10 commits into from

Conversation

a-bouth
Copy link
Collaborator

@a-bouth a-bouth commented Jan 15, 2025

Added class TonalityECMA418_2 + Associated tests
image

@a-bouth
Copy link
Collaborator Author

a-bouth commented Jan 15, 2025

Important note (@ansaminard ) the outputs tonality over time and tone frequency over time might have slightly different time scales (same behaviour as in SAS), as a consequence :

  • The time scale obtained with get_time_scale() is the one associated to the tonality over time
  • For the plot, I'm using a different X axis for both subplots

Copy link
Collaborator

@mattbennett72 mattbennett72 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

@github-actions github-actions bot added documentation Improvements or additions to documentation enhancement New features or code improvements labels Jan 16, 2025
Copy link

codecov bot commented Jan 16, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 100.00%. Comparing base (41782d6) to head (7b99c20).

Additional details and impacted files
@@            Coverage Diff            @@
##              main      #208   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           69        70    +1     
  Lines         3813      3878   +65     
=========================================
+ Hits          3813      3878   +65     

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

Copy link
Collaborator

@anshlachamb anshlachamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Main concern: time scale of the vs time indicators

time_scale_ft = self.get_output()[2].time_freq_support.time_frequencies.data

# Plot ECMA 418-2 parameters over time.
_, axes = plt.subplots(2, 1, sharex=False)
Copy link
Collaborator

@anshlachamb anshlachamb Jan 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@a-bouth why not sharing X axis?

On the plot you share in the description of the PR, X axes are both vs time, but slightly not synchronized, which looks weird

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by the way, isn't the same time scale (get_time_scale()) shared by both curves ?

If yes: we can use the same, and share it among both plots
If no: why ? and in this case, we probably miss a time_scale getter for the second one

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@anshlachamb I think the question is for me rather than for Antoine

The answer is because both output does not have exactly the same time scale (same behaviour as in SAS)

Concerning the "why" : I have no precise answer. As for the getter I don't know if it's needed, I leave that question to @ansaminard

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"why": I don't know either, I planned to look into the Matlab code, but haven't the chance to do it yet. Anyway, whatever I find there, I doubt it'll have an immediate impact here, since @a-bouth says it's also the case in SAS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New features or code improvements
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants