Skip to content

Commit

Permalink
updates doc for transcription.py
Browse files Browse the repository at this point in the history
Signed-off-by: Nithin Rao Koluguri <nithinraok>
  • Loading branch information
Nithin Rao Koluguri committed Oct 31, 2024
1 parent 22d677f commit 8debe2a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions nemo/collections/asr/parts/mixins/transcription.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class TranscribeConfig:
num_workers: Optional[int] = None
channel_selector: ChannelSelectorType = None
augmentor: Optional[DictConfig] = None
timestamps: bool = False # returns timestamps for each word and segments if model supports punctuations
timestamps: Optional[bool] = None # returns timestamps for each word and segments if model supports punctuations
verbose: bool = True

# Utility
Expand Down Expand Up @@ -179,7 +179,7 @@ def transcribe(
channel_selector: Optional[ChannelSelectorType] = None,
augmentor: DictConfig = None,
verbose: bool = True,
timestamps: bool = False,
timestamps: Optional[bool] = None,
override_config: Optional[TranscribeConfig] = None,
**config_kwargs,
) -> GenericTranscriptionType:
Expand All @@ -201,6 +201,7 @@ def transcribe(
to `None`. Defaults to `None`. Uses zero-based indexing.
augmentor: (DictConfig): Augment audio samples during transcription if augmentor is applied.
verbose: (bool) whether to display tqdm progress bar
timestamps: Optional(Bool): timestamps will be returned if set to True as part of hypothesis object (output.timestep['segment']/output.timestep['word']). Refer to `Hypothesis` class for more details. Default is None and would retain the previous state set by using self.change_decoding_strategy().
override_config: (Optional[TranscribeConfig]) override transcription config pre-defined by the user.
**Note**: All other arguments in the function will be ignored if override_config is passed.
You should call this argument as `model.transcribe(audio, override_config=TranscribeConfig(...))`.
Expand Down

0 comments on commit 8debe2a

Please sign in to comment.