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

HTK and Slaney #24

Closed
VinodS7 opened this issue Mar 12, 2019 · 11 comments
Closed

HTK and Slaney #24

VinodS7 opened this issue Mar 12, 2019 · 11 comments

Comments

@VinodS7
Copy link

VinodS7 commented Mar 12, 2019

For reproducibility it would be useful to have these two mel filters. These are the two types of filters I have seen the most so correct me if there are other more important types of mel filters.

@keunwoochoi
Copy link
Owner

Agreed. Implementation wouldn't be a big issue, so would be the API design. PR would be welcome!

@VinodS7
Copy link
Author

VinodS7 commented Mar 18, 2019

Will work on it. I am going to reimplement how librosa generates the filters in their backend. However, it is done in python and not in C. Also, I will write some tests that compare my implementation to librosa's but do we have a system in place for writing and evaluating tests?

@hagenw
Copy link
Contributor

hagenw commented Mar 19, 2019

If you want to use the same test framework as PyTorch, uinittest would be the way to go.
I would personally prefer pytest which is great for doing parametrized tests, see also pytorch/pytorch#11578.

To compare the actual outcome of the two implementation, something like numpy.array_equal or numpy.testing.assert_almost_equal might be of interest.

@keunwoochoi
Copy link
Owner

@VinodS7 Welcome and thanks :)

in python and not in C.

Would it make a big difference in computation time?

@keunwoochoi
Copy link
Owner

@hagenw Thanks for letting us know. Probably we should start with unittest and see how it goes there. @faroit @f0k Any thought?

@f0k
Copy link
Collaborator

f0k commented Mar 22, 2019

Probably we should start with unittest and see how it goes there. @faroit @f0k Any thought?

If there is no policy forbidding us to do so, I'd also prefer pytest.

These are the two types of filters I have seen the most so correct me if there are other more important types of mel filters.

I think we should make it easy to reproduce most research papers, so (a) we should include these two filterbanks by default and (b) the API should make it easy to add your own.

@keunwoochoi
Copy link
Owner

Ok let's go with pytest.

@keunwoochoi
Copy link
Owner

@VinodS7 Hi, we'd love to hear from you if there's been any progress! :)

@ksanjeevan
Copy link
Collaborator

Should be easy to add Slaney following librosa https://librosa.github.io/librosa/_modules/librosa/core/time_frequency.html#hz_to_mel? Would just have to add them as options to MelFilterbank!

@VinodS7
Copy link
Author

VinodS7 commented May 2, 2019

@keunwoochoi Hey. Sorry got caught up is some paper deadlines. I'll have it done by end of next week!

@keunwoochoi
Copy link
Owner

@VinodS7 Perfect, no problem, no rush. @ksanjeevan is working on Melspectrogram and I'm expecting to merge some update on it soon. It'll become obvious on which part of the code you should be work on. Thanks! :D

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

5 participants