-
Notifications
You must be signed in to change notification settings - Fork 663
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 MVDR beamforming tutorial #2398
Conversation
@nateanl has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
examples/tutorials/mvdr_tutorial.py
Outdated
@@ -1,32 +1,45 @@ | |||
""" | |||
MVDR with torchaudio | |||
==================== | |||
MVDR Beamforming with TorchAudio |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have been feeling with TorchAudio
is redundant.
Can we rephrase it to <Task> with MVDR Beamforming
?
From the content of the tutorial, I think Noise reduction with MVDR Beamforming
is a good title.
examples/tutorials/mvdr_tutorial.py
Outdated
waveform_clean, sr2 = torchaudio.load(SAMPLE_CLEAN) | ||
assert sr == sr2 == SAMPLE_RATE | ||
# The mixture waveform is a combination of clean and noise waveforms | ||
waveform_noise = waveform_mix - waveform_clean |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This part felt unintuitive to me.
If it were waveform_mix = waveform_clean + waveform_noise
then it makes more sense.
Can we create another asset and fetch it in the same way as the rest?
examples/tutorials/mvdr_tutorial.py
Outdated
magnitude = stft.abs() | ||
spectrogram = 20 * torch.log10(magnitude + 1e-8).numpy() | ||
figure, axis = plt.subplots(1, 1) | ||
img = axis.imshow(spectrogram, cmap="nipy_spectral", vmin=-100, vmax=0, origin="lower", aspect="auto") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The custom colormap is cool, but can we use the default viridis
?
It is designed so that it is easy for people with color blindness to understand the plot.
See the story behind the development https://bids.github.io/colormap/
@nateanl has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Co-authored-by: Caroline Chen <carolinechen@fb.com>
Co-authored-by: Caroline Chen <carolinechen@fb.com>
@nateanl has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
Hey @nateanl. |
download_asset
to download audios.MVDR
module with new-addedSoudenMVDR
andRTFMVDR
modules.F.rtf_evd
andF.rtf_power
for RTF computation.