MCPcopy Create free account

hub / github.com/XiangLi1999/PrefixTuning / functions

Functions3,725 in github.com/XiangLi1999/PrefixTuning

Methodis_fast
:obj:`bool`: Indicate whether this :class:`~transformers.BatchEncoding` was generated from the result of a :class:`~transformers.PreT
transformers/src/transformers/tokenization_utils_base.py:189
Methodis_fast
(self)
transformers/src/transformers/tokenization_utils.py:125
Methodis_gpu
(self)
transformers/src/transformers/benchmark/benchmark_args.py:113
Methodis_gpu
(self)
transformers/src/transformers/benchmark/benchmark_args_tf.py:134
Methodis_initialized
Returns :obj:`True` if index is already initialized.
transformers/src/transformers/retrieval_rag.py:74
Methodis_initialized
(self)
transformers/src/transformers/retrieval_rag.py:151
Methodis_initialized
(self)
transformers/src/transformers/retrieval_rag.py:225
Methodis_local_master
Whether or not this process is the local (e.g., on one machine if training in a distributed fashion on several machines) main process
transformers/src/transformers/trainer_prefix.py:2588
Methodis_local_master
Whether or not this process is the local (e.g., on one machine if training in a distributed fashion on several machines) main process
transformers/src/transformers/trainer.py:1164
Methodis_local_master
Whether or not this process is the local (e.g., on one machine if training in a distributed fashion on several machines) main process
gpt2/trainer_prefix.py:1260
Functionis_memory_tracing_enabled
()
transformers/src/transformers/benchmark/benchmark_utils.py:103
Methodis_tpu
(self)
transformers/src/transformers/benchmark/benchmark_args.py:93
Methodis_tpu
(self)
transformers/src/transformers/benchmark/benchmark_args_tf.py:113
Methodis_valid_mbart
Is the configuration aligned with the MBART paper.
transformers/src/transformers/configuration_bart.py:209
Functionkeras_serializable
Decorate a Keras Layer class to support Keras serialization. This is done by: 1. Adding a :obj:`transformers_config` dict to the Keras
transformers/src/transformers/modeling_tf_utils.py:60
Methodload_dpr_model
(self)
transformers/src/transformers/convert_dpr_original_checkpoint_to_pytorch.py:42
Methodload_dpr_model
(self)
transformers/src/transformers/convert_dpr_original_checkpoint_to_pytorch.py:59
Methodload_dpr_model
(self)
transformers/src/transformers/convert_dpr_original_checkpoint_to_pytorch.py:76
Methodload_hf_checkpoint
(self, *args, **kwargs)
seq2seq/lightning_base.py:197
Methodload_hf_checkpoint
(self, *args, **kwargs)
seq2seq/lightning_base.py:498
Functionload_json
(path)
seq2seq/utils.py:366
Functionload_pytorch_model_in_tf2_model
Load pytorch checkpoints in a TF 2.0 model
transformers/src/transformers/modeling_tf_pytorch_utils.py:97
Functionload_tf_weights_in_gpt2
Load tf checkpoints in a pytorch model
transformers/src/transformers/modeling_gpt2_adapter.py:63
Methodlogits
(self)
transformers/src/transformers/modeling_transfo_xl.py:661
Functionlr_lambda
(current_step: int)
transformers/src/transformers/optimization.py:63
Functionmake_tatoeba_registry
(repo_path="Tatoeba-Challenge/models")
transformers/src/transformers/convert_marian_to_pytorch.py:385
Methodmask_token
:obj:`str`: Mask token, to use when training a model with masked-language modeling. Log an error if used while not having been set.
transformers/src/transformers/tokenization_utils_base.py:844
Methodmask_token_id
:obj:`Optional[int]`: Id of the mask token in the vocabulary, used when training a model with masked-language modeling. Returns :obj:
transformers/src/transformers/tokenization_utils_base.py:967
Methodmask_tokens
Prepare masked tokens inputs/labels for masked language modeling: 80% MASK, 10% random, 10% original.
transformers/src/transformers/data/data_collator.py:926
Methodmask_tokens
Prepare masked tokens inputs/labels for masked language modeling: 80% MASK, 10% random, 10% original.
transformers/src/transformers/data/data_collator.py:1143
Methodmax_len
:obj:`int`: **Deprecated** Kept here for backward compatibility. Now renamed to :obj:`model_max_length` to avoid ambiguity.
transformers/src/transformers/tokenization_utils_base.py:1317
Methodmax_len_sentences_pair
:obj:`int`: The maximum combined length of a pair of sentences that can be fed to the model.
transformers/src/transformers/tokenization_utils_base.py:1336
Methodmax_len_single_sentence
:obj:`int`: The maximum length of a sentence that can be fed to the model.
transformers/src/transformers/tokenization_utils_base.py:1329
Methodmax_position_embeddings
(self)
transformers/src/transformers/configuration_ctrl.py:124
Methodmax_position_embeddings
(self)
transformers/src/transformers/configuration_openai.py:163
Methodmax_position_embeddings
(self)
transformers/src/transformers/configuration_t5.py:112
Methodmax_position_embeddings
(self)
transformers/src/transformers/configuration_xlnet.py:216
Methodmax_position_embeddings
(self)
transformers/src/transformers/configuration_transfo_xl.py:182
Methodmax_position_embeddings
(self)
transformers/src/transformers/configuration_gpt2.py:172
Functionmish
(x)
transformers/src/transformers/activations_tf.py:36
Functionmish
(x)
transformers/src/transformers/modeling_mobilebert.py:143
Functionmish
(x)
transformers/src/transformers/activations.py:43
Functionmockenv
this is a convenience wrapper, that allows this: @mockenv(USE_CUDA=True, USE_TF=False) def test_something(): use_cuda = os.getenv("US
transformers/src/transformers/testing_utils.py:441
FunctionmodelForQuestionAnswering
r""" # Using torch.hub ! import torch model = torch.hub.load('huggingface/transformers', 'modelForQuestionAnswering', 'bert-b
transformers/hubconf.py:113
FunctionmodelForSequenceClassification
r""" # Using torch.hub ! import torch model = torch.hub.load('huggingface/transformers', 'modelForSequenceClassif
transformers/hubconf.py:94
FunctionmodelWithLMHead
r""" # Using torch.hub ! import torch model = torch.hub.load('huggingface/transformers', 'modelWithLMHead', 'bert-base-uncase
transformers/hubconf.py:76
Methodmodel_info
(self)
transformers/src/transformers/commands/serving.py:160
Methodmodel_names
(self)
transformers/src/transformers/benchmark/benchmark_args_utils.py:133
Methodmove_added_token
Moves an added token to a specific position in the vocab. This method should be used when resizing an embedding layer other than the
transformers/src/transformers/tokenization_transfo_xl.py:354
Functionmulti_process_func
(*args, **kwargs)
transformers/src/transformers/benchmark/benchmark_utils.py:77
Methodn_gpu
The number of replicas (CPUs, GPUs or TPU cores) used in this training.
transformers/src/transformers/training_args_tf.py:210
Methodn_gpu
The number of GPUs used by this process. Note: This will only be greater than one when you have multiple GPUs available
transformers/src/transformers/training_args.py:374
Methodn_gpu
(self)
transformers/src/transformers/benchmark/benchmark_args.py:109
Methodn_gpu
(self)
transformers/src/transformers/benchmark/benchmark_args_tf.py:128
Methodn_replicas
The number of replicas (CPUs, GPUs or TPU cores) used in this training.
transformers/src/transformers/training_args_tf.py:176
Methodn_token
(self)
transformers/src/transformers/configuration_xlnet.py:220
Methodn_token
(self)
transformers/src/transformers/configuration_transfo_xl.py:188
Methodn_words
(self)
transformers/src/transformers/configuration_xlm.py:232
Functionnested_detach
Detach `tensors` (even if it's a nested list/tuple of tensors).
transformers/src/transformers/trainer_utils.py:165
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_bart.py:202
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_ctrl.py:132
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_openai.py:171
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_fsmt.py:203
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_xlm.py:244
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_distilbert.py:133
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_t5.py:120
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_xlnet.py:232
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_transfo_xl.py:200
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_funnel.py:176
Methodnum_attention_heads
(self)
transformers/src/transformers/configuration_gpt2.py:180
Methodnum_blocks
(self)
transformers/src/transformers/configuration_funnel.py:184
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_ctrl.py:136
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_openai.py:175
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_xlm.py:248
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_distilbert.py:137
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_t5.py:124
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_xlnet.py:236
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_transfo_xl.py:204
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_funnel.py:180
Methodnum_hidden_layers
(self)
transformers/src/transformers/configuration_gpt2.py:184
Methodnum_labels
:obj:`int`: The number of labels for classification models.
transformers/src/transformers/configuration_utils.py:226
Methodnum_parameters
Get the number of (optionally, trainable) parameters in the model. Args: only_trainable (:obj:`bool`, `optional`, defaul
transformers/src/transformers/modeling_tf_utils.py:43
Methodnum_special_tokens_to_add
Returns the number of added tokens when encoding a sequence with special tokens. .. note:: This encodes a dummy input an
transformers/src/transformers/tokenization_utils_fast.py:214
Methodnum_special_tokens_to_add
Just EOS
transformers/src/transformers/tokenization_pegasus.py:65
Methodnum_special_tokens_to_add
Returns the number of added tokens when encoding a sequence with special tokens. .. note:: This encodes a dummy input an
transformers/src/transformers/tokenization_utils.py:218
Methodnum_tokens_in_example
(i)
seq2seq/utils.py:149
Methodon_batch_end
(self, trainer, pl_module)
seq2seq/callbacks.py:24
Methodon_batch_end
(self, trainer, pl_module)
seq2seq/lightning_base.py:653
Methodon_epoch_end
(self)
seq2seq/finetune.py:203
Methodon_save_checkpoint
(self, checkpoint: Dict[str, Any], filepath=None)
seq2seq/lightning_base.py:284
Methodon_test_end
(self, trainer: pl.Trainer, pl_module: pl.LightningModule)
seq2seq/callbacks.py:76
Methodon_test_end
(self, trainer: pl.Trainer, pl_module: pl.LightningModule)
seq2seq/lightning_base.py:666
Methodon_train_start
(self, trainer, pl_module)
seq2seq/callbacks.py:65
Methodon_validation_end
(self, trainer: pl.Trainer, pl_module)
seq2seq/callbacks.py:81
Methodon_validation_end
(self, trainer: pl.Trainer, pl_module: pl.LightningModule)
seq2seq/lightning_base.py:658
Methodpad
(self)
seq2seq/finetune.py:185
Methodpad
(self)
seq2seq/finetune.py:522
Methodpad_token
:obj:`str`: Padding token. Log an error if used while not having been set.
transformers/src/transformers/tokenization_utils_base.py:823
Methodpad_token_id
:obj:`Optional[int]`: Id of the padding token in the vocabulary. Returns :obj:`None` if the token has not been set.
transformers/src/transformers/tokenization_utils_base.py:938
Methodpad_token_type_id
:obj:`int`: Id of the padding token type in the vocabulary.
transformers/src/transformers/tokenization_utils_base.py:948
← previousnext →3,301–3,400 of 3,725, ranked by callers