Improve type checker performance (#13094)
* conditional declare `TOKENIZER_MAPPING_NAMES` within a `if TYPE_CHECKING` block so that type checkers dont need to evaluate the RHS of the assignment. this improves performance of the pylance/pyright type checkers * Update src/transformers/models/auto/tokenization_auto.py Co-authored-by:Sylvain Gugger <35901082+sgugger@users.noreply.github.com> * adding missing import * format Co-authored-by:
Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
Showing
Please register or sign in to comment