MCPcopy Create free account

hub / github.com/RL-Align/RL-Kernel / functions

Functions1,290 in github.com/RL-Align/RL-Kernel

↓ 3 callersFunctionbuild_arg_parser
()
benchmarks/profiler.py:765
↓ 3 callersFunctionchunked_linear_logp_backward
( grad_logp: torch.Tensor, hidden_2d: torch.Tensor, weight: torch.Tensor, target_1d: torch.Ten
rl_engine/kernels/ops/pytorch/loss/linear_logp.py:383
↓ 3 callersMethodcreate_rollout_worker
(self, spec: RayWorkerSpec)
rl_engine/executors/ray_actor_manager.py:116
↓ 3 callersMethodcreate_worker_actor
(self, spec: RayWorkerSpec)
rl_engine/executors/ray_actor_manager.py:102
↓ 3 callersMethoddebug_tensor_data_ptrs
Return storage pointers for tests and benchmark transport verification.
rl_engine/executors/bridge.py:1634
↓ 3 callersMethodestimate_logp_tflops
Estimate floating-point operations for a single logp forward pass. log_softmax ~= 5 * B * S * V FLOPs (subtract max, exp, s
benchmarks/profiler.py:227
↓ 3 callersFunctionextract_rollout_reward_groups
Extract scalar reward groups from rollout payloads when they are present.
rl_engine/executors/training_contract.py:471
↓ 3 callersMethodforward
Compute `a @ b` and return the input dtype.
rl_engine/kernels/ops/pytorch/linear/matmul.py:22
↓ 3 callersMethodforward
Apply RoPE in input dtype. Cos/sin always computed in fp32.
rl_engine/kernels/ops/pytorch/rotary_embedding/rope.py:27
↓ 3 callersMethodfrom_model_config
Build a sampler config from the executor's loose model_config dictionary.
rl_engine/executors/vllm_sampler.py:29
↓ 3 callersFunctionfwd_bwd
(op, h_src=hidden, w_src=weight, t=target)
benchmarks/benchmark_linear_logp.py:112
↓ 3 callersMethodget_preferred_dtype
Returns the optimal data type for the current hardware. AMD ROCm typically yields better performance with bfloat16 in RL workloads.
rl_engine/platforms/device.py:47
↓ 3 callersMethodgroup_advantages
Per-sequence reward normalization, computed by the Triton group kernel.
rl_engine/kernels/ops/triton/loss/grpo_loss.py:139
↓ 3 callersMethodimport_update
(self, manifest: WeightUpdateManifest)
rl_engine/executors/bridge.py:2125
↓ 3 callersMethodinstall
( self, manifest: WeightUpdateManifest, tensors: Mapping[str, torch.Tensor], )
rl_engine/executors/bridge.py:466
↓ 3 callersFunctionnative_attention_availability
()
tests/test_attention_correctness.py:171
↓ 3 callersMethodout
( self, logits: torch.Tensor, token_ids: torch.Tensor, output: torch.Tensor )
rl_engine/kernels/ops/pytorch/loss/logp.py:109
↓ 3 callersMethodrelease_allocation
( self, handle: Any, address: int, mapped_nbytes: int, exported_fd: in
rl_engine/executors/bridge.py:1245
↓ 3 callersMethodrelease_import
(self, handle: Any, address: int, mapped_nbytes: int)
rl_engine/executors/bridge.py:1295
↓ 3 callersFunctionreserve_paged_kv_cache
Allocate paged KV tensors and a dense block table for the scoring batch.
rl_engine/executors/paged_kv_baseline.py:183
↓ 3 callersFunctionshould_use_tensor_parallel_linear_logp
Whether a linear_logp call describes a vocab-parallel weight shard.
rl_engine/kernels/ops/pytorch/loss/linear_logp.py:58
↓ 3 callersFunctionsummarize_tensor_tree
Count tensors and bytes in nested tuples/lists/mappings/dataclass-like outputs.
rl_engine/executors/stateless_executor.py:411
↓ 3 callersFunctiontensor_parallel_linear_logp
( hidden: torch.Tensor, lm_head_weight: torch.Tensor, target_ids: torch.Tensor, bias: Optional
rl_engine/kernels/ops/pytorch/loss/linear_logp.py:338
↓ 2 callersMethodCUmemLocation
(self)
rl_engine/executors/bridge.py:1082
↓ 2 callersMethod__init__
(self, config: TorchRLTrainingConfig)
tests/test_stateless_training_contract.py:23
↓ 2 callersMethod__init__
(self, vocab_size: int, hidden_dim: int)
benchmarks/benchmark_stateless_executor.py:101
↓ 2 callersMethod_access_desc
(self)
rl_engine/executors/bridge.py:1182
↓ 2 callersMethod_allocation_prop
(self)
rl_engine/executors/bridge.py:1175
↓ 2 callersFunction_arg_str
(args: argparse.Namespace, name: str, default: str)
rl_engine/kernels/gtest/operator_inputs.py:259
↓ 2 callersFunction_attach_reference_logps_to_candidate
( candidate: Any, logp_rows: Sequence[Sequence[float]], row_index: int, )
rl_engine/executors/training_contract.py:753
↓ 2 callersFunction_attach_reward_to_candidate
( candidate: Any, rewards: Sequence[float], reward_index: int, )
rl_engine/executors/training_contract.py:692
↓ 2 callersMethod_attention
Core softmax attention: cast to ``compute_dtype``, score, mask, softmax, weighted-sum over V, cast out. ``strict_fp32`` disables autocast/TF32
rl_engine/kernels/ops/pytorch/attention/standard_attn.py:116
↓ 2 callersFunction_backward_grads
( outputs: list[torch.Tensor], inputs: Mapping[str, Any], grad_input_names: tuple[str, ...], *
rl_engine/kernels/gtest/op_checks.py:321
↓ 2 callersMethod_batch_from_candidate_groups
( self, candidate_groups: Sequence[Sequence[Sequence[int]]], rollout: RolloutStageResu
rl_engine/executors/training_contract.py:147
↓ 2 callersFunction_blocked_metric
( *, profiler: PerformanceProfiler, benchmark_name: str, batch_size: int, seq_len: int,
benchmarks/profiler.py:578
↓ 2 callersFunction_blocked_row
(args: argparse.Namespace, reason: str)
benchmarks/benchmark_stateless_executor.py:387
↓ 2 callersFunction_call_candidate
(candidate: Callable[..., Any] | Any, inputs: Mapping[str, Any])
rl_engine/kernels/gtest/op_checks.py:293
↓ 2 callersFunction_candidate_groups_from_grouped_outputs
(grouped_outputs: Sequence[Any])
rl_engine/executors/training_contract.py:608
↓ 2 callersFunction_candidate_records_from_grouped_outputs
( grouped_outputs: Sequence[Any], )
rl_engine/executors/training_contract.py:530
↓ 2 callersFunction_check_group_block_limit
(max_group: int)
rl_engine/kernels/ops/triton/loss/grpo_loss.py:21
↓ 2 callersFunction_clone_inputs_for_backward
( inputs: Mapping[str, Any], grad_input_names: tuple[str, ...], )
rl_engine/kernels/gtest/op_checks.py:299
↓ 2 callersFunction_clone_state_dict
(state_dict: Mapping[str, Any])
rl_engine/executors/deepspeed_trainer.py:678
↓ 2 callersFunction_coerce_hidden_tensor
( candidate: Any, *, expected_hidden_dim: Optional[int] = None, )
rl_engine/executors/deepspeed_trainer.py:461
↓ 2 callersFunction_compare_case_outputs
( candidate: CandidateSpec, case: OperatorCase, contract: Mapping[str, Any], candidate_outputs
rl_engine/kernels/gtest/op_checks.py:253
↓ 2 callersFunction_compare_output
( candidate: torch.Tensor, gold: torch.Tensor, *, output_index: int, atol: float, rtol
rl_engine/kernels/gtest/op_checks.py:436
↓ 2 callersFunction_completion_mask_starts_at_position_zero
( completion_mask: torch.Tensor, *, device: torch.device, )
rl_engine/executors/stateless_executor.py:569
↓ 2 callersMethod_compute_cos_sin
Compute cos/sin tables in fp32 from positions and theta. Args: x: [..., D] — only x.shape[-1] (head_dim) is used. pos
rl_engine/kernels/ops/pytorch/rotary_embedding/rope.py:50
↓ 2 callersMethod_concat_kv
Append the step's new K/V to the cache along the seq axis (dim=2). Layout is [B, Hkv, S, D], so the sequence axis is dim=2. Pure (no
rl_engine/kernels/ops/pytorch/attention/kv_cache.py:148
↓ 2 callersFunction_copy_float_list
(value: Any)
rl_engine/executors/training_contract.py:1012
↓ 2 callersFunction_descend
(op, batch, policy_logits, ref_logits, *, steps=5, lr=0.05)
tests/test_grpo_loss.py:315
↓ 2 callersFunction_dtype_from_name
(name: str)
rl_engine/executors/bridge.py:761
↓ 2 callersFunction_dtype_from_string
(value: str)
benchmarks/benchmark_weight_sync_bridge.py:912
↓ 2 callersMethod_embedding
( token_ids: torch.Tensor, weight: torch.Tensor, *, output_dtype: torch.dtype,
rl_engine/kernels/ops/pytorch/linear/embedding.py:39
↓ 2 callersMethod_engine_rank
(self)
rl_engine/executors/deepspeed_trainer.py:295
↓ 2 callersMethod_find_libcuda
(discovered_path: Optional[str])
rl_engine/executors/bridge.py:997
↓ 2 callersFunction_first_sequence_item
(value: Any)
rl_engine/executors/vllm_sampler.py:285
↓ 2 callersFunction_generator
(args: argparse.Namespace, device: torch.device, offset: int)
rl_engine/kernels/gtest/operator_inputs.py:229
↓ 2 callersFunction_install_fake_flashinfer
Inject a stub ``flashinfer.sampling`` so the FlashInfer code path runs on CPU. ``top_p_sampling_from_probs`` records the probabilities it receive
tests/test_sampler_temperature.py:12
↓ 2 callersFunction_last_hidden_state_tensor
( candidate: Any, *, expected_hidden_dim: Optional[int] = None, )
rl_engine/executors/deepspeed_trainer.py:544
↓ 2 callersFunction_layout_inputs
(base_hidden, base_target, base_mask, order, lead_shape)
tests/test_linear_logp.py:173
↓ 2 callersMethod_lm_head
Core matmul: cast to ``compute_dtype``, project, optionally add bias, cast out. When ``strict_fp32`` is set, the matmul runs with autocast di
rl_engine/kernels/ops/pytorch/linear/lm_head.py:87
↓ 2 callersFunction_load_object
(path: str)
rl_engine/kernels/gtest/operator_specs.py:27
↓ 2 callersFunction_load_torch_extension_tools
()
setup.py:9
↓ 2 callersMethod_load_vllm_classes
(self)
rl_engine/executors/vllm_sampler.py:150
↓ 2 callersFunction_log_once_impl
Implementation for one-time logging using LRU cache.
rl_engine/utils/logger.py:15
↓ 2 callersFunction_logits
(batch, seed, *, vocab=_VOCAB, device="cpu")
tests/test_ratio_kl.py:43
↓ 2 callersFunction_logits
(batch, seed, *, device="cpu")
tests/test_grpo_loss.py:49
↓ 2 callersFunction_logp_backward_case
(name: str, *, seed: int = 0)
tests/test_op_checks.py:25
↓ 2 callersFunction_make_boundaries
(vocab_size: int, world_size: int, uneven: bool)
tests/linear_logp_tp.py:101
↓ 2 callersFunction_make_inputs
(args: argparse.Namespace, device: torch.device)
benchmarks/benchmark_stateless_executor.py:166
↓ 2 callersFunction_make_model
(args: argparse.Namespace, device: torch.device)
benchmarks/benchmark_stateless_executor.py:205
↓ 2 callersMethod_masked_mean
( values: torch.Tensor, bool_mask: torch.Tensor, eps: float = 1e-8 )
rl_engine/kernels/ops/triton/loss/grpo_loss.py:178
↓ 2 callersMethod_masked_mean
( values: torch.Tensor, bool_mask: torch.Tensor, eps: float = 1e-8 )
rl_engine/kernels/ops/pytorch/loss/grpo_loss.py:163
↓ 2 callersFunction_matmul_k
(args: argparse.Namespace)
rl_engine/kernels/gtest/operator_inputs.py:243
↓ 2 callersFunction_matmul_n
(args: argparse.Namespace)
rl_engine/kernels/gtest/operator_inputs.py:247
↓ 2 callersFunction_model_config_targets
(model: torch.nn.Module)
rl_engine/executors/stateless_executor.py:618
↓ 2 callersFunction_native_logp_fn
( *, batch_size: int, seq_len: int, vocab_size: int, dtype: torch.dtype, device: torch
benchmarks/profiler.py:499
↓ 2 callersFunction_parse_dtype
(name: str)
tests/linear_logp_tp.py:33
↓ 2 callersFunction_peak_memory_gb
(device: torch.device)
benchmarks/benchmark_ratio_kl.py:118
↓ 2 callersFunction_peak_vram_gb
(fn, warmup=3, iters=5)
benchmarks/benchmark_grpo_loss.py:60
↓ 2 callersFunction_perturb_inactive_logits
Set garbage at masked positions' logits; the loss must ignore them.
tests/test_grpo_loss.py:283
↓ 2 callersFunction_prepend_env_path
(key: str, path: Path)
rl_engine/executors/deepspeed_trainer.py:383
↓ 2 callersMethod_rebuild_cuda_ipc_tensor
(self, handle: Any)
rl_engine/executors/bridge.py:2588
↓ 2 callersFunction_reference_group_advantages
Mirror of examples.grpo_single_gpu.make_group_advantages normalization.
tests/test_grpo_loss.py:59
↓ 2 callersFunction_reference_logp_groups_from_grouped_outputs
( grouped_outputs: Sequence[Any], )
rl_engine/executors/training_contract.py:642
↓ 2 callersFunction_reference_selected_logp
(logits: torch.Tensor, token_ids: torch.Tensor)
tests/test_logp.py:28
↓ 2 callersFunction_require_tensor
(value: Any, source: str)
rl_engine/alignment/model_wrappers.py:14
↓ 2 callersFunction_required_storage_numel
( shape: tuple[int, ...], stride: tuple[int, ...], storage_offset: int, )
rl_engine/executors/bridge.py:769
↓ 2 callersMethod_reset_memory
(self)
benchmarks/profiler.py:177
↓ 2 callersFunction_reset_peak
(device: torch.device)
benchmarks/benchmark_ratio_kl.py:124
↓ 2 callersMethod_resolve_apply_model
(self)
rl_engine/executors/bridge.py:695
↓ 2 callersFunction_resolve_cuda_device_uuid
Return a stable identifier for a CUDA device. torch.cuda.get_device_properties(...).uuid only exists on PyTorch >= 2.6. This project sup
rl_engine/executors/bridge.py:799
↓ 2 callersFunction_resolve_tolerance
( contract: Mapping[str, Any], *, op_class: str, dtype: torch.dtype, arch_key: str | None
rl_engine/kernels/gtest/op_checks.py:403
↓ 2 callersFunction_reward_groups_from_grouped_outputs
(grouped_outputs: Sequence[Any])
rl_engine/executors/training_contract.py:625
↓ 2 callersMethod_rms_norm
( x: torch.Tensor, weight: torch.Tensor, *, eps: float, output_dtype:
rl_engine/kernels/ops/pytorch/norm/rms_norm.py:54
↓ 2 callersFunction_run_no_cache_forward
( model: torch.nn.Module, inputs: StatelessForwardInputs, )
rl_engine/executors/stateless_executor.py:474
↓ 2 callersFunction_safe_float
(value: Any)
rl_engine/executors/training_contract.py:878
↓ 2 callersFunction_safe_float
(value: Any)
rl_engine/executors/vllm_sampler.py:299
↓ 2 callersFunction_score_paged_kv
( args: argparse.Namespace, inputs: StatelessForwardInputs, model: torch.nn.Module, )
benchmarks/benchmark_stateless_executor.py:298
↓ 2 callersMethod_selected_logp
(self, logits: torch.Tensor, action_ids: torch.Tensor)
rl_engine/kernels/ops/pytorch/loss/ratio_kl.py:29
← previousnext →201–300 of 1,290, ranked by callers