MCPcopy Create free account

hub / github.com/AMAP-ML/EMF / functions

Functions947 in github.com/AMAP-ML/EMF

↓ 1 callersMethodcreate_merge_config_linear
Creates a merge configuration for a linear merge of two models with specified weights.
trl/trl/mergekit_utils.py:105
↓ 1 callersMethodcreate_merge_config_slerp
Creates a merge configuration for a SLERP merge of a model with a base model.
trl/trl/mergekit_utils.py:212
↓ 1 callersMethodcreate_merge_config_ties
Creates a merge configuration for a TIES merge of two models, with specified weights and densities.
trl/trl/mergekit_utils.py:124
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/online_dpo_trainer.py:784
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/iterative_sft_trainer.py:442
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/rloo_trainer.py:653
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/prm_trainer.py:315
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/kto_trainer.py:1676
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/orpo_trainer.py:1038
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/bco_trainer.py:1483
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/dpo_trainer.py:1928
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/ppo_trainer.py:760
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/cpo_trainer.py:1054
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/sft_trainer.py:938
↓ 1 callersMethodcreate_model_card
Creates a draft of a model card using the information available to the `Trainer`. Args: model_name (`str` or `None`, *op
trl/trl/trainer/reward_trainer.py:381
↓ 1 callersMethoddecode_code
(self, code_b, shape=None, channel_first=True)
tok/ar_dtok/vqvae.py:92
↓ 1 callersMethoddecode_latents
(self, latents, normalize=True, return_tensor=False)
blip3o/model/language_model/blip3o_qwen_inference.py:99
↓ 1 callersMethoddecode_latents
(self, latents, normalize=True, return_tensor=False)
blip3o/model/language_model/blip3o_qwen_grpo.py:125
↓ 1 callersFunctiondecode_n_tokens
( model, cur_token: torch.Tensor, input_pos: torch.Tensor, num_new_tokens: int, cfg_scale: float, cfg
tok/ar_dtok/generate.py:105
↓ 1 callersFunctiondecode_one_token
(model, x: torch.Tensor, input_pos: torch.Tensor, cfg_scale: float, cfg_flag: bool, **sampling_kwargs)
tok/ar_dtok/generate.py:89
↓ 1 callersFunctiondownload_video
Download video if not already present locally.
trl/examples/scripts/sft_video_llm.py:70
↓ 1 callersMethoddpo_loss
Compute the DPO loss for a batch of policy and reference model log probabilities. Args: chosen_logps (`torch.FloatTensor
trl/trl/trainer/dpo_trainer.py:993
↓ 1 callersFunctiondrop_path
Drop paths (Stochastic Depth) per sample (when applied in main path of residual blocks). This is the same as the DropConnect impl I created for E
tok/ar_dtok/ar_model.py:114
↓ 1 callersMethodencode
(self, x, **kwargs)
tok/ta_tok.py:103
↓ 1 callersFunctionentropy_from_logits
Compute the Shannon entropy (in nats) for each row of *logits* without materialising the full soft-max in memory. The batch dimension is
trl/trl/trainer/utils.py:1464
↓ 1 callersFunctionexpand2square
(pil_img, background_color)
blip3o/data/dataset.py:45
↓ 1 callersFunctionextract_prompt
r""" Extracts the shared prompt from a preference data example, where the prompt is implicit within both the chosen and rejected completions.
trl/trl/data_utils.py:331
↓ 1 callersMethodforward
(self, *args, **kwargs)
trl/trl/models/modeling_base.py:699
↓ 1 callersMethodgeneralized_jsd_loss
Compute the generalized Jensen-Shannon Divergence loss for knowledge distillation using F.kl_div. See Eq. (1) of https://huggingface.
trl/trl/trainer/gkd_trainer.py:149
↓ 1 callersFunctiongenerate
Generates sequences from the language model backbone in a way that does not affect padding tokens. Args: lm_backbone (`torch.nn.Modu
trl/trl/trainer/utils.py:1058
↓ 1 callersMethodgenerate
( self, inputs: Optional[torch.Tensor] = None, images: Optional[torch.Tensor] = None,
blip3o/model/language_model/blip3o_qwen_inference.py:75
↓ 1 callersMethodgenerate
( self, inputs: Optional[torch.Tensor] = None, images: Optional[torch.Tensor] = None,
blip3o/model/language_model/blip3o_qwen_grpo.py:89
↓ 1 callersMethodgenerate
r""" A simple wrapper around the `generate` method of the wrapped model. Please refer to the [`generate`](https://huggingface.co/docs/
trl/trl/models/modeling_value_head.py:185
↓ 1 callersMethodgenerate_completions
(self, sampling: bool = False)
trl/trl/trainer/rloo_trainer.py:568
↓ 1 callersMethodgenerate_from_model
Generate samples from the model and reference model for the given batch of inputs.
trl/trl/trainer/orpo_trainer.py:869
↓ 1 callersMethodgenerate_from_model
Generate samples from the model and reference model for the given batch of inputs.
trl/trl/trainer/cpo_trainer.py:890
↓ 1 callersMethodgenerate_from_model_and_ref
Generate samples from the model and reference model for the given batch of inputs.
trl/trl/trainer/kto_trainer.py:1489
↓ 1 callersMethodgenerate_from_model_and_ref
Generate samples from the model and reference model for the given batch of inputs.
trl/trl/trainer/bco_trainer.py:1297
↓ 1 callersMethodgenerate_from_model_and_ref
Generate samples from the model and reference model for the given batch of inputs.
trl/trl/trainer/dpo_trainer.py:1756
↓ 1 callersMethodgenerate_image
(self, prompt: str,cfg_guidance,num_step)
inference.py:44
↓ 1 callersMethodgenerate_image
(self, prompt: str)
trl/inference.py:30
↓ 1 callersFunctionget_1d_sincos_pos_embed_from_grid
embed_dim: output dimension for each position pos: a list of positions to be encoded: size (M,) out: (M, D) scale_factor: the base fo
tok/ar_dtok/ar_model.py:21
↓ 1 callersFunctionget_act_offloading_ctx_manager
Returns the activation offloading context manager for the model. All but the last output Linear in every step will be offloaded. If acti
trl/trl/models/activation_offloading.py:345
↓ 1 callersFunctionget_all_parameters
(sub_module, recurse=False)
trl/trl/models/utils.py:263
↓ 1 callersFunctionget_args
()
trl/examples/research_projects/stack_llama/scripts/supervised_finetuning.py:33
↓ 1 callersMethodget_batch_logps
Compute the log probabilities of the given labels under the given logits. Args: logits: Logits of the model (unnormalized). Shape
trl/trl/trainer/orpo_trainer.py:667
↓ 1 callersMethodget_batch_logps
Compute the log probabilities of the given labels under the given logits. Args: logits: Logits of the model (unnormalized). Shape
trl/trl/trainer/cpo_trainer.py:698
↓ 1 callersMethodget_codebook_entry
(self, indices, shape=None)
tok/ar_dtok/bottleneck.py:165
↓ 1 callersMethodget_codebook_entry
(self, indices, shape=None, channel_first=True)
tok/ar_dtok/vqvae.py:297
↓ 1 callersFunctionget_dataset_cls
(name)
blip3o/data/dataset.py:395
↓ 1 callersMethodget_embedding
(self)
blip3o/model/multimodal_encoder/ta_tok_encoder.py:65
↓ 1 callersMethodget_eval_dataloader
Returns the evaluation [`~torch.utils.data.DataLoader`]. Subclass of transformers.src.transformers.trainer.get_eval_dataloader to pr
trl/trl/trainer/kto_trainer.py:867
↓ 1 callersFunctionget_exp_cap
Get the exponent cap of a value. This is used to cap the exponent of a value to avoid overflow. The formula is : log(value.dtype.max) E.g.
trl/trl/trainer/utils.py:643
↓ 1 callersFunctionget_git_commit_hash
(package_name)
trl/trl/scripts/utils.py:264
↓ 1 callersFunctionget_global_statistics
Computes element-wise mean and variance of the tensor across processes. Reference: https://github.com/OpenLMLab/MOSS-RLHF/blob/40b91eb2f2b71b
trl/trl/trainer/utils.py:455
↓ 1 callersFunctionget_high_entropy_mask
Returns a binary mask identifying tokens whose entropy exceeds a given quantile threshold. Args: entropies (`torch.Tensor`):
trl/trl/trainer/grpo_trainer.py:362
↓ 1 callersMethodget_images
(self, return_pil=False, return_path=False)
blip3o/conversation.py:157
↓ 1 callersFunctionget_modality_length_grouped_indices
Return a list of indices so that each slice of `batch_size` consecutive indices correspond to elements of similar lengths. To do this, the in
blip3o/train/blip3o_trainer.py:90
↓ 1 callersFunctionget_modality_length_grouped_indices_auto
(lengths, batch_size, world_size, generator=None)
blip3o/train/blip3o_trainer.py:168
↓ 1 callersFunctionget_model
(model_args, training_args)
blip3o/train/train.py:94
↓ 1 callersMethodget_model
(self)
blip3o/model/language_model/blip3o_qwen_inference.py:58
↓ 1 callersMethodget_model
(self)
blip3o/model/language_model/blip3o_qwen.py:44
↓ 1 callersMethodget_model
(self)
blip3o/model/language_model/blip3o_qwen_grpo.py:63
↓ 1 callersMethodget_prompt
(self)
blip3o/conversation.py:43
↓ 1 callersFunctionget_variable_length_grouped_indices
(lengths, batch_size, world_size, megabatch_mult=8, generator=None)
blip3o/train/blip3o_trainer.py:74
↓ 1 callersMethodinitialize_vision_modules
(self, model_args, fsdp=None)
blip3o/model/blip3o_arch.py:84
↓ 1 callersMethodinitialize_vision_tokenizer
(self, model_args, tokenizer)
blip3o/model/blip3o_arch.py:370
↓ 1 callersMethodinitialize_weights
(self)
tok/ar_dtok/ar_model.py:338
↓ 1 callersFunctioninsert_separator
(X, sep)
blip3o/mm_utils.py:14
↓ 1 callersFunctioninstructions_formatting_function
r""" return a callable function that takes in an "instructions" dataset and returns a formatted dataset, based on the tokenizer apply chat tem
trl/trl/extras/dataset_formatting.py:60
↓ 1 callersMethodinterpolant
Define interpolation function
blip3o/model/language_model/loss_adaptive.py:59
↓ 1 callersMethodinv
(self, inp)
tok/utils.py:14
↓ 1 callersFunctionis_conversational_from_value
r""" Check if the example is in a conversational format (from/value). Note that this format isn't recommended. Prefer the ChatML format (role/
trl/trl/data_utils.py:690
↓ 1 callersFunctionis_deepspeed_available
()
trl/trl/import_utils.py:43
↓ 1 callersMethodis_video_file
(self, filename)
blip3o/conversation.py:176
↓ 1 callersFunctioniter_params
(module, recurse=False)
trl/trl/models/utils.py:267
↓ 1 callersMethodkto_loss
Compute the KTO loss for a batch of policy and reference model log probabilities. Args: policy_chosen_logps: Log
trl/trl/trainer/kto_trainer.py:1098
↓ 1 callersMethodload_from_json
Create an instance from the content of `json_path`.
trl/trl/trainer/utils.py:446
↓ 1 callersMethodlog
Log `logs` on the various objects watching training, including stored metrics. Args: logs (`dict[str, float]`):
trl/trl/trainer/orpo_trainer.py:988
↓ 1 callersMethodlog
Log `logs` on the various objects watching training, including stored metrics. Args: logs (`dict[str, float]`):
trl/trl/trainer/bco_trainer.py:1439
↓ 1 callersMethodlog
Log `logs` on the various objects watching training, including stored metrics. Args: logs (`dict[str, float]`):
trl/trl/trainer/cpo_trainer.py:1004
↓ 1 callersMethodloss
( self, advantages: torch.Tensor, clip_range: float, ratio: torch.Tensor,
trl/trl/trainer/ddpo_trainer.py:400
↓ 1 callersFunctionmain
()
inference.py:78
↓ 1 callersFunctionmain
()
trl/inference.py:62
↓ 1 callersFunctionmain
()
trl/examples/scripts/sft_vlm_gemma3.py:140
↓ 1 callersFunctionmain
()
trl/examples/scripts/sft_gemma3.py:33
↓ 1 callersFunctionmain
(args)
trl/examples/research_projects/stack_llama/scripts/supervised_finetuning.py:207
↓ 1 callersFunctionmain
()
trl/trl/cli.py:32
↓ 1 callersFunctionmain
(script_args, training_args, model_args)
trl/trl/scripts/dpo.py:82
↓ 1 callersFunctionmain
(script_args, training_args, model_args)
trl/trl/scripts/sft.py:82
↓ 1 callersFunctionmain
(script_args, training_args, model_args)
trl/trl/scripts/kto.py:83
↓ 1 callersFunctionmain
(script_args, training_args, model_args)
trl/trl/scripts/grpo.py:71
↓ 1 callersFunctionmain
(script_args: ScriptArguments)
trl/trl/scripts/vllm_serve.py:366
↓ 1 callersFunctionmake_parser
(subparsers: argparse._SubParsersAction = None)
trl/trl/scripts/dpo.py:156
↓ 1 callersFunctionmake_parser
(subparsers: argparse._SubParsersAction = None)
trl/trl/scripts/sft.py:144
↓ 1 callersFunctionmake_parser
(subparsers: argparse._SubParsersAction = None)
trl/trl/scripts/kto.py:125
↓ 1 callersFunctionmake_parser
(subparsers: argparse._SubParsersAction = None)
trl/trl/scripts/grpo.py:127
↓ 1 callersFunctionmake_parser
(subparsers: argparse._SubParsersAction = None)
trl/trl/scripts/vllm_serve.py:630
↓ 1 callersFunctionmake_supervised_data_module
Make dataset and collator for supervised fine-tuning.
blip3o/data/dataset.py:403
↓ 1 callersMethodmask_drop
(self, latents, drop_prob=0.1)
blip3o/model/language_model/blip3o_qwen.py:58
← previousnext →301–400 of 947, ranked by callers