Skip to content

Commit

Permalink
Fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mthrok committed May 31, 2021
1 parent 3f58793 commit d0523f0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion docs/source/models.rst
Expand Up @@ -62,7 +62,7 @@ Utility Functions

.. autofunction:: import_huggingface_model

.. autofunction:: import_fairseq_finetuned_model
.. autofunction:: import_fairseq_model

.. currentmodule:: torchaudio.models

Expand Down
5 changes: 3 additions & 2 deletions torchaudio/models/wav2vec2/utils/import_fairseq.py
Expand Up @@ -129,14 +129,15 @@ def import_fairseq_model(
"""Build Wav2Vec2Model from pretrained parameters published by `fairseq`_.
Args:
original (Wav2Vec2Model or Wav2VecEncoder):
original (torch.nn.Module):
An instance of fairseq's Wav2Vec2.0 model class.
Either ``fairseq.models.wav2vec.wav2vec2_asr.Wav2VecEncoder`` or
``fairseq.models.wav2vec.wav2vec2.Wav2Vec2Model``.
num_out (int, optional):
The number of output labels. Required only when the original model is
an instance of ``fairseq.models.wav2vec.wav2vec2.Wav2Vec2Model``.
Returns
Returns:
Wav2Vec2Model: Imported model.
Example - Loading pretrain-only model
Expand Down

0 comments on commit d0523f0

Please sign in to comment.