transformers/docs/source/en/internal
Sanchit Gandhi a9701953ff
[whisper] static kv cache (#31166)
* make work with cache abstraction

* correct for static cache

* hacks for compile

* make fast

* fix

* fix pos ids

* generate

* fix sdpa

* fix sdpa cache pos

* fix fa2

* clean fa2

* integrate cache into generate

* make style

* copies

* more copies

* update eager

* update sdpa

* update fa2

* simplify

* use cache pos

* always compute cross-cache for debug

* avoid recompiles
Co-authored-by: Arthur Zucker <arthur@huggingface.co>

* fix fix

* fix fix fix

* more fix

* try encoder-decoder cache (too messy)

* revert encoder-decoder cache

* check cross-attn cache

* use enc-dec dataclass

* use richer enc-dec dataclass

* clean-up

* revert static cache changes

* small fixes

* revert to cpu flag

* fix copies

* add static slow test

* past k/v docstring

* more docstrings

* cache_position docstrings

* add to docs

* add enc-dec cache to docs

* make style

* fix after rebase

* fix beam

* style

* fix generation strategies

* fix most decoder-only tests

* style

* skip test

* more clean up

* small docstrings

* Apply suggestions from code review

Co-authored-by: Joao Gante <joaofranciscocardosogante@gmail.com>

* add todo

* only crop self-attn

* check cache in mixin

* style

* fix re-compile after rebase

* move `is_updated` logic to enc-dec wrapper

* revert back

* revert cache back

* finalise design

* fix

* fix fix

* style

* Update src/transformers/cache_utils.py

Co-authored-by: Arthur <48595927+ArthurZucker@users.noreply.github.com>

* deprecate

* updates

* final updates

* style

* style

---------

Co-authored-by: Joao Gante <joaofranciscocardosogante@gmail.com>
Co-authored-by: Arthur <48595927+ArthurZucker@users.noreply.github.com>
2024-07-02 13:24:15 +01:00
..
audio_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
file_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
generation_utils.md [whisper] static kv cache (#31166) 2024-07-02 13:24:15 +01:00
image_processing_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
modeling_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
pipelines_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
time_series_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
tokenization_utils.md Migrate doc files to Markdown. (#24376) 2023-06-20 18:07:47 -04:00
trainer_utils.md translate internal folder files to chinese (#27638) 2023-12-04 10:04:28 -08:00