MCPcopy Create free account

hub / github.com/THUDM/GLM / types & classes

Types & classes200 in github.com/THUDM/GLM

↓ 46 callersClassCommandToken
data_utils/tokenization.py:154
↓ 38 callersClassInputExample
A raw input example consisting of one or two segments of text and a label
tasks/data_utils.py:43
↓ 9 callersClassTokenization
Tokenization object to hold tokenization, (processed text),and original text. Can hold tokenization as Ids or tokens. It also holds
data_utils/tokenization.py:56
↓ 8 callersClassLazyLoader
Arguments: path: path to directory where array entries are concatenated into one big string file and the .len file are locate
data_utils/lazy_loader.py:122
↓ 7 callersClassBertModel
BERT model ("Bidirectional Embedding Representations from a Transformer"). Params: config: a BertConfig class instance with the configura
model/modeling_bert.py:852
↓ 7 callersClassTypeToken
data_utils/tokenization.py:190
↓ 6 callersClassLazyWriter
data_utils/lazy_loader.py:62
↓ 5 callersClassColumnParallelLinear
Linear layer with column parallelism. The linear layer is defined as Y = XA + b. A is parallelized along its second dimension as A = [A_1, ..
mpu/layers.py:179
↓ 5 callersClassSuperGlueDataset
tasks/superglue/dataset.py:130
↓ 4 callersClassBertLayerNorm
model/modeling_bert.py:271
↓ 4 callersClassFakeDataloader
tasks/data_utils.py:349
↓ 3 callersClassRowParallelLinear
Linear layer with row parallelism. The linear layer is defined as Y = XA + b. A is parallelized along its first dimension and X along its sec
mpu/layers.py:246
↓ 2 callersClassAnnealingLR
Anneals the learning rate from start to zero along a cosine curve.
learning_rates.py:22
↓ 2 callersClassBeamSearchScorer
r""" :class:`transformers.BeamScorer` implementing standard beam search decoding. Adapted in part from `Facebook's XLM beam search code <
generation_utils.py:141
↓ 2 callersClassBertLMPredictionHead
model/modeling_bert.py:611
↓ 2 callersClassBlankLMDataset
tasks/seq2seq/dataset.py:651
↓ 2 callersClassConstructBlockStrategy
blocklm_utils.py:30
↓ 2 callersClassCustomizationDataset
tasks/seq2seq/dataset.py:779
↓ 2 callersClassDynamicLossScaler
Class that manages dynamic loss scaling. It is recommended to use :class:`DynamicLossScaler` indirectly, by supplying ``dynamic_loss_scale
fp16/loss_scaler.py:63
↓ 2 callersClassExtractionDataset
tasks/seq2seq/dataset.py:553
↓ 2 callersClassGLMForSequenceClassification
model/downstream.py:148
↓ 2 callersClassIdentityLayer
mpu/tests/commons.py:25
↓ 2 callersClassIdentityLayer2D
mpu/tests/test_layers.py:178
↓ 2 callersClassIdentityLayer3D
mpu/tests/test_layers.py:319
↓ 2 callersClassLMDataset
tasks/language_model/dataset.py:12
↓ 2 callersClassMultiTaskDataset
configure_data.py:35
↓ 2 callersClassParallelMLP
MLP for GPT2. MLP will take the input with h hidden state, project it to 4*h hidden dimension, perform gelu transformation, and project the
mpu/transformer.py:343
↓ 2 callersClassParallelSelfAttention
Parallel self-attention layer for GPT2. Self-attention layer takes input with size [b, s, h] where b is the batch size, s is the sequence len
mpu/transformer.py:154
↓ 2 callersClassSeq2SeqDataset
tasks/seq2seq/dataset.py:420
↓ 2 callersClassTimers
Group of timers.
utils.py:113
↓ 2 callersClassXStanceProcessor
Processor for the X-Stance data set.
tasks/superglue/dataset.py:1115
↓ 1 callersClassBasicTokenizer
Runs basic tokenization (punctuation splitting, lower casing, etc.).
data_utils/wordpiece.py:176
↓ 1 callersClassBeamHypotheses
generation_utils.py:344
↓ 1 callersClassBertAttention
model/modeling_bert.py:437
↓ 1 callersClassBertConfig
Configuration class to store the configuration of a `BertModel`.
model/modeling_bert.py:166
↓ 1 callersClassBertEmbeddings
Construct the embeddings from word, position and token_type embeddings.
model/modeling_bert.py:287
↓ 1 callersClassBertEncoder
model/modeling_bert.py:526
↓ 1 callersClassBertIntermediate
model/modeling_bert.py:456
↓ 1 callersClassBertLayer
model/modeling_bert.py:512
↓ 1 callersClassBertOnlyMLMHead
model/modeling_bert.py:652
↓ 1 callersClassBertOnlyNSPHead
model/modeling_bert.py:662
↓ 1 callersClassBertOutput
model/modeling_bert.py:477
↓ 1 callersClassBertPooler
model/modeling_bert.py:575
↓ 1 callersClassBertPreTrainingHeads
model/modeling_bert.py:672
↓ 1 callersClassBertPredictionHeadTransform
model/modeling_bert.py:590
↓ 1 callersClassBertSelfAttention
model/modeling_bert.py:350
↓ 1 callersClassBertSelfOutput
model/modeling_bert.py:402
↓ 1 callersClassBertSentencepairDataset
Dataset containing sentencepairs for BERT training. Each index corresponds to a randomly generated sentence pair. Arguments: ds (Data
data_utils/datasets.py:840
↓ 1 callersClassBertWordPieceTokenizer
Loads a pretrained WordPiece tokenizer from `cache_dir` for tokenization in BERT training. Default to bert-large-uncased tokenizer.
data_utils/tokenization.py:784
↓ 1 callersClassBlankLMEvaluater
tasks/seq2seq/evaluate.py:409
↓ 1 callersClassBlockDataset
data_utils/datasets.py:570
↓ 1 callersClassCMRCProcessor
tasks/seq2seq/dataset.py:108
↓ 1 callersClassChineseSPTokenizer
data_utils/tokenization.py:1137
↓ 1 callersClassConcatDataset
Dataset to concatenate multiple datasets. Purpose: useful to assemble different existing datasets, possibly large-scale datasets as the c
data_utils/datasets.py:57
↓ 1 callersClassCudaRNGStatesTracker
Tracker for the cuda RNG states. Using the `add` method, a cuda rng state is initialized based on the input `seed` and is assigned to `name`.
mpu/random.py:119
↓ 1 callersClassDataConfig
configure_data.py:95
↓ 1 callersClassDecoderEvaluater
tasks/seq2seq/evaluate.py:250
↓ 1 callersClassEncoder
data_utils/sp_tokenizer.py:34
↓ 1 callersClassEncoder_SP
data_utils/sp_tokenizer.py:98
↓ 1 callersClassFP16_Module
fp16/fp16.py:67
↓ 1 callersClassFP16_Optimizer
:class:`FP16_Optimizer` is designed to wrap an existing PyTorch optimizer, and manage static or dynamic loss scaling and master weights in a
fp16/fp16.py:86
↓ 1 callersClassGLMForMultiTokenCloze
model/downstream.py:8
↓ 1 callersClassGLMForMultiTokenClozeFast
model/downstream.py:56
↓ 1 callersClassGLMForSingleTokenCloze
model/downstream.py:114
↓ 1 callersClassGLMModel
GLM Language model. The output of the forward method are the logits (parallel or serial depending on the `parallel_output` flag.
model/modeling_glm.py:40
↓ 1 callersClassGPT2BPETokenizer
data_utils/tokenization.py:933
↓ 1 callersClassGPT2Dataset
data_utils/datasets.py:715
↓ 1 callersClassLambadaDataset
tasks/language_model/dataset.py:73
↓ 1 callersClassLogitsProcessorList
This class can be used to create a list of :class:`~transformers.LogitsProcessor` or :class:`~transformers.LogitsWarper` to subsequently proc
generation_utils.py:402
↓ 1 callersClassLossScaler
Class that manages a static loss scale. This class is intended to interact with :class:`FP16_Optimizer`, and should not be directly manipu
fp16/loss_scaler.py:26
↓ 1 callersClassMinLengthLogitsProcessor
r""" :class:`transformers.LogitsProcessor` enforcing a min-length by setting EOS probability to 0. Args: min_length (:obj:`int`):
generation_utils.py:416
↓ 1 callersClassMultiChoiceDataset
tasks/superglue/dataset.py:64
↓ 1 callersClassNLTKSegmenter
data_utils/extraction.py:9
↓ 1 callersClassNoRepeatNGramLogitsProcessor
r""" :class:`transformers.LogitsProcessor` that enforces no repetition of n-grams. See `Fairseq <https://github.com/pytorch/fairseq/blob/a07cb
generation_utils.py:444
↓ 1 callersClassParallelCrossAttention
Parallel cross-attention layer for Transformer
mpu/transformer.py:57
↓ 1 callersClassParallelDecoderLayer
A single layer transformer for GPT2. We use the following notation: h: hidden size n: number of attention heads b: batch
mpu/transformer.py:391
↓ 1 callersClassParallelTransformerLayer
A single layer transformer for GPT2. We use the following notation: h: hidden size n: number of attention heads b: batch
mpu/transformer.py:492
↓ 1 callersClassPositionalEmbedding
mpu/transformer.py:38
↓ 1 callersClassProcessorTokenizer
callable class that runs a preprocessing, as well as tokenization step, on input text.
data_utils/lazy_loader.py:104
↓ 1 callersClassPromptSpell
model/prompt.py:5
↓ 1 callersClassSQuADGenerationProcessor
tasks/seq2seq/dataset.py:149
↓ 1 callersClassSQuADProcessor
tasks/seq2seq/dataset.py:190
↓ 1 callersClassSplitDataset
Dataset wrapper to access a subset of another dataset. Purpose: useful to index into existing datasets, possibly large-scale datasets as
data_utils/datasets.py:143
↓ 1 callersClassSummmaryProcessor
tasks/seq2seq/dataset.py:60
↓ 1 callersClassTokenizer
Tokenizer object that handles text tokenization, command tokens, and type tokens. Command tokens and text tokens are stored together in o
data_utils/tokenization.py:216
↓ 1 callersClassWordpieceTokenizer
Runs WordPiece tokenization.
data_utils/wordpiece.py:293
↓ 1 callersClassXLDataset
data_utils/datasets.py:501
↓ 1 callersClassXSumProcessor
tasks/seq2seq/dataset.py:362
↓ 1 callersClasstofp16
Utility module that implements:: def forward(self, input): return input.half()
fp16/fp16util.py:24
ClassAFQMCPVP
tasks/superglue/pvp.py:1051
ClassAFQMCProcessor
Processor for the AFQMC data set (CLUE version).
tasks/superglue/dataset.py:961
ClassAgnewsPVP
tasks/superglue/pvp.py:907
ClassAgnewsProcessor
Processor for the AG news data set.
tasks/superglue/dataset.py:994
ClassAxBProcessor
Processor for the AX-B diagnostic data set.
tasks/superglue/dataset.py:359
ClassAxGProcessor
Processor for the AX-G diagnostic data set.
tasks/superglue/dataset.py:349
ClassBeamScorer
Abstract base class for all beam scorers that are used for :meth:`~transformers.PretrainedModel.beam_search` and :meth:`~transformers.Pretrai
generation_utils.py:112
ClassBertBaseData
data_utils/corpora.py:483
ClassBertData
data_utils/corpora.py:404
ClassBertForMaskedLM
BERT model with the masked language modeling head. This module comprises the BERT model followed by the masked language modeling head. Params
model/modeling_bert.py:1019
ClassBertForMultipleChoice
BERT model for multiple choice tasks. This module is composed of the BERT model with a linear layer on top of the pooled output. Params:
model/modeling_bert.py:1214
next →1–100 of 200, ranked by callers