1. 29 Apr, 2021 1 commit
  2. 26 Apr, 2021 6 commits
  3. 25 Apr, 2021 2 commits
    • cronoik's avatar
      EncoderDecoderConfigs should not create new objects (#11300) · 35cd8eed
      cronoik authored
      
      
      * removes the creation of separate config objects and uses the existing ones instead+overwrite resize_token_embeddings from parent class because it is not working for the EncoderDecoderModel
      
      * rollback to current version of the huggingface master branch
      
      * reworked version that ties the encoder and decoder config of the parent encoderdecoder instance
      
      * overwrite of resize_token_embeddings throws an error now
      
      * review comment suggestion
      Co-authored-by: default avatarSuraj Patil <surajp815@gmail.com>
      
      * implemented warning in case encoderdecoder is created with differing configs of encoderdecoderconfig and decoderconfig or encoderconfig
      
      * added test to avoid diverging configs of wrapper class and wrapped classes
      
      * Update src/transformers/models/encoder_decoder/modeling_encoder_decoder.py
      
      * make style
      Co-authored-by: default avatarSuraj Patil <surajp815@gmail.com>
      Co-authored-by: default avatarPatrick von Platen <patrick.v.platen@gmail.com>
      35cd8eed
    • Daniel Stancl's avatar
      Add head_mask, decoder_head_mask, cross_head_mask to ProphetNet (#9964) · f45cb66b
      Daniel Stancl authored
      * Add head_mask & decoder_head_mask + some corrections
      
      * Fix head masking for N-grams
      
      * Enable test_headmasking for encoder and decod
      
      * Fix one typo regarding in modeling_propgetnet.py
      
      * Enable test_headmasking for ProphetNetStandaloneDecoderModelTest
      and ProphetNetStandaloneEncoderModelTest in test_modeling_prophetnet.py
      
      * make style
      
      * Fix cross_head_mask
      
      * Fix attention head mask naming
      
      * `cross_head_mask` -> `cross_attn_head_mask`
      
      * `cross_layer_head_mask` -> `cross_attn_layer_head_mask`
      
      * Still need to merge #10605 to master to pass the tests
      f45cb66b
  4. 23 Apr, 2021 5 commits
    • Philip May's avatar
      Enable option for subword regularization in `XLMRobertaTokenizer` (#11149) · 195bfd11
      Philip May authored
      
      
      * enable subword regularization.
      
      * fix tokenizer storage
      
      * fix docstring formatting
      
      * Update src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py
      Co-authored-by: default avatarStefan Schweter <stefan@schweter.it>
      
      * fix docstring formatting
      
      * add test for subword regularization tokenizer
      
      * improve comments of test
      
      * add sp_model_kwargs
      
      * reformat docstring to match the style
      
      * add some more documentation
      
      * Update src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      
      * improve docstring
      
      * empty commit to trigger CI
      
      * Update src/transformers/models/xlm_roberta/tokenization_xlm_roberta.py
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      
      * fix docstring formatting for sphinx
      Co-authored-by: default avatarStefan Schweter <stefan@schweter.it>
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      195bfd11
    • Daniel Stancl's avatar
      Fix cross-attention head mask for Torch encoder-decoder models (#10605) · e3ff165a
      Daniel Stancl authored
      * Fix cross-attention head mask for Torch BART models
      
      * Fix head masking for cross-attention module for the following
      models: BART, Blenderbot, Blenderbot_small, M2M_100, Marian, MBart,
      Pegasus
      
      * Enable test_headmasking for M2M_100 model
      
      * Fix cross_head_mask for FSMT, LED and T5
      
      * This commit fixes `head_mask` for cross-attention modules
      in the following models: FSMT, LED, T5
      
      * It also contains some smaller changes in doc so that
      it is be perfectly clear the shape of `cross_head_mask`
      is the same as of `decoder_head_mask`
      
      * Update template
      
      * Fix template for BartForCausalLM
      
      * Fix cross_head_mask for Speech2Text models
      
      * Fix cross_head_mask in templates
      
      * Fix args order in BartForCausalLM template
      
      * Fix doc in BART templates
      
      * Make more explicit naming
      
      * `cross_head_mask` -> `cross_attn_head_mask`
      
      * `cross_layer_head_mask` -> `cross_attn_layer_head_mask`
      
      * Fix doc
      
      * make style quality
      
      * Fix speech2text docstring
      e3ff165a
    • Sylvain Gugger's avatar
      Trainer push to hub (#11328) · bf2e0cf7
      Sylvain Gugger authored
      
      
      * Initial support for upload to hub
      
      * push -> upload
      
      * Fixes + examples
      
      * Fix torchhub test
      
      * Torchhub test I hate you
      
      * push_model_to_hub -> push_to_hub
      
      * Apply mixin to other pretrained models
      
      * Remove ABC inheritance
      
      * Add tests
      
      * Typo
      
      * Run tests
      
      * Install git-lfs
      
      * Change approach
      
      * Add push_to_hub to all
      
      * Staging test suite
      
      * Typo
      
      * Maybe like this?
      
      * More deps
      
      * Cache
      
      * Adapt name
      
      * Quality
      
      * MOAR tests
      
      * Put it in testing_utils
      
      * Docs + torchhub last hope
      
      * Styling
      
      * Wrong method
      
      * Typos
      
      * Update src/transformers/file_utils.py
      Co-authored-by: default avatarJulien Chaumond <julien@huggingface.co>
      
      * Address review comments
      
      * Apply suggestions from code review
      Co-authored-by: default avatarPatrick von Platen <patrick.v.platen@gmail.com>
      Co-authored-by: default avatarJulien Chaumond <julien@huggingface.co>
      Co-authored-by: default avatarPatrick von Platen <patrick.v.platen@gmail.com>
      bf2e0cf7
    • Patrick von Platen's avatar
      make blenderbot test slow (#11395) · 74e84f1f
      Patrick von Platen authored
      74e84f1f
    • Patrick von Platen's avatar
      [Flax] Big FlaxBert Refactor (#11364) · 8c9b5fcb
      Patrick von Platen authored
      * improve flax
      
      * refactor
      
      * typos
      
      * Update src/transformers/modeling_flax_utils.py
      
      * Apply suggestions from code review
      
      * Update src/transformers/modeling_flax_utils.py
      
      * fix typo
      
      * improve error tolerance
      
      * typo
      
      * correct nasty saving bug
      
      * fix from pretrained
      
      * correct tree map
      
      * add note
      
      * correct weight tying
      8c9b5fcb
  5. 22 Apr, 2021 1 commit
  6. 21 Apr, 2021 2 commits
    • Sylvain Gugger's avatar
      Examples reorg (#11350) · dabeb152
      Sylvain Gugger authored
      
      
      * Base move
      
      * Examples reorganization
      
      * Update references
      
      * Put back test data
      
      * Move conftest
      
      * More fixes
      
      * Move test data to test fixtures
      
      * Update path
      
      * Apply suggestions from code review
      Co-authored-by: default avatarLysandre Debut <lysandre@huggingface.co>
      
      * Address review comments and clean
      Co-authored-by: default avatarLysandre Debut <lysandre@huggingface.co>
      dabeb152
    • Nicolas Patry's avatar
      Removed `max_length` from being mandatory within `generate`. (#11314) · aad95c7c
      Nicolas Patry authored
      * Removed `max_length` from being mandatory within `generate`.
      
      - Moving on to fully using `StoppingCriteria` for `greedy` and `sample`
      modes.
      - `max_length` still used for `beam_search` and `group_beam_search`
      (Follow up PR)
      - Fixes a bug with MaxLengthStoppingCriteria (we should stop as soon a
      we hit the max_length, the comparison needs to be or equal, that affects
      the tests).
      - Added options to use `logits_processor` and `stopping_criteria`
      directly within `generate` function (so some users can define their own
      `logits_processor` and `stopping_criteria`).
      - Modified the backward compat tests to make sure we issue a warning.
      
      * Fix `max_length` argument in `generate`.
      
      * Moving validate to being functional.
      
      - Renamed `smax_length` to `stoppping_max_length`.
      
      * Removing `logits_processor` and `stopping_criteria` from `generate`
      arguments.
      
      * Deepcopy.
      
      * Fix global variable name.
      aad95c7c
  7. 20 Apr, 2021 2 commits
  8. 16 Apr, 2021 2 commits
  9. 15 Apr, 2021 2 commits
  10. 14 Apr, 2021 2 commits
  11. 13 Apr, 2021 2 commits
  12. 12 Apr, 2021 2 commits
    • Philipp Schmid's avatar
      Sagemaker test docs update for framework upgrade (#11206) · f243a5ec
      Philipp Schmid authored
      * increased train_runtime for model parallelism
      
      * added documentation for framework upgrade
      f243a5ec
    • NielsRogge's avatar
      Add DeiT (PyTorch) (#11056) · 9f126097
      NielsRogge authored
      * First draft of deit
      
      * More improvements
      
      * Remove DeiTTokenizerFast from init
      
      * Conversion script works
      
      * Add DeiT to ViT conversion script
      
      * Add tests, add head model, add support for deit in vit conversion script
      
      * Update model checkpoint names
      
      * Update image_mean and image_std, set resample to bicubic
      
      * Improve docs
      
      * Docs improvements
      
      * Add DeiTForImageClassificationWithTeacher to init
      
      * Address comments by @sgugger
      
      * Improve feature extractors
      
      * Make fix-copies
      
      * Minor fixes
      
      * Address comments by @patil-suraj
      
      * All models uploaded
      
      * Fix tests
      
      * Remove labels argument from DeiTForImageClassificationWithTeacher
      
      * Fix-copies, style and quality
      
      * Fix tests
      
      * Fix typo
      
      * Multiple docs improvements
      
      * More docs fixes
      9f126097
  13. 09 Apr, 2021 4 commits
  14. 08 Apr, 2021 6 commits
  15. 07 Apr, 2021 1 commit