Skip to content

Fix typos, use idiomatic PyTorch API, and correct type hints#2765

Open
avasis-ai wants to merge 1 commit into
openai:mainfrom
avasis-ai:fix/typos-and-type-hints
Open

Fix typos, use idiomatic PyTorch API, and correct type hints#2765
avasis-ai wants to merge 1 commit into
openai:mainfrom
avasis-ai:fix/typos-and-type-hints

Conversation

@avasis-ai

Copy link
Copy Markdown

Summary

Three small fixes across the whisper package:

  1. transcribe.py: Fix "supercedes" → "supersedes" typo in the --threads CLI help text
  2. timing.py: Use dim=0 instead of axis=0 for torch.Tensor.mean(). While PyTorch accepts axis as an alias, dim is the canonical parameter name and consistent with the rest of the codebase.
  3. __init__.py: Fix download_root: str = NoneOptional[str] = None to correctly reflect that None is a valid default value.

Testing

  • No functional changes; all fixes are documentation/type-level only

Co-authored-by: opencode

- transcribe.py: fix 'supercedes' typo to 'supersedes' in --threads help
- timing.py: use 'dim' instead of 'axis' for torch.Tensor.mean() (idiomatic PyTorch)
- __init__.py: fix download_root type hint from 'str' to 'Optional[str]'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants