MCPcopy Create free account

hub / github.com/CStanKonrad/long_llama / types & classes

Types & classes52 in github.com/CStanKonrad/long_llama

↓ 4 callersClassLongLlamaMemCache
Class with LongLlama's memory cache Args: keys (`torch.FloatTensor` of shape `(batch_size, num_heads, mem_length, embed_size_per_hea
src/longllama_utils.py:30
↓ 3 callersClassJaxRNG
A convenient stateful Jax RNG wrapper. Can be used to wrap RNG inside pure function.
fot_continued_pretraining/EasyLM/jax_utils.py:24
↓ 3 callersClassLongLlamaRMSNorm
src/modeling_longllama.py:103
↓ 3 callersClassRMSNorm
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:378
↓ 2 callersClassCarry
fot_continued_pretraining/EasyLM/bpt.py:156
↓ 2 callersClassFlaxLLaMAForCausalLMModule
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:1129
↓ 2 callersClassLongLlamaDecoderLayer
src/modeling_longllama.py:483
↓ 2 callersClassLongLlamaModel
Transformer decoder consisting of *config.num_hidden_layers* layers. Each layer is a [`LongLlamaDecoderLayer`] Args: config: LlamaCo
src/modeling_longllama.py:708
↓ 2 callersClassOptaxScheduledWeightDecayState
fot_continued_pretraining/EasyLM/optimizers.py:192
↓ 1 callersClassDataCollator
instruction_fine_tuning/data_processing.py:714
↓ 1 callersClassDatasetProcessingStats
instruction_fine_tuning/data_processing.py:593
↓ 1 callersClassDocAwareDataPipeline
Pipeline that assigns documents to the indexes of the batch. To be more precise, each document from token_source is assigned an index in the
fot_continued_pretraining/FoT/data_pipeline.py:89
↓ 1 callersClassFlaxLLaMABlockCollection
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:974
↓ 1 callersClassFlaxLLaMAModule
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:1053
↓ 1 callersClassHuggingfaceDataset
Huggingface dataset, where the dataset is loaded using the huggingface datasets.load_dataset() function.
fot_continued_pretraining/EasyLM/data.py:135
↓ 1 callersClassJsonDataset
JSON dataset, where each line of the data file contains a JSON dictionary with text fields.
fot_continued_pretraining/EasyLM/data.py:232
↓ 1 callersClassLLaMAConfig
r""" This is the configuration class to store the configuration of a [`~LLaMAModel`]. It is used to instantiate an LLaMA model according to th
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:169
↓ 1 callersClassLLaMATokenizer
Construct a LLaMA tokenizer. Based on byte-level Byte-Pair-Encoding. Args: vocab_file (`str`): Path to the vocabulary fil
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:1235
↓ 1 callersClassLongLlamaAttention
Multi-headed attention from 'Attention Is All You Need' paper with FoT modifications
src/modeling_longllama.py:203
↓ 1 callersClassLongLlamaMLP
src/modeling_longllama.py:185
↓ 1 callersClassLongLlamaMemConfig
Class for configuring memory caches for LongLlama model. Args: positionals (`boolean`) Whether to use positional embeddi
src/longllama_utils.py:8
↓ 1 callersClassLongLlamaModelOutputWithPast
Based on BaseModelOutputWithPast Args: last_hidden_state (`torch.FloatTensor` of shape `(batch_size, sequence_length, hidden_size)`)
src/modeling_longllama.py:53
↓ 1 callersClassLongLlamaRotaryEmbedding
src/modeling_longllama.py:121
↓ 1 callersClassMixedTuneDataset
instruction_fine_tuning/data_processing.py:644
↓ 1 callersClassSingleTuneDataset
For handling a single dataset. data_args should be separated using separate_data_args.
instruction_fine_tuning/data_processing.py:533
↓ 1 callersClassStreamingCheckpointer
Custom msgpack checkpointer that saves large train states by serializing and saving tensors one by one in a streaming fashion. Avoids running
fot_continued_pretraining/EasyLM/checkpoint.py:17
↓ 1 callersClassTextProcessor
Example processor that converts a dictionary of texts into tokens.
fot_continued_pretraining/EasyLM/data.py:52
ClassAdamWOptimizerFactory
AdamW optimizer with cosine schedule.
fot_continued_pretraining/EasyLM/optimizers.py:118
ClassDataArgs
instruction_fine_tuning/arguments.py:16
ClassDataPipeline
Base class for the data pipeline. token_source should generate tuples consisting of (tokens_from_doc, loss_mask, name_of_the_data_source)
fot_continued_pretraining/FoT/data_pipeline.py:19
ClassDatasetFactory
Datset builder class.
fot_continued_pretraining/EasyLM/data.py:20
ClassFlaxLLaMAAttention
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:453
ClassFlaxLLaMABlock
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:733
ClassFlaxLLaMAForCausalLM
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:1191
ClassFlaxLLaMAMLP
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:692
ClassFlaxLLaMAModel
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:1118
ClassFlaxLLaMAPreTrainedModel
An abstract class to handle weights initialization and a simple interface for downloading and loading pretrained models.
fot_continued_pretraining/EasyLM/models/llama/llama_model.py:827
ClassFlaxTemperatureLogitsWarper
JIT traceable version of FlaxLogitsWarper that performs temperature scaling.
fot_continued_pretraining/EasyLM/jax_utils.py:83
ClassJaxDistributedConfig
Utility class for initializing JAX distributed.
fot_continued_pretraining/EasyLM/jax_utils.py:50
ClassKPackingDAPipeline
Pipeline that assigns multiple (k) indexes of the batch to a single doc. It achieves this by using DocAwareDataPipeline with k times smaller
fot_continued_pretraining/FoT/data_pipeline.py:200
ClassLinearPipeline
Pipeline that concatenates docs/examples sequentially to create the batch.
fot_continued_pretraining/FoT/data_pipeline.py:40
ClassLogAggregator
fot_continued_pretraining/EasyLM/logging_utils.py:25
ClassLongLlamaConfig
r""" This is the configuration class to store the configuration of a [`LongLlamaModel`]. It is used to instantiate an LongLLaMA model accordin
src/configuration_longllama.py:33
ClassLongLlamaForCausalLM
src/modeling_longllama.py:1156
ClassLongLlamaForSequenceClassification
src/modeling_longllama.py:1352
ClassLongLlamaPreTrainedModel
src/modeling_longllama.py:584
ClassModelArgs
instruction_fine_tuning/arguments.py:6
ClassOptimizerFactory
Configurable optax optimizer factory.
fot_continued_pretraining/EasyLM/optimizers.py:20
ClassPalmOptimizerFactory
PaLM optimizer factory. This optimizer implements the optimizer described in the PaLM paper: https://arxiv.org/abs/2204.02311
fot_continued_pretraining/EasyLM/optimizers.py:60
ClassTextToToken
fot_continued_pretraining/FoT/data_pipeline.py:238
ClassTokenFilter
Filters out examples that have less than min_example_length tokens. Collects statistics about token_source (averaged over num_stat_samples).
fot_continued_pretraining/FoT/data_pipeline.py:249
ClassTokenizationArgs
instruction_fine_tuning/arguments.py:264