MCPcopy Create free account

hub / github.com/DevSinghSachan/art / functions

Functions712 in github.com/DevSinghSachan/art

↓ 92 callersFunctionget_args
Return arguments.
megatron/global_vars.py:39
↓ 89 callersFunctionprint_rank_0
If distributed is initialized print only on rank 0.
megatron/__init__.py:26
↓ 51 callersMethodsize
(self, index)
megatron/data/indexed_dataset.py:197
↓ 19 callersMethodstart
Start the timer.
megatron/global_vars.py:198
↓ 18 callersMethodget
Retrieves a single item from the dataset with the option to only return a portion of the item. get(idx) is the same as [idx] but get
megatron/data/indexed_dataset.py:500
↓ 17 callersMethodstop
Stop the timer.
megatron/global_vars.py:205
↓ 14 callersFunctionget_data_parallel_group
Get the data parallel group the caller rank belongs to.
megatron/mpu/initialize.py:156
↓ 13 callersFunctionget_model_parallel_group
Get the model parallel group the caller rank belongs to.
megatron/mpu/initialize.py:142
↓ 13 callersMethodwrite
(self, sizes, doc_idx)
megatron/data/indexed_dataset.py:363
↓ 12 callersFunctionget_model_parallel_rank
Return my rank for the model parallel group.
megatron/mpu/initialize.py:190
↓ 11 callersMethodevaluate
(self, qa_file, split, mips_index=None, evidence_id2text=None, iteration_num=-1)
tasks/dense_retriever/supervised_training/evaluation/evaluate.py:114
↓ 11 callersFunctionget_model_parallel_world_size
Return world size for the model parallel group.
megatron/mpu/initialize.py:176
↓ 10 callersMethodexists
(path)
megatron/data/indexed_dataset.py:201
↓ 10 callersFunctionget_tokenizer
Return tokenizer.
megatron/global_vars.py:45
↓ 9 callersFunctionget_checkpoint_name
A unified checkpoint name.
megatron/checkpointing.py:74
↓ 9 callersFunctionget_checkpoint_tracker_filename
Tracker file rescords the latest chckpoint during training to restart from.
megatron/checkpointing.py:88
↓ 9 callersFunctionget_timers
Return timers.
megatron/global_vars.py:74
↓ 9 callersMethodtokenize
(self, text)
tasks/dense_retriever/supervised_training/evaluation/tokenizers.py:143
↓ 8 callersFunction_compare
(arg_name)
megatron/checkpointing.py:49
↓ 8 callersFunctionadd_to_logging
(name)
megatron/training.py:274
↓ 7 callersFunction_ensure_var_is_not_initialized
Make sure the input variable is not None.
megatron/global_vars.py:184
↓ 7 callersFunctiondata_file_path
(prefix_path)
megatron/data/indexed_dataset.py:115
↓ 7 callersMethodload_state_dict
(self, state_dict, strict=True)
megatron/fp16/fp16.py:84
↓ 6 callersFunction_ensure_var_is_initialized
Make sure the input variable is not None.
megatron/global_vars.py:179
↓ 6 callersMethoddecode
(self, ids)
megatron/tokenizer/tokenizer.py:197
↓ 6 callersMethodembed_text
Embed a batch of tokens using the model
megatron/model/dualencoder_model.py:78
↓ 6 callersFunctionget_node_first_rank
()
megatron/mpu/initialize.py:231
↓ 6 callersFunctionindex_file_path
(prefix_path)
megatron/data/indexed_dataset.py:111
↓ 6 callersFunctionmake_attention_mask
Returns a 2-dimensional (2-D) attention mask :param source_block: 1-D array :param target_block: 1-D array
megatron/data/mask_creation_utils.py:5
↓ 6 callersMethodwrite
Write timers to a tensorboard writer
megatron/global_vars.py:245
↓ 5 callersMethod_check_and_set
Auxiliary function for checking the values in the checkpoint and setting them.
megatron/learning_rates.py:93
↓ 5 callersFunction_set_cuda_rng_state
Sets the random number generator state of the current GPU. Arguments: new_state (torch.ByteTensor): The desired state This function i
megatron/mpu/random.py:71
↓ 5 callersFunctiondivide
Ensure that numerator is divisible by the denominator and return the division value.
megatron/mpu/utils.py:26
↓ 5 callersFunctionget_cuda_rng_tracker
Get cuda rng tracker.
megatron/mpu/random.py:202
↓ 5 callersFunctioninitialize_megatron
Set global variables, initialize distributed, and random seeds. `allow_no_cuda` should not be set unless using megatron for cpu only data pro
megatron/initialize.py:11
↓ 5 callersMethodmaybe_print
(self, msg)
megatron/fp16/fp16.py:258
↓ 5 callersMethodstate_dict
(self, destination=None, prefix='', keep_vars=False)
megatron/fp16/fp16.py:76
↓ 4 callersMethod_model_params_to_master_params
(self)
megatron/fp16/fp16.py:311
↓ 4 callersMethodbuild_and_save_index
(self)
megatron/indexer.py:128
↓ 4 callersMethodclear
Clear the embedding data structures to save memory. The metadata ends up getting used, and is also much smaller in dimensionality so i
megatron/data/art_index.py:38
↓ 4 callersFunctionconvert_by_vocab
Converts a sequence of [tokens|ids] using the vocab.
megatron/tokenizer/bert_tokenization.py:136
↓ 4 callersFunctiondualencoder_model_provider
(only_query_model=False, only_context_model=False, vocab_size=None)
megatron/model/dualencoder_model.py:14
↓ 4 callersFunctioninit_method_normal
Init method based on N(0, sigma).
megatron/model/utils.py:25
↓ 4 callersMethodload_state_dict
Customized load.
megatron/model/language_model.py:200
↓ 4 callersMethodlog
Log a group of timers.
megatron/global_vars.py:255
↓ 4 callersFunctionread_longs
(f, n)
megatron/data/indexed_dataset.py:82
↓ 4 callersFunctionscaled_init_method_normal
Init method based on N(0, sigma/sqrt(2*num_layers).
megatron/model/utils.py:33
↓ 4 callersFunctionset_global_variables
Set args, tokenizer, tensorboard-writer, and timers.
megatron/global_vars.py:80
↓ 4 callersMethodstate_dict
(self, destination=None, prefix='', keep_vars=False)
megatron/model/distributed.py:78
↓ 4 callersMethodstate_dict_for_save_checkpoint
For easy load.
megatron/model/language_model.py:183
↓ 4 callersFunctionwrite_longs
(f, a)
megatron/data/indexed_dataset.py:88
↓ 4 callersMethodwriter
(cls, path, dtype)
megatron/data/indexed_dataset.py:340
↓ 3 callersMethod__init__
(self, init_method, output_layer_init_method)
megatron/model/transformer.py:67
↓ 3 callersFunction_gather
Gather tensors and concatinate along the last dimension.
megatron/mpu/mappings.py:54
↓ 3 callersFunction_initialize_affine_weight_cpu
Initialize affine weight for model parallel. Build the master weight on all processes and scatter the relevant chunk.
megatron/mpu/layers.py:62
↓ 3 callersFunction_initialize_affine_weight_gpu
Initialize affine weight for model parallel on GPU.
megatron/mpu/layers.py:50
↓ 3 callersFunction_normalize
(text)
tasks/dense_retriever/supervised_training/evaluation/qa_validation.py:164
↓ 3 callersFunction_reduce
All-reduce the the input tensor across model parallel group.
megatron/mpu/mappings.py:22
↓ 3 callersMethod_set_mips_index
Create a Faiss Flat index with inner product as the metric to search against
megatron/data/art_index.py:113
↓ 3 callersMethod_set_mips_index
Create a Faiss Flat index with inner product as the metric to search against
megatron/data/art_index.py:211
↓ 3 callersFunction_split
Split the tensor along its last dimension and keep the corresponding slice.
megatron/mpu/mappings.py:35
↓ 3 callersMethodadd_token
(self, token)
megatron/tokenizer/tokenizer.py:169
↓ 3 callersFunctionbias_dropout_add
(x, bias, residual, prob, training)
megatron/model/transformer.py:397
↓ 3 callersFunctionbuild_data_loader
Data loader. Note that batch-size is the local (per GPU) batch-size.
tasks/dense_retriever/supervised_training/train_dense_retriever.py:199
↓ 3 callersFunctionbuild_tokenizer
Initialize tokenizer.
megatron/tokenizer/tokenizer.py:24
↓ 3 callersFunctionbuild_tokens_types_paddings_from_ids
Build token types and paddings, trim if needed, and pad if needed.
tasks/dense_retriever/supervised_training/train_data_utils.py:57
↓ 3 callersFunctionconvert_to_unicode
Converts `text` to Unicode (if it's not already), assuming utf-8 input.
megatron/tokenizer/bert_tokenization.py:78
↓ 3 callersMethodelapsed
Calculate the elapsed time.
megatron/global_vars.py:217
↓ 3 callersMethodencode
(self, csv_line)
tools/create_evidence_indexed_dataset.py:42
↓ 3 callersFunctionensure_directory_exists
Build filename's path if it does not already exists.
megatron/checkpointing.py:67
↓ 3 callersFunctionget_language_model
Build language model and return along with the key to save.
megatron/model/language_model.py:45
↓ 3 callersFunctionget_linear_layer
Simple linear layer with weight initialization.
megatron/model/utils.py:43
↓ 3 callersFunctionget_mips_group
()
megatron/mpu/initialize.py:224
↓ 3 callersFunctionget_model
Build the model.
megatron/training.py:38
↓ 3 callersMethodget_states
Get rng states. Copy the dictionary so we have direct pointers to the states, not just a pointer to the dictionary.
megatron/mpu/random.py:147
↓ 3 callersFunctionget_t0_tokenizer
Return T0 tokenizer.
megatron/global_vars.py:51
↓ 3 callersFunctionget_tensorboard_writer
Return tensorboard writer. It can be None so no need to check if it is initialized.
megatron/global_vars.py:68
↓ 3 callersFunctionload_checkpoint
Load a model checkpoint and return the iteration.
megatron/checkpointing.py:145
↓ 3 callersFunctionload_dualencoder_checkpoint
selectively load retrieval models for indexing/retrieving from saved checkpoints
megatron/checkpointing.py:267
↓ 3 callersMethodload_from_file
Populate members from instance saved to file
megatron/data/art_index.py:45
↓ 3 callersMethodload_state_dict
Load the state dicts of each of the models
megatron/model/dualencoder_model.py:101
↓ 3 callersMethodpad
(self)
megatron/tokenizer/tokenizer.py:120
↓ 3 callersFunctionreduce_losses
Reduce a tensor of losses across all GPUs.
megatron/utils.py:9
↓ 3 callersFunctionsave_checkpoint
Save a model checkpoint.
megatron/checkpointing.py:94
↓ 3 callersMethodset_states
Set the rng states. For efficiency purposes, we do not check the size of seed for compatibility.
megatron/mpu/random.py:155
↓ 3 callersMethodstep
If no closure is supplied, :attr:`step` should be called after ``fp16_optimizer_obj.backward(loss)``. :attr:`step` updates th
megatron/fp16/fp16.py:420
↓ 3 callersMethodtokenize
(self, text)
megatron/tokenizer/tokenizer.py:102
↓ 3 callersFunctionwhitespace_tokenize
Runs basic whitespace cleaning and splitting on a piece of text.
megatron/tokenizer/bert_tokenization.py:152
↓ 3 callersMethodwords
Returns a list of the text of each token Args: uncased: lower cases text
tasks/dense_retriever/supervised_training/evaluation/tokenizers.py:49
↓ 2 callersMethod__init__
(self, hidden_size, init_method)
megatron/model/language_model.py:85
↓ 2 callersMethod__init__
(self, path)
megatron/data/indexed_dataset.py:131
↓ 2 callersMethod__init__
(self, input_size, output_size, bias=True, input_is_parallel=False, init_met
megatron/mpu/layers.py:295
↓ 2 callersMethod__iter__
(self)
megatron/data/samplers.py:61
↓ 2 callersMethod_batch
extracts samples only pertaining to this worker's batch
megatron/data/samplers.py:142
↓ 2 callersFunction_build_tokenizer
Initialize tokenizer.
megatron/global_vars.py:108
↓ 2 callersFunction_check_arg_is_not_none
(args, arg)
megatron/arguments.py:148
↓ 2 callersMethod_do_init
(self, path, skip_warmup)
megatron/data/indexed_dataset.py:460
↓ 2 callersMethod_get_layer
(self, layer_number)
megatron/model/transformer.py:618
↓ 2 callersMethod_get_layer_index
(self, layer_number)
megatron/model/transformer.py:611
↓ 2 callersMethod_master_params_to_model_params
(self)
megatron/fp16/fp16.py:307
next →1–100 of 712, ranked by callers