Andy Ehrenberg
2840272c5f
add flax whisper implementation (#20479)
* add flax whisper implementation
* rever change to setup
* remove unused imports
* revert generation changes
* flax whisper docs
* docs
* import order
* import sorting
* isort
* add dummy objects
* doc formatting
* formatting
* remove trailing whitespaces
* fix flax whisper docs
* add generation logic to unlock flax whisper
* remove scans
* give credits to Flax Bart implementation
* remove unused imports
* add license
* remove assert
* more credits to Bart
* fix style
* formatting
* support left padding
* add flax whisper generation test
* remove copied from comments whenever not a full copy
* fix docstrings for logits processors
* revert change to FlaxForceTokensLogitsProcessor
* revert doc changes
* improve generation docs
* reorganize
* formatting
* cleanup docs
* add tests
* handle empty list case
* fix forced decoder ids in flax tests
* add flax whisper to inits
* upate dummy objects
* docs for FlaxAutoModelForSpeechSeq2Seq
* fix decoder_position_ids computation in pretrained model decode/__call__ fns
* add Copied from statements as necessary
* compute position_ids only in __call__ and decode methods of pretrained model subclasses
* improve readabilityof compute positional embeddings
* check dimensionality of input_features instead of hidden_states
* copied from statement for init_cache
* formatting
* fix copies
* fix copies
* pass attention mask to encoder layers
* fix decoder module outputs
* set dtype
Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com>
* smaller flax model for whisper test
* Update src/transformers/generation/flax_utils.py
Co-authored-by: Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
* Update src/transformers/models/whisper/modeling_flax_whisper.py
Co-authored-by: Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
* Update tests/models/whisper/test_modeling_flax_whisper.py
Co-authored-by: Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
* cleanup
Co-authored-by: Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
* Update src/transformers/models/whisper/modeling_flax_whisper.py
Co-authored-by: Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
* bias cleanup
* doc fix
* align style for force tokens processor
* readability
* fix input shape in tests
* revert FlaxGenerationMixin docstring
* formatting
* fix tests
* fix imports
* consistent encoder hidden states
* consistent hidden states
* input shapes
* typo
* partial class trick
* partial class for input shape
* base_class with correct input shape
* partial base classes
* match by name
* set main_input_name
* compare on names
* formatting
* remove unused import
* safer position ids computation
* safer position id computation
* Update src/transformers/models/whisper/modeling_flax_whisper.py
Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com>
* Update src/transformers/models/whisper/modeling_flax_whisper.py
Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com>
* remove identical inherited tests
* fix prompt ids in tests
* use generation config
* use jnp array
* better var names
* more explicit bias use
* import transformers
* formatting
* test formatting
* remove unused imports
* remove unused imports
* formatting
* isort
* docs
* fix ln orders for encoder hidden states
* whisper unique generation stuff
* flake
* use finfo for attention bias
* docs
* Update src/transformers/generation/flax_utils.py
Co-authored-by: Arthur <48595927+ArthurZucker@users.noreply.github.com>
* docs
* add timestamp flax test
* jit for timestamps
* formatting
* clean up timestamps processor
* formatting
* remove if_true
* cleanup
---------
Co-authored-by: Sanchit Gandhi <93869735+sanchit-gandhi@users.noreply.github.com>
Co-authored-by: Sylvain Gugger <35901082+sgugger@users.noreply.github.com>
Co-authored-by: Arthur <48595927+ArthurZucker@users.noreply.github.com>
2023-02-20 09:17:40 +01:00
..
2023-02-16 20:59:27 +01:00
2023-02-17 09:44:01 +01:00
2023-02-20 09:17:40 +01:00
2023-02-15 09:24:56 -05:00
2022-04-04 10:25:46 -04:00
2023-02-17 09:44:01 +01:00
2022-08-08 10:53:52 -05:00
2023-02-09 15:46:26 -05:00
2022-12-12 09:23:23 -05:00
2022-11-07 09:19:04 -05:00
2023-02-15 10:35:14 -08:00
2022-11-30 14:50:55 +00:00
2022-04-04 10:25:46 -04:00
2022-04-04 10:25:46 -04:00
2022-11-07 09:19:04 -05:00
2022-04-04 10:25:46 -04:00
2022-04-04 10:25:46 -04:00
2022-09-30 20:30:38 +01:00
2023-01-25 11:33:39 -05:00
2022-11-07 13:57:39 -05:00
2022-12-12 10:38:56 -05:00
2022-04-04 10:25:46 -04:00
2023-01-17 12:23:22 -05:00
2022-11-30 14:50:55 +00:00
2022-10-11 22:54:19 -04:00
2023-02-20 09:17:40 +01:00
2022-08-05 13:14:00 -04:00
2022-04-04 10:25:46 -04:00
2023-02-06 09:26:22 -05:00
2023-02-15 10:35:14 -08:00
2022-04-04 10:25:46 -04:00
2022-04-04 10:25:46 -04:00
2022-04-04 10:25:46 -04:00
2022-05-16 13:36:41 +02:00
2022-12-01 16:52:13 +01:00
2022-12-01 16:52:13 +01:00
2023-02-07 15:09:27 +01:00
2022-06-23 14:51:54 +02:00
2022-11-28 08:54:35 -05:00
2023-02-06 09:20:43 -05:00
2022-11-30 10:41:18 -05:00
2022-12-08 11:18:52 -05:00
2022-11-30 10:41:18 -05:00
2023-02-07 15:19:19 +00:00
2022-11-30 10:41:18 -05:00
2022-11-30 10:41:18 -05:00
2022-09-06 15:20:12 -04:00
2022-11-30 14:50:55 +00:00
2023-02-10 10:26:17 +01:00
2023-02-06 18:10:56 -05:00
2023-02-07 12:27:31 -05:00
2023-01-19 08:43:36 -05:00
2023-02-13 11:37:48 -08:00
2022-08-06 09:38:55 +02:00
2022-04-04 10:25:46 -04:00
2023-02-10 15:32:06 +01:00
2023-02-13 10:09:00 -05:00
2023-02-02 11:41:27 -08:00
2022-11-15 09:40:06 -05:00
2023-01-18 17:53:05 +00:00
2022-11-15 01:18:13 +01:00
2022-10-03 13:18:29 -07:00
2023-01-20 07:38:15 -08:00
2022-11-30 14:50:55 +00:00