MCPcopy Create free account

hub / github.com/649453932/Bert-Chinese-Text-Classification-Pytorch / functions

Functions349 in github.com/649453932/Bert-Chinese-Text-Classification-Pytorch

Methodfrom_pretrained
Instantiate a pre-processed corpus.
pytorch_pretrained/tokenization_transfo_xl.py:452
Methodfrom_pretrained
Instantiate a GPT2PreTrainedModel from a pre-trained model file or a pytorch state dict. Download and cache the pre-trained model fil
pytorch_pretrained/modeling_gpt2.py:365
Methodfrom_pretrained
Instantiate a BertPreTrainedModel from a pre-trained model file or a pytorch state dict. Download and cache the pre-trained model fil
pytorch_pretrained/modeling.py:526
Methodfrom_pretrained
Instantiate a OpenAIGPTPreTrainedModel from a pre-trained model file or a pytorch state dict. Download and cache the pre-trained mode
pytorch_pretrained/modeling_openai.py:422
Functiongelu
(x)
pytorch_pretrained/modeling_gpt2.py:99
Functiongelu
Implementation of the gelu activation function. For information: OpenAI GPT's gelu is slightly different (and gives slightly different results
pytorch_pretrained/modeling.py:118
Functiongelu
(x)
pytorch_pretrained/modeling_openai.py:116
Functionget_file_extension
(path, dot=True, lower=True)
pytorch_pretrained/file_utils.py:267
Methodget_iterator
(self, split, *args, **kwargs)
pytorch_pretrained/tokenization_transfo_xl.py:540
Functionget_lm_corpus
(datadir, dataset)
pytorch_pretrained/tokenization_transfo_xl.py:557
Methodget_lr
:param step: which of t_total steps we're on :param nowarn: set to True to suppress warning regarding training beyond specified '
pytorch_pretrained/optimization.py:53
Methodget_lr_
(self, progress)
pytorch_pretrained/optimization.py:82
Methodget_lr_
(self, progress)
pytorch_pretrained/optimization.py:103
Methodget_lr_
(self, progress)
pytorch_pretrained/optimization.py:121
Methodget_lr_
(self, progress)
pytorch_pretrained/optimization.py:141
Methodget_lr_
(self, progress)
pytorch_pretrained/optimization.py:156
Methodget_lr_
(self, progress)
pytorch_pretrained/optimization.py:168
Methodget_varlen_iter
(self, start=0, std=5, min_len=5, max_deviation=3)
pytorch_pretrained/tokenization_transfo_xl.py:321
Methodinit_bert_weights
Initialize the weights.
pytorch_pretrained/modeling.py:512
Methodinit_mems
(self, data)
pytorch_pretrained/modeling_transfo_xl.py:1352
Functioninit_network
(model, method='xavier', exclude='embedding', seed=123)
train_eval.py:13
Methodinit_weights
Initialize the weights.
pytorch_pretrained/modeling_transfo_xl.py:846
Methodinit_weights
Initialize the weights.
pytorch_pretrained/modeling_gpt2.py:351
Methodlog_prob
r""" Computes log probabilities for all :math:`n\_classes` From: https://github.com/pytorch/pytorch/blob/master/torch/nn/modules/adaptive.py
pytorch_pretrained/modeling_transfo_xl_utilities.py:198
Functionlru_cache
()
pytorch_pretrained/tokenization_gpt2.py:31
Functionread_set_from_file
Extract a de-duped collection (set) of text from a file. Expected file format is one item per line.
pytorch_pretrained/file_utils.py:255
Methodreset_length
(self, tgt_len, ext_len, mem_len)
pytorch_pretrained/modeling_transfo_xl.py:1349
Functions3_request
Wrapper function for s3 requests in order to create more helpful error messages.
pytorch_pretrained/file_utils.py:131
Methodsave_vocabulary
Save the tokenizer vocabulary and merge files to a directory.
pytorch_pretrained/tokenization_openai.py:280
Methodsave_vocabulary
Save the tokenizer vocabulary to a directory or file.
pytorch_pretrained/tokenization.py:137
Methodsave_vocabulary
Save the tokenizer vocabulary and merge files to a directory.
pytorch_pretrained/tokenization_gpt2.py:268
Methodsave_vocabulary
Save the tokenizer vocabulary to a directory or file.
pytorch_pretrained/tokenization_transfo_xl.py:147
Methodset_num_special_tokens
(self, num_special_tokens)
pytorch_pretrained/modeling_transfo_xl.py:887
Methodset_num_special_tokens
(self, num_special_tokens)
pytorch_pretrained/modeling_openai.py:418
Methodset_num_special_tokens
Update input and output embeddings with new embedding matrice Make sure we are sharing the embeddings
pytorch_pretrained/modeling_openai.py:710
Methodset_num_special_tokens
Update input and output embeddings with new embedding matrice Make sure we are sharing the embeddings
pytorch_pretrained/modeling_openai.py:800
Methodset_tied
(self)
pytorch_pretrained/modeling_gpt2.py:348
Methodset_tied
Make sure we are sharing the embeddings
pytorch_pretrained/modeling_gpt2.py:690
Methodstep
Performs a single optimization step. Arguments: closure (callable, optional): A closure that reevaluates the model
pytorch_pretrained/optimization_openai.py:70
Functionswish
(x)
pytorch_pretrained/modeling.py:127
Functionswish
(x)
pytorch_pretrained/modeling_openai.py:120
Methodto_json_file
Save this instance to a json file.
pytorch_pretrained/modeling_transfo_xl.py:318
Methodto_json_file
Save this instance to a json file.
pytorch_pretrained/modeling_gpt2.py:180
Methodto_json_file
Save this instance to a json file.
pytorch_pretrained/modeling.py:222
Methodto_json_file
Save this instance to a json file.
pytorch_pretrained/modeling_openai.py:226
Methodtokenize
Tokenizes a piece of text.
pytorch_pretrained/tokenization.py:215
Methodtokenize
Tokenizes a piece of text into its word pieces. This uses a greedy longest-match-first algorithm to perform tokenization using the gi
pytorch_pretrained/tokenization.py:326
Methodtotal_tokens_embeddings
(self)
pytorch_pretrained/modeling_openai.py:196
Functionwrapper
(url, *args, **kwargs)
pytorch_pretrained/file_utils.py:138
← previous301–349 of 349, ranked by callers