MCPcopy Create free account

hub / github.com/NVlabs/GDPO / functions

Functions2,091 in github.com/NVlabs/GDPO

Methodinit_model
(self)
verl-GDPO/verl/workers/megatron_workers.py:672
Methodinit_model
(self)
verl-GDPO/verl/workers/fsdp_workers.py:285
Methodinit_model
(self)
verl-GDPO/verl/workers/fsdp_workers.py:851
Methodinitialize_weight_buffer
Initialize the weight buffer. The weight buffer is obtained according to the actor. We will construct a large buffer for each dtype i
verl-GDPO/verl/utils/memory_buffer.py:181
Functioninner
(*args, **kwargs)
verl-GDPO/verl/single_controller/base/decorator.py:401
Methodinstall_package
(self, language, version)
trl-GDPO/open-r1/src/open_r1/utils/competitive_programming/piston_client.py:115
Functionint_reward_func
(completions, **kwargs)
trl-GDPO/open-r1/src/open_r1/gsm8k.py:107
Methodis_bf16
(precision)
verl-GDPO/verl/utils/torch_dtypes.py:59
Methodis_fast
(self)
verl-GDPO/verl/workers/rollout/tokenizer.py:161
Methodis_fp16
(precision)
verl-GDPO/verl/utils/torch_dtypes.py:51
Methodis_fp32
(precision)
verl-GDPO/verl/utils/torch_dtypes.py:55
Functionis_patchable
(lang)
trl-GDPO/open-r1/src/open_r1/utils/competitive_programming/code_patcher.py:85
Functionis_sequence_parallel_param
(param)
verl-GDPO/verl/utils/megatron/sequence_parallel.py:25
Functionis_unsloth_available
()
trl-GDPO/trl-0.18.0-gdpo/trl/import_utils.py:75
Methodjudge
(self, prompts, completions, shuffle_order=True, return_scores=False)
trl-GDPO/trl-0.18.0-gdpo/tests/testing_utils.py:122
Methodjudge
(self, prompts, completions, shuffle_order=True, return_scores=False)
trl-GDPO/trl-0.18.0-gdpo/tests/test_callbacks.py:38
Methodjudge
Judge the completion for the given prompts and return the ranks of each completion. Args: prompts (`list[str]`):
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/judges.py:93
Methodjudge
Judge the completion pairs for the given prompts. Args: prompts (`list[str]`): List of prompts.
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/judges.py:120
Methodjudge
Judge the completion for a given prompt. Used to assess if a completion satisfies a constraint. This base class should be used to im
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/judges.py:152
Methodjudge
Judge the completion pairs for the given prompts using the PairRM model. Args: prompts (`list[str]`): Li
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/judges.py:220
Methodjudge
(self, prompts: list[str], completions: list[list[str]], shuffle_order: bool = True)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/judges.py:373
Functionkl_penalty
Compute KL divergence given logprob and ref_logprob. Copied from https://github.com/huggingface/trl/blob/main/trl/trainer/ppo_trainer.py#L1104
verl-GDPO/verl/trainer/ppo/core_algos.py:385
Methodlast_text_segment
Get the last text segment.
trl-GDPO/trl-0.18.0-gdpo/trl/environment/base_environment.py:124
Functionlifespan
(app: FastAPI)
trl-GDPO/trl-0.18.0-gdpo/trl/scripts/vllm_serve.py:366
Functionllama_flash_attn_forward
adapt from transformers 4.47.1
verl-GDPO/verl/models/transformers/llama.py:27
Functionllm_worker
( script_args: ScriptArguments, data_parallel_rank: int, master_port: int, connection: Connection )
trl-GDPO/trl-0.18.0-gdpo/trl/scripts/vllm_serve.py:271
Methodload_checkpoint
(self, checkpoint_path)
verl-GDPO/verl/workers/megatron_workers.py:395
Methodload_checkpoint
(self, checkpoint_path)
verl-GDPO/verl/workers/megatron_workers.py:568
Methodload_checkpoint
(self, models, input_dir)
trl-GDPO/trl-0.18.0-gdpo/trl/models/modeling_sd_base.py:896
Methodload_from_disk
(filepath)
verl-GDPO/verl/protocol.py:220
Functionload_fsdp_grad
(module, device_id)
verl-GDPO/verl/utils/fsdp_utils.py:86
Methodload_pretrained_model
(self, checkpoint_path)
verl-GDPO/verl/workers/megatron_workers.py:399
Functionload_state_dict_to_megatron_llama
Load merged state_dict to sharded Megatron module in training.
verl-GDPO/verl/models/llama/megatron/checkpoint_utils/llama_loader.py:51
Methodlocal_rank_list
(self)
verl-GDPO/verl/single_controller/base/worker_group.py:55
Methodlocal_world_size_list
(self)
verl-GDPO/verl/single_controller/base/worker_group.py:49
Methodlog
(self, data, step)
verl-GDPO/verl/utils/tracking.py:69
Methodlog
(self, logs: dict[str, float], start_time: Optional[float] = None)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/sft_trainer.py:735
Methodlog
(self, logs: dict[str, float], start_time: Optional[float] = None)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/grpo_trainer.py:1487
Functionlog_probs_from_logits_all_rmpad
Compute the log_probs from logits with rmpad input_ids and logits. Note that logits_rmpad = model(input_ids_rmpad). For each sentences, there is a
verl-GDPO/verl/utils/torch_functional.py:328
Functionlog_probs_from_logits_response
Compute the response log_probs from full logits. Note that logits = model(input_ids) Args: input_ids: [batch_size, seqlen] lo
verl-GDPO/verl/utils/torch_functional.py:284
Functionlog_probs_from_logits_response_rmpad
Compute the log_probs from logits with rmpad logits and pad input. Note that logits_rmpad = model(input_ids_rmpad). For each sentences, there is a
verl-GDPO/verl/utils/torch_functional.py:300
Functionlogprobs_of_labels_v2
A memory efficient implementation of logprobs_from_logits
verl-GDPO/verl/utils/torch_functional.py:76
Methodloss
( self, advantages: torch.Tensor, clip_range: float, ratio: torch.Tensor,
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/alignprop_trainer.py:283
Methodloss_func
(output, data, meta_info)
verl-GDPO/verl/workers/critic/megatron_critic.py:135
Methodloss_func
(output, data, meta_info)
verl-GDPO/verl/workers/actor/megatron_actor.py:249
Methodloss_func
(output)
verl-GDPO/verl/workers/reward_model/megatron/reward_model.py:219
Functionlr_lambda
(current_step)
verl-GDPO/verl/utils/torch_functional.py:412
Functionmain
(text_file_name, slack_channel_name=None)
trl-GDPO/trl-0.18.0-gdpo/scripts/log_example_reports.py:30
Functionmain_task
(config)
verl-GDPO/verl/trainer/main_ppo.py:117
Functionmake_conversation
(example, prompt_column: str = script_args.dataset_prompt_column)
trl-GDPO/open-r1/scripts/pass_rate_filtering/compute_pass_rate.py:80
Methodmake_inputs_require_grad
(module, input, output)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/kto_trainer.py:425
Methodmake_inputs_require_grad
(module, input, output)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/orpo_trainer.py:185
Methodmake_inputs_require_grad
(module, input, output)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/bco_trainer.py:440
Methodmake_inputs_require_grad
(module, input, output)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/dpo_trainer.py:311
Methodmake_inputs_require_grad
(module, input, output)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/cpo_trainer.py:181
Methodmake_inputs_require_grad
(module, input, output)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/sft_trainer.py:503
Methodmake_minibatch_iterator
(self, data: DataProto)
verl-GDPO/verl/workers/critic/megatron_critic.py:106
Functionmark_parameter_as_sequence_parallel
(parameter)
verl-GDPO/verl/utils/megatron/sequence_parallel.py:21
Functionmasked_sum
Compute mean of tensor with a masked values.
verl-GDPO/verl/utils/torch_functional.py:102
Methodmaster_address
(self)
verl-GDPO/verl/single_controller/ray/base.py:354
Methodmaster_port
(self)
verl-GDPO/verl/single_controller/ray/base.py:358
Methodmatch_underlying_distribution
(self)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/bco_trainer.py:740
Methodmegatron_actor_model_provider
(pre_process, post_process)
verl-GDPO/verl/workers/megatron_workers.py:154
Methodmegatron_critic_model_provider
(pre_process, post_process)
verl-GDPO/verl/workers/megatron_workers.py:476
Methodmegatron_rm_model_provider
(pre_process, post_process)
verl-GDPO/verl/workers/megatron_workers.py:638
Methodmemory_buffers
(self)
verl-GDPO/verl/utils/memory_buffer.py:213
Methodmerge
(self, other)
verl-GDPO/verl/utils/seqlen_balancing.py:72
Functionmerge_megatron_ckpt_llama
Merge sharded parameters of a Megatron module into a merged checkpoint. Args: wrapped_modelss (list of megatron.model.DistributedDataPara
verl-GDPO/verl/models/llama/megatron/checkpoint_utils/llama_saver.py:76
Functionmerge_resource_pool
(rp1: RayResourcePool, rp2: RayResourcePool)
verl-GDPO/verl/single_controller/ray/base.py:114
Functionmeta_device_init
Create model parameters with meta device. Note buffers in model will still be initialized in default device (e.g., CPU), since the buffe
verl-GDPO/verl/utils/fsdp_utils.py:134
Methodmixture_coef
(self)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/nash_md_trainer.py:169
Methodmock_encode
(text, add_special_tokens)
trl-GDPO/trl-0.18.0-gdpo/tests/test_prm_trainer.py:40
Methodmock_tokenizer_call
(text, add_special_tokens)
trl-GDPO/trl-0.18.0-gdpo/tests/test_prm_trainer.py:51
Methodmock_tokenizer_call
(text, add_special_tokens)
trl-GDPO/trl-0.18.0-gdpo/tests/test_dpo_trainer.py:56
Methodnon_applicable_reward_func
A reward function that returns None for all inputs, as it is not applicable to this sample.
trl-GDPO/trl-0.18.0-gdpo/tests/test_grpo_trainer.py:590
Methodnoop
(tensor)
trl-GDPO/trl-0.18.0-gdpo/trl/models/activation_offloading.py:337
Methodon_evaluate
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:183
Methodon_evaluate
(self, args: TrainingArguments, state: TrainerState, control: TrainerControl, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:356
Methodon_log
(self, args, state, control, logs=None, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:195
Methodon_predict
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:189
Methodon_prediction_step
(self, args, state, control, eval_dataloader=None, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:175
Methodon_save
( self, args: TrainingArguments, state: TrainerState, control: TrainerControl,
trl-GDPO/open-r1/src/open_r1/utils/callbacks.py:47
Methodon_step_end
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/examples/research_projects/stack_llama/scripts/reward_modeling.py:315
Methodon_step_end
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:170
Methodon_step_end
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:464
Methodon_train_begin
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:155
Methodon_train_end
(self, args, state, control, **kwargs)
trl-GDPO/trl-0.18.0-gdpo/trl/trainer/callbacks.py:200
Functionpack
(examples)
trl-GDPO/trl-0.18.0-gdpo/trl/data_utils.py:509
Methodpack_tensor
(activation: torch.Tensor)
trl-GDPO/trl-0.18.0-gdpo/trl/models/activation_offloading.py:128
Functionpad_packed_inputs
pad the tokens such that the total length is a multiple of size. This function is useful when applying sequence parallel and context parallel
verl-GDPO/verl/utils/model.py:299
Methodpad_token_id
`Optional[int]`: Id of the padding token in the vocabulary. Returns `None` if the token has not been set.
verl-GDPO/verl/workers/rollout/tokenizer.py:36
Functionparallel_init_module_fn
Generate a function to initialize sub-modules in the `module` with `shard_states` from huggingface checkpoint. Args: module (tor
verl-GDPO/verl/utils/fsdp_utils.py:221
Functionparallel_load_safetensors
Parallel load safetensors from huggingface checkpoint Huggingface checkpoint contains: - config.json: a json file for model configurati
verl-GDPO/verl/utils/fsdp_utils.py:165
Functionparallel_put
(data_list, max_workers=None)
verl-GDPO/verl/utils/ray_utils.py:23
Methodpost_init
r""" We add the state dictionary of the value head to the state dictionary of the wrapped model by prepending the key with `v_head.`.
trl-GDPO/trl-0.18.0-gdpo/trl/models/modeling_value_head.py:222
Methodpost_init
r""" We add the state dictionary of the value head to the state dictionary of the wrapped model by prepending the key with `v_head.`.
trl-GDPO/trl-0.18.0-gdpo/trl/models/modeling_value_head.py:310
Functionpost_process_logits
(input_ids, logits, temperature, top_k, top_p)
verl-GDPO/verl/utils/torch_functional.py:359
Methodpostprocess_data
(self, data: DataProto)
verl-GDPO/verl/workers/sharding_manager/fsdp_vllm.py:121
Methodpostprocess_data
Split the data to follow FSDP partition
verl-GDPO/verl/workers/sharding_manager/fsdp_ulysses.py:80
Methodpostprocess_data
(self, data: DataProto)
verl-GDPO/verl/workers/sharding_manager/megatron_vllm.py:394
← previousnext →1,301–1,400 of 2,091, ranked by callers