1. 27 Jan, 2021 1 commit
  2. 14 Jan, 2021 1 commit
  3. 13 Jan, 2021 1 commit
  4. 06 Jan, 2021 1 commit
  5. 18 Dec, 2020 1 commit
  6. 15 Dec, 2020 1 commit
  7. 01 Dec, 2020 1 commit
  8. 23 Nov, 2020 1 commit
    • Colin Brochtrup's avatar
      Add early stopping callback to pytorch trainer (#8581) · 8ffc01a7
      Colin Brochtrup authored
      * Add early stopping patience and minimum threshold metric must improve to prevent early stopping to pytorch trainer
      
      * Add early stopping test
      
      * Set patience counter to 0 if best metric not defined yet
      
      * Make early stopping a callback. Add callback event for updating the best metric for early stopping callback to trigger on.
      
      * Run make style
      
      * make funciton name sensible
      
      * Improve new argument docstring wording and hope that flakey CI test passes.
      
      * Use on_evaluation callback instead of custom. Remove some debug printing
      
      * Move early stopping arguments and state into early stopping callback
      
      * Run make style
      
      * Remove old code
      
      * Fix docs formatting. make style went rogue on me.
      
      * Remove copied attributes and fix variable
      
      * Add assertions on training arguments instead of mutating them. Move comment out of public docs.
      
      * Make separate test for early stopping callback. Add test of invalid arguments.
      
      * Run make style... I remembered before CI this time!
      
      * appease flake8
      
      * Add EarlyStoppingCallback to callback docs
      
      * Make docstring EarlyStoppingCallabck match other callbacks.
      
      * Fix typo in docs
      8ffc01a7
  9. 19 Nov, 2020 1 commit
  10. 18 Nov, 2020 1 commit
  11. 05 Nov, 2020 1 commit
  12. 03 Nov, 2020 1 commit
  13. 21 Oct, 2020 1 commit
  14. 19 Oct, 2020 1 commit
    • Julien Rossi's avatar
      Trainer with Iterable Dataset (#7858) · a09fe140
      Julien Rossi authored
      * fix 5990
      
      * accomodate iterable dataset without predefined length
      * set it as 1 use case: provide max_steps, and NO num_epochs
      * Is a merge of master and PR 5995
      
      * fix trainer test under TF
      
      * fix only for torch
      * TF trainer untouched
      * trainer tests are skipped when no torch
      
      * address comments
      
      * fix quality checks
      
      * remove torch.dataset from test_trainer
      
      * unnecessary inheritance
      * RegressionDataset implements all needed methods __len__ and __getitem__
      
      * fix quality checks
      
      * restore RegressionDataset
      
      * was wrongly under is_torch_available()
      a09fe140
  15. 18 Oct, 2020 1 commit
    • Thomas Wolf's avatar
      [Dependencies|tokenizers] Make both SentencePiece and Tokenizers optional dependencies (#7659) · ba8c4d0a
      Thomas Wolf authored
      * splitting fast and slow tokenizers [WIP]
      
      * [WIP] splitting sentencepiece and tokenizers dependencies
      
      * update dummy objects
      
      * add name_or_path to models and tokenizers
      
      * prefix added to file names
      
      * prefix
      
      * styling + quality
      
      * spliting all the tokenizer files - sorting sentencepiece based ones
      
      * update tokenizer version up to 0.9.0
      
      * remove hard dependency on sentencepiece 馃帀
      
      * and removed hard dependency on tokenizers 馃帀
      
      
      
      * update conversion script
      
      * update missing models
      
      * fixing tests
      
      * move test_tokenization_fast to main tokenization tests - fix bugs
      
      * bump up tokenizers
      
      * fix bert_generation
      
      * update ad fix several tokenizers
      
      * keep sentencepiece in deps for now
      
      * fix funnel and deberta tests
      
      * fix fsmt
      
      * fix marian tests
      
      * fix layoutlm
      
      * fix squeezebert and gpt2
      
      * fix T5 tokenization
      
      * fix xlnet tests
      
      * style
      
      * fix mbart
      
      * bump up tokenizers to 0.9.2
      
      * fix model tests
      
      * fix tf models
      
      * fix seq2seq examples
      
      * fix tests without sentencepiece
      
      * fix slow => fast  conversion without sentencepiece
      
      * update auto and bert generation tests
      
      * fix mbart tests
      
      * fix auto and common test without tokenizers
      
      * fix tests without tokenizers
      
      * clean up tests lighten up when tokenizers + sentencepiece are both off
      
      * style quality and tests fixing
      
      * add sentencepiece to doc/examples reqs
      
      * leave sentencepiece on for now
      
      * style quality split hebert and fix pegasus
      
      * WIP Herbert fast
      
      * add sample_text_no_unicode and fix hebert tokenization
      
      * skip FSMT example test for now
      
      * fix style
      
      * fix fsmt in example tests
      
      * update following Lysandre and Sylvain's comments
      
      * Update src/transformers/testing_utils.py
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      
      * Update src/transformers/testing_utils.py
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      
      * Update src/transformers/tokenization_utils_base.py
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      
      * Update src/transformers/tokenization_utils_base.py
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      Co-authored-by: default avatarSylvain Gugger <35901082+sgugger@users.noreply.github.com>
      ba8c4d0a
  16. 14 Oct, 2020 1 commit
  17. 13 Oct, 2020 1 commit
  18. 10 Oct, 2020 1 commit
  19. 05 Oct, 2020 1 commit
  20. 01 Oct, 2020 1 commit
    • Sylvain Gugger's avatar
      Clean the Trainer state (#7490) · 29baa8fa
      Sylvain Gugger authored
      * Trainer should not modify its TrainingArguments
      
      * Trainer should not modify its TrainingArguments
      
      * Trainer should not modify its TrainingArguments
      
      * Add test of resumed training
      
      * Fixes
      
      * Non multiGPU test
      
      * Clean Trainer state
      
      * Add more to the state
      
      * Documentation
      
      * One last test
      
      * Make resume training test more complete
      
      * Unwanted changes
      29baa8fa
  21. 29 Sep, 2020 2 commits
  22. 28 Sep, 2020 1 commit
  23. 22 Sep, 2020 1 commit
  24. 17 Sep, 2020 1 commit
  25. 15 Sep, 2020 3 commits
  26. 14 Sep, 2020 1 commit
  27. 10 Sep, 2020 2 commits
  28. 27 Aug, 2020 1 commit
  29. 26 Aug, 2020 1 commit
  30. 25 Aug, 2020 1 commit
  31. 20 Aug, 2020 1 commit
    • Sylvain Gugger's avatar
      Add tests to Trainer (#6605) · 573bdb0a
      Sylvain Gugger authored
      * Add tests to Trainer
      
      * Test if removing long breaks everything
      
      * Remove ugly hack
      
      * Fix distributed test
      
      * Use float for number of epochs
      573bdb0a
  32. 20 Jul, 2020 1 commit
    • Pradhy729's avatar
      Trainer support for iterabledataset (#5834) · 290b6e18
      Pradhy729 authored
      * Don't pass sampler for iterable dataset
      
      * Added check for test and eval dataloaders.
      
      * Formatting
      
      * Don't pass sampler for iterable dataset
      
      * Added check for test and eval dataloaders.
      
      * Formatting
      
      * Cleaner if nesting.
      
      * Added test for trainer and iterable dataset
      
      * Formatting for test
      
      * Fixed import when torch is available only.
      
      * Added require torch decorator to helper class
      
      * Moved dataset class inside unittest
      
      * Removed nested if and changed model in test
      
      * Checking torch availability for IterableDataset
      290b6e18
  33. 07 Jul, 2020 1 commit
    • Shashank Gupta's avatar
      Added data collator for permutation (XLNet) language modeling and related calls (#5522) · 3dcb748e
      Shashank Gupta authored
      * Added data collator for XLNet language modeling and related calls
      
      Added DataCollatorForXLNetLanguageModeling in data/data_collator.py
      to generate necessary inputs for language modeling training with
      XLNetLMHeadModel. Also added related arguments, logic and calls in
      examples/language-modeling/run_language_modeling.py.
      
      Resolves: #4739, #2008 (partially)
      
      * Changed name to `DataCollatorForPermutationLanguageModeling`
      
      Changed the name of `DataCollatorForXLNetLanguageModeling` to the more general `DataCollatorForPermutationLanguageModelling`.
      Removed the `--mlm` flag requirement for the new collator and defined a separate `--plm_probability` flag for its use.
      CTRL uses a CLM loss just like GPT and GPT-2, so should work out of the box with this script (provided `past` is taken care of
      similar to `mems` for XLNet).
      Changed calls and imports appropriately.
      
      * Added detailed comments, changed variable names
      
      Added more detailed comments to `DataCollatorForPermutationLanguageModeling` in `data/data_collator.py` to explain working. Also cleaned up variable names and made them more informative.
      
      * Added tests for new data collator
      
      Added tests in `tests/test_trainer.py` for DataCollatorForPermutationLanguageModeling based on those in DataCollatorForLanguageModeling. A specific test has been added to check for odd-length sequences.
      
      * Fixed styling issues
      3dcb748e
  34. 01 Jul, 2020 2 commits
  35. 18 Jun, 2020 1 commit