Unverified Commit 48b23c11 authored by S Harish's avatar S Harish Committed by GitHub
Browse files

Add example for MuLawEncoding (#1586)

parent 2cece69e
...@@ -654,6 +654,12 @@ class MuLawEncoding(torch.nn.Module): ...@@ -654,6 +654,12 @@ class MuLawEncoding(torch.nn.Module):
Args: Args:
quantization_channels (int, optional): Number of channels. (Default: ``256``) quantization_channels (int, optional): Number of channels. (Default: ``256``)
Example
>>> waveform, sample_rate = torchaudio.load('test.wav', normalize=True)
>>> transform = torchaudio.transforms.MuLawEncoding(quantization_channels=512)
>>> mulawtrans = transform(waveform)
""" """
__constants__ = ['quantization_channels'] __constants__ = ['quantization_channels']
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment