transformers/tests
Julien Plu bf7f79cd57
Optional layers (#8961)
* Apply on BERT and ALBERT

* Update TF Bart

* Add input processing to TF BART

* Add input processing for TF CTRL

* Add input processing to TF Distilbert

* Add input processing to TF DPR

* Add input processing to TF Electra

* Add deprecated arguments

* Add input processing to TF XLM

* remove unused imports

* Add input processing to TF Funnel

* Add input processing to TF GPT2

* Add input processing to TF Longformer

* Add input processing to TF Lxmert

* Apply style

* Add input processing to TF Mobilebert

* Add input processing to TF GPT

* Add input processing to TF Roberta

* Add input processing to TF T5

* Add input processing to TF TransfoXL

* Apply style

* Rebase on master

* Fix wrong model name

* Fix BART

* Apply style

* Put the deprecated warnings in the input processing function

* Remove the unused imports

* Raise an error when len(kwargs)>0

* test ModelOutput instead of TFBaseModelOutput

* Address Patrick's comments

* Address Patrick's comments

* Add boolean processing for the inputs

* Take into account the optional layers

* Add missing/unexpected weights in the other models

* Apply style

* rename parameters

* Apply style

* Remove useless

* Remove useless

* Remove useless

* Update num parameters

* Fix tests

* Address Patrick's comment

* Remove useless attribute
2020-12-08 09:14:09 -05:00
..
fixtures Add new token classification example (#8340) 2020-11-09 11:39:55 -05:00
__init__.py GPU text generation: mMoved the encoded_prompt to correct device 2020-01-06 15:11:12 +01:00
conftest.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_activations_tf.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_activations.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_benchmark_tf.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_benchmark.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_cli.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_configuration_auto.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_configuration_common.py [PretrainedConfig] Fix save pretrained config for edge case (#7943) 2020-10-22 15:39:01 +02:00
test_data_collator.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_doc_samples.py Fix ignore list behavior in doctests (#8213) 2020-11-02 08:47:37 -05:00
test_file_utils.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_flax_auto.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_generation_beam_search.py Refactoring the generate() function (#6949) 2020-11-03 16:04:22 +01:00
test_generation_logits_process.py Adding PrefixConstrainedLogitsProcessor (#8529) 2020-11-18 17:06:25 +01:00
test_generation_utils.py fix flaky ci (#8694) 2020-11-20 22:07:21 +01:00
test_hf_api.py transformers-cli: LFS multipart uploads (> 5GB) (#8663) 2020-12-07 16:38:39 -05:00
test_hf_argparser.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_logging.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_model_card.py GPU text generation: mMoved the encoded_prompt to correct device 2020-01-06 15:11:12 +01:00
test_model_output.py Add tests and fix various bugs in ModelOutput (#7073) 2020-09-11 12:01:33 -04:00
test_modeling_albert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_auto.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_bart.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_bert_generation.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_bert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_blenderbot.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_camembert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_common.py Patch model parallel test (#8920) 2020-12-03 17:15:47 -05:00
test_modeling_ctrl.py Ctrl for sequence classification (#8812) 2020-12-01 09:49:27 +01:00
test_modeling_deberta.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_modeling_distilbert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_dpr.py Fix dpr<>bart config for RAG (#8808) 2020-11-27 16:26:45 +01:00
test_modeling_electra.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_encoder_decoder.py Fix bug in x-attentions output for roberta and harden test to catch it (#8660) 2020-11-23 13:28:29 +01:00
test_modeling_flaubert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_flax_bert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_flax_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_fsmt.py [PyTorch] Refactor Resize Token Embeddings (#8880) 2020-12-02 19:19:50 +01:00
test_modeling_funnel.py Switch return_dict to True by default. (#8530) 2020-11-16 11:43:00 -05:00
test_modeling_gpt2.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_layoutlm.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_longformer.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_lxmert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_marian.py consistent ignore keys + make private (#8737) 2020-11-23 12:33:13 -08:00
test_modeling_mbart.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_mobilebert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_mt5.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_openai.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_pegasus.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_prophetnet.py Return correct Bart hidden state tensors (#8747) 2020-11-25 22:06:04 +01:00
test_modeling_rag.py Add T5 Encoder for Feature Extraction (#8717) 2020-11-30 08:34:40 +01:00
test_modeling_reformer.py [PyTorch] Refactor Resize Token Embeddings (#8880) 2020-12-02 19:19:50 +01:00
test_modeling_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_squeezebert.py Switch return_dict to True by default. (#8530) 2020-11-16 11:43:00 -05:00
test_modeling_t5.py [PyTorch] Refactor Resize Token Embeddings (#8880) 2020-12-02 19:19:50 +01:00
test_modeling_tf_albert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_auto.py Optional layers (#8961) 2020-12-08 09:14:09 -05:00
test_modeling_tf_bart.py New TF model inputs (#8602) 2020-11-24 13:55:00 -05:00
test_modeling_tf_bert.py Optional layers (#8961) 2020-12-08 09:14:09 -05:00
test_modeling_tf_blenderbot.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_camembert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_common.py New TF model inputs (#8602) 2020-11-24 13:55:00 -05:00
test_modeling_tf_ctrl.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_distilbert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_dpr.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_electra.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_flaubert.py Switch return_dict to True by default. (#8530) 2020-11-16 11:43:00 -05:00
test_modeling_tf_funnel.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_modeling_tf_gpt2.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_longformer.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_lxmert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_marian.py TFMarian, TFMbart, TFPegasus, TFBlenderbot (#7987) 2020-10-30 11:23:16 -04:00
test_modeling_tf_mbart.py TFMarian, TFMbart, TFPegasus, TFBlenderbot (#7987) 2020-10-30 11:23:16 -04:00
test_modeling_tf_mobilebert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_mt5.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_openai.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_pegasus.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_pytorch.py Optional layers (#8961) 2020-12-08 09:14:09 -05:00
test_modeling_tf_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_t5.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_transfo_xl.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_xlm_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_xlm.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_tf_xlnet.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_transfo_xl.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_xlm_prophetnet.py Ci test tf super slow (#8007) 2020-10-30 10:25:48 -04:00
test_modeling_xlm_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_xlm.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_modeling_xlnet.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_onnx.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_optimization_tf.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_optimization.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_common.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_conversational.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_feature_extraction.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_fill_mask.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_ner.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_question_answering.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_sentiment_analysis.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_summarization.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_text_generation.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_text2text_generation.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_translation.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_pipelines_zero_shot.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_retrieval_rag.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_skip_decorators.py [testing] rename skip targets + docs (#7863) 2020-10-20 04:39:13 -04:00
test_tokenization_albert.py [Dependencies|tokenizers] Make both SentencePiece and Tokenizers optional dependencies (#7659) 2020-10-18 20:51:24 +02:00
test_tokenization_auto.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_bart.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_barthez.py Add barthez model (#8393) 2020-11-27 12:31:42 -05:00
test_tokenization_bert_generation.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_bert_japanese.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_bert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_bertweet.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_blenderbot.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_camembert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_common.py Warning about too long input for fast tokenizers too (#8799) 2020-12-02 10:18:28 -05:00
test_tokenization_ctrl.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_deberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_distilbert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_dpr.py [Dependencies|tokenizers] Make both SentencePiece and Tokenizers optional dependencies (#7659) 2020-10-18 20:51:24 +02:00
test_tokenization_fsmt.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_funnel.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_gpt2.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_herbert.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_layoutlm.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_lxmert.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_marian.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_mbart.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_openai.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_pegasus.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_phobert.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_prophetnet.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_rag.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_reformer.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_squeezebert.py [Dependencies|tokenizers] Make both SentencePiece and Tokenizers optional dependencies (#7659) 2020-10-18 20:51:24 +02:00
test_tokenization_t5.py fix t5 token type ids (#8437) 2020-11-10 14:21:54 -05:00
test_tokenization_transfo_xl.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_utils.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_xlm_prophetnet.py Reorganize repo (#8580) 2020-11-16 21:43:42 -05:00
test_tokenization_xlm_roberta.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_xlm.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_tokenization_xlnet.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_trainer_callback.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_trainer_distributed.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_trainer_tpu.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_trainer_utils.py Add predict step accumulation (#7767) 2020-10-14 11:41:45 -04:00
test_trainer.py Better support for resuming training (#8878) 2020-12-01 13:45:21 -05:00
test_utils_check_copies.py Copyright (#8970) 2020-12-07 18:36:34 -05:00
test_versions_utils.py Copyright (#8970) 2020-12-07 18:36:34 -05:00