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

Update audio feature extraction tutorial #2391

Closed

Conversation

mthrok
Copy link
Collaborator

@mthrok mthrok commented May 13, 2022

  • Adopt torchaudio.utils.download_asset to simplify asset management.
  • Break down the first section about helper functions.
  • Reduce the number of helper functions

https://app.circleci.com/pipelines/github/pytorch/audio/11065/workflows/8fd5da50-71af-46f3-8c95-cadbc7be3a1a/jobs/704592

@mthrok mthrok force-pushed the update-feature-extraction-tutorial branch from ca76d1c to 7c35c28 Compare May 16, 2022 04:18
@mthrok mthrok marked this pull request as ready for review May 16, 2022 04:23
@nateanl
Copy link
Member

nateanl commented May 16, 2022

@mthrok
Copy link
Collaborator Author

mthrok commented May 16, 2022

Copy link
Member

@nateanl nateanl left a comment

Choose a reason for hiding this comment

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

lgtm overall. just some nits to be addressed.

# The following diagram shows the relashipship between common audio features
# and torchaudio APIs to generate them.
#
# .. image:: https://download.pytorch.org/torchaudio/tutorial-assets/torchaudio_feature_extractions.png
Copy link
Member

Choose a reason for hiding this comment

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

Do you plan to add ComputeDelta to this diagram? It can be above the MFCC feature IMO. Delta feature is often used along with MFCC by kaldi users for ASR.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Not this time. let's followup later.


######################################################################
#

plot_spectrogram(melspec[0], title="MelSpectrogram - torchaudio", ylabel="mel freq")

######################################################################
# Comparison against librosa
Copy link
Member

Choose a reason for hiding this comment

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

This section doesn't have section index, is it intended?

@mthrok mthrok added this to the v0.12 milestone May 24, 2022
- Adopt torchaudio.utils.download_asset to simplify asset management.
- Break down the first section about helper functions.
- Reduce the number of helper functions
- Add section number
@mthrok mthrok force-pushed the update-feature-extraction-tutorial branch from 7c35c28 to 894e7b3 Compare June 2, 2022 04:13
pitch = F.detect_pitch_frequency(waveform, sample_rate)
plot_pitch(waveform, sample_rate, pitch)
play_audio(waveform, sample_rate)
plot_pitch(SPEECH_WAVEFORM, SAMPLE_RATE, pitch)

######################################################################
# Kaldi Pitch (beta)
Copy link
Contributor

Choose a reason for hiding this comment

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

ooc is this still in beta phase?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes.

Co-authored-by: nateanl <zni@fb.com>
Co-authored-by: Caroline Chen <carolinechen@fb.com>
@facebook-github-bot
Copy link
Contributor

@mthrok has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@github-actions
Copy link

github-actions bot commented Jun 3, 2022

Hey @mthrok.
You merged this PR, but labels were not properly added. Please add a primary and secondary label (See https://github.com/pytorch/audio/blob/main/.github/process_commit.py)

@mthrok mthrok deleted the update-feature-extraction-tutorial branch June 3, 2022 22:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants