1. 19 Jan, 2024 13 commits
  2. 18 Jan, 2024 11 commits
  3. 17 Jan, 2024 7 commits
  4. 16 Jan, 2024 9 commits
    • Joao Gante's avatar
    • inisis's avatar
      Add is_model_supported for fx (#28521) · 7142bdfa
      inisis authored
      
      * modify check_if_model_is_supported to return bool
      
      * add is_model_supported and have check_if_model_is_supported use that
      
      * Update src/transformers/utils/fx.py
      
      Fantastic
      
      Co-authored-by: default avataramyeroberts <22614925+amyeroberts@users.noreply.github.com>
      
      ---------
      
      Co-authored-by: default avataramyeroberts <22614925+amyeroberts@users.noreply.github.com>
      7142bdfa
    • fxmarty's avatar
      Clearer error for SDPA when explicitely requested (#28006) · 02f8738e
      fxmarty authored
      * clearer error for sdpa
      
      * better message
      02f8738e
    • Arthur's avatar
      [`SpeechT5Tokenization`] Add copied from and fix the... · fe23256b
      Arthur authored
      [`SpeechT5Tokenization`]  Add copied from and fix the `convert_tokens_to_string` to match the fast decoding scheme (#28522)
      
      * Add copied from and fix the `convert_tokens_to_string` to match the fast decoding scheme
      
      * fixup
      
      * add a small test
      
      * style test file
      
      * nites
      fe23256b
    • Arthur's avatar
      [`TokenizationRoformerFast`] Fix the save and loading (#28527) · 96d08831
      Arthur authored
      * cleanup
      
      * add a test
      
      * update the test
      
      * style
      
      * revert part that allows to pickle the tokenizer
      96d08831
    • Arthur's avatar
      [ `TokenizationUtils`] Fix `add_special_tokens` when the token is already there (#28520) · 716df5fb
      Arthur authored
      
      * fix adding special tokens when the token is already there.
      
      * add a test
      
      * add a test
      
      * nit
      
      * fix the test: make sure the order is preserved
      
      * Update tests/test_tokenization_common.py
      
      Co-authored-by: default avataramyeroberts <22614925+amyeroberts@users.noreply.github.com>
      
      ---------
      
      Co-authored-by: default avataramyeroberts <22614925+amyeroberts@users.noreply.github.com>
      716df5fb
    • Nima Yaqmuri's avatar
      Fix/speecht5 bug (#28481) · 07ae53e6
      Nima Yaqmuri authored
      * Fix bug in SpeechT5 speech decoder prenet's forward method
      
      - Removed redundant `repeat` operation on speaker_embeddings in the forward method. This line was erroneously duplicating the embeddings, leading to incorrect input size for concatenation and performance issues.
      - Maintained original functionality of the method, ensuring the integrity of the speech decoder prenet's forward pass remains intact.
      - This change resolves a critical bug affecting the model's performance in handling speaker embeddings.
      
      * Refactor SpeechT5 text to speech integration tests
      
      - Updated SpeechT5ForTextToSpeechIntegrationTests to accommodate the variability in sequence lengths due to dropout in the speech decoder pre-net. This change ensures that our tests are robust against random variations in generated speech, enhancing the reliability of our test suite.
      - Removed hardcoded dimensions in test assertions. Replaced with dynamic checks based on model configuration and seed settings, ensuring tests remain valid across different runs and configurations.
      - Added new test cases to thoroughly validate the shapes of generated spectrograms and waveforms. These tests leverage seed settings to ensure consistent and predictable behavior in testing, addressing potential issues in speech generation and vocoder processing.
      - Fixed existing test cases where incorrect assumptions about output shapes led to potential errors.
      
      * Fix bug in SpeechT5 speech decoder prenet's forward method
      
      - Removed redundant `repeat` operation on speaker_embeddings in the forward method. This line was erroneously duplicating the embeddings, leading to incorrect input size for concatenation and performance issues.
      - Maintained original functionality of the method, ensuring the integrity of the speech decoder prenet's forward pass remains intact.
      - This change resolves a critical bug affecting the model's performance in handling speaker embeddings.
      
      * Refactor SpeechT5 text to speech integration tests
      
      - Updated SpeechT5ForTextToSpeechIntegrationTests to accommodate the variability in sequence lengths due to dropout in the speech decoder pre-net. This change ensures that our tests are robust against random variations in generated speech, enhancing the reliability of our test suite.
      - Removed hardcoded dimensions in test assertions. Replaced with dynamic checks based on model configuration and seed settings, ensuring tests remain valid across different runs and configurations.
      - Added new test cases to thoroughly validate the shapes of generated spectrograms and waveforms. These tests leverage seed settings to ensure consistent and predictable behavior in testing, addressing potential issues in speech generation and vocoder processing.
      - Fixed existing test cases where incorrect assumptions about output shapes led to potential errors.
      
      * Enhance handling of speaker embeddings in SpeechT5
      
      - Refined the generate and generate_speech functions in the SpeechT5 class to robustly handle two scenarios for speaker embeddings: matching the batch size (one embedding per sample) and one-to-many (a single embedding for all samples in the batch).
      - The update includes logic to repeat the speaker embedding when a single embedding is provided for multiple samples, and a ValueError is raised for any mismatched dimensions.
      - Also added corresponding test cases to validate both scenarios, ensuring complete coverage and functionality for diverse speaker embedding situations.
      
      * Improve Test Robustness with Randomized Speaker Embeddings
      07ae53e6
    • fxmarty's avatar
      Fix mismatching loading in from_pretrained with/without accelerate (#28414) · 66db33dd
      fxmarty authored
      * fix mismatching behavior in from_pretrained with/without accelerate
      
      * meaningful refactor
      
      * remove added space
      
      * add test
      
      * fix model on the hub
      
      * comment
      
      * use tiny model
      
      * style
      66db33dd
    • Hamza FILALI's avatar
      Improving Training Performance and Scalability Documentation (#28497) · 002566f3
      Hamza FILALI authored
      
      * Improving Training Performance and Scaling documentation by adding PEFT techniques to suggestions to reduce memory requirements for training
      
      * Update docs/source/en/perf_train_gpu_one.md
      
      Co-authored-by: default avatarYounes Belkada <49240599+younesbelkada@users.noreply.github.com>
      
      ---------
      
      Co-authored-by: default avatarYounes Belkada <49240599+younesbelkada@users.noreply.github.com>
      002566f3