MCPcopy Create free account

hub / github.com/RL-Align/RL-Kernel / types & classes

Types & classes193 in github.com/RL-Align/RL-Kernel

↓ 73 callersClassWeightManifestValidationError
Raised when a weight update manifest is incomplete or inconsistent.
rl_engine/executors/bridge.py:1343
↓ 45 callersClassWeightBridgeUnavailableError
Raised when a requested transport is not supported by this runtime.
rl_engine/executors/bridge.py:1339
↓ 34 callersClassLocalTensorCopyBridge
Safe local transport for the weight synchronization protocol. This transport intentionally copies tensors. It is not the final zero-copy
rl_engine/executors/bridge.py:1508
↓ 27 callersClassNativeLogpOp
Pure PyTorch native fallback for Fused LogP.
rl_engine/kernels/ops/pytorch/loss/logp.py:9
↓ 27 callersClassSharedMemoryTensorBridge
Same-node shared-memory transport with zero-copy import semantics. Publishing creates a shared-memory snapshot of model state. Importing tha
rl_engine/executors/bridge.py:1696
↓ 26 callersClassNativeAttentionOp
Pure PyTorch native standard-softmax attention reference. out = softmax(Q Kᵀ * scale + masks) @ V Hand-written naive softmax -- delibera
rl_engine/kernels/ops/pytorch/attention/standard_attn.py:13
↓ 24 callersClassNativeLinearLogpOp
Naive PyTorch reference for fused linear log-prob. Materializes the full ``[N, V]`` logits with a single ``F.linear`` and runs ``log_softmax`
rl_engine/kernels/ops/pytorch/loss/linear_logp.py:442
↓ 17 callersClassNativeRoPEOp
Pure PyTorch reference RoPE — GPT-NeoX style (HF rotate-half). Qwen3-8B defaults: theta=1e6, head_dim=128, full-dimension rotation (half=64).
rl_engine/kernels/ops/pytorch/rotary_embedding/rope.py:10
↓ 17 callersClassStatelessForwardConfig
Configuration for no-cache reference/reward model scoring.
rl_engine/executors/stateless_executor.py:23
↓ 13 callersClassNativeGRPOLossOp
Pure PyTorch native fallback for the fused GRPO loss. Consumes logits directly: the per-token ``policy_ratio`` / ``kl_penalty`` come from the
rl_engine/kernels/ops/pytorch/loss/grpo_loss.py:13
↓ 13 callersClassNativeKVCacheAttnOp
Pure PyTorch native KV-cache attention reference (ISSUE #108 WS1). Decode/incremental attention: the past keys/values live in a cache and th
rl_engine/kernels/ops/pytorch/attention/kv_cache.py:13
↓ 13 callersClassStatelessForwardExecutor
Lightweight Reference/Reward scoring wrapper. The executor runs one full-sequence forward pass with ``use_cache=False`` whenever the wra
rl_engine/executors/stateless_executor.py:93
↓ 13 callersClassWeightUpdateRejectedError
Raised when a weight update cannot be imported or acknowledged.
rl_engine/executors/bridge.py:1347
↓ 12 callersClassNativeLMHeadOp
Pure PyTorch native language-model-head reference. out = hidden @ weight.t() (+ bias) Projects hidden states back to vocabulary logits -
rl_engine/kernels/ops/pytorch/linear/lm_head.py:12
↓ 12 callersClassNativeMatmulOp
Pure PyTorch reference GEMM. It intentionally uses one `torch.matmul` call in fp32 for the gold path and does not implement split-K or manual
rl_engine/kernels/ops/pytorch/linear/matmul.py:10
↓ 12 callersClassNativeRMSNormOp
Pure Pytorch native RMSNorm reference out = x * rsqrt(mean(x^2, dim=-1) + eps) * weight
rl_engine/kernels/ops/pytorch/norm/rms_norm.py:9
↓ 10 callersClassFusedLinearLogpSM90Op
SM90 (Hopper) TMA+WGMMA fused linear log-prob. Computes ``log_softmax(hidden @ W^T + b)[target]`` without materializing the ``[N, V]`` logits
rl_engine/kernels/ops/cuda/loss/linear_logp.py:252
↓ 10 callersClassRolloutExecutor
Unified execution engine for RL rollout (sampling) phase. Manages shared weights and dispatches hardware-specific kernels for large-scale sam
rl_engine/executors/rollout.py:22
↓ 10 callersClassTritonLinearLogpOp
Triton fused linear log-prob op. Computes per-token ``log_softmax(hidden @ W^T + b)[target]`` without materializing the ``[N, V]`` logits: th
rl_engine/kernels/ops/triton/loss/linear_logp.py:157
↓ 10 callersClassVLLMWeightInstallAdapter
Guarded adapter for installing imported tensors into a rollout engine. vLLM does not expose one stable public hot-weight update API across v
rl_engine/executors/bridge.py:110
↓ 9 callersClassCUDAVMMTensorBridge
Same-node CUDA VMM transport with POSIX-fd zero-copy import semantics. This is the modern CUDA IPC path for WSL2/native Linux runtimes where
rl_engine/executors/bridge.py:1993
↓ 9 callersClassCandidateSpec
One implementation to validate against the gold path.
rl_engine/kernels/gtest/op_checks.py:28
↓ 9 callersClassFixedLogitsModel
tests/test_alignment_model_wrappers.py:20
↓ 9 callersClassKernelRegistry
Central dispatcher for high-performance kernels. Handles dynamic routing between ROCm and CUDA backends at runtime.
rl_engine/kernels/registry.py:80
↓ 9 callersClassNativeEmbeddingOp
Pure PyTorch native token-embedding reference. out = weight[token_ids] (a plain row gather, no accumulation) Maps integer token ids to
rl_engine/kernels/ops/pytorch/linear/embedding.py:10
↓ 9 callersClassNativeRatioKLOp
PyTorch native fallback for the fused ratio + KL operator.
rl_engine/kernels/ops/pytorch/loss/ratio_kl.py:13
↓ 9 callersClassStatelessForwardInputs
Dense full-sequence batch for stateless scoring.
rl_engine/executors/stateless_executor.py:53
↓ 8 callersClassDeepSpeedTrainingConfig
Configuration for the optional DeepSpeed training worker.
rl_engine/executors/deepspeed_trainer.py:42
↓ 8 callersClassNativeSwiGLUOp
Pure PyTorch native SwiGLU reference. out = silu(gate) * up = (gate * sigmoid(gate)) * up Middle stage of the Qwen3/Llama MLP: ``gate``
rl_engine/kernels/ops/pytorch/activation/swiglu.py:44
↓ 8 callersClassTritonGRPOLossOp
Triton fused GRPO loss op. The per-token ``policy_ratio`` / ``kl_penalty`` are produced by the fused ``ratio_kl`` Triton kernel (logits -> ra
rl_engine/kernels/ops/triton/loss/grpo_loss.py:58
↓ 7 callersClassDeepSpeedTrainingWorker
Training worker implementation backed by a real DeepSpeed engine contract. DeepSpeed is optional for RL-Kernel, so importing this module nev
rl_engine/executors/deepspeed_trainer.py:73
↓ 7 callersClassIPCWeightBridge
Same-node legacy PyTorch CUDA IPC transport. Publishing creates a complete CUDA snapshot and stores PyTorch `reduce_tensor` handles in t
rl_engine/executors/bridge.py:2371
↓ 7 callersClassNativeSiLUOp
Pure PyTorch native SiLU reference. out = x * sigmoid(x) (a.k.a. Swish) Element-wise activation used by the Qwen3 SwiGLU MLP (hidd
rl_engine/kernels/ops/pytorch/activation/swiglu.py:10
↓ 7 callersClassTritonRatioKLOp
Fused policy-ratio + KL-penalty op (Triton; CUDA & ROCm).
rl_engine/kernels/ops/triton/loss/ratio_kl.py:183
↓ 7 callersClass_LocalUpdateRecord
rl_engine/executors/bridge.py:1445
↓ 6 callersClassRolloutStageResult
Result consumed by training workers.
rl_engine/executors/training_contract.py:21
↓ 5 callersClassBenchmarkMetrics
End-to-end performance metrics for a single benchmark run.
benchmarks/profiler.py:42
↓ 5 callersClassPagedKVScoringConfig
Configuration for a generation-style paged-KV scoring baseline.
rl_engine/executors/paged_kv_baseline.py:29
↓ 5 callersClassPolicyModelWrapper
Standard adapter for the trainable policy model used by RL losses.
rl_engine/alignment/model_wrappers.py:77
↓ 5 callersClassRayWorkerSpec
Factory and constructor arguments for a worker hosted in a Ray actor.
rl_engine/executors/ray_actor_manager.py:66
↓ 5 callersClassVLLMIPCWeightUpdateRequestBuilder
Build the public vLLM IPC weight-update request shape. vLLM 0.18+ expects `LLM.update_weights({"update_info": ...})` for IPC backends. T
rl_engine/executors/bridge.py:191
↓ 5 callersClassVLLMSharedPrefixSampler
Lazy vLLM wrapper that preserves shared prompt prefixes across candidates.
rl_engine/executors/vllm_sampler.py:77
↓ 4 callersClassFakeLLMEngine
tests/test_weight_sync_bridge.py:699
↓ 4 callersClassNativeAttentionOp
PyTorch SDPA fallback for FlashAttention-layout tensors.
rl_engine/kernels/ops/pytorch/attention/__init__.py:8
↓ 4 callersClassOperatorCase
One deterministic test object for an operator candidate.
rl_engine/kernels/gtest/op_checks.py:16
↓ 4 callersClassRayRuntimeConfig
Configuration for lazy Ray runtime initialization.
rl_engine/executors/ray_actor_manager.py:18
↓ 4 callersClassStatelessForwardOutputs
Normalized model outputs consumed by scoring adapters.
rl_engine/executors/stateless_executor.py:63
↓ 4 callersClassVLLMCUDAVMMExternalStorageAdapter
Bind vLLM worker parameters to tensors imported from a CUDA VMM manifest. The vLLM worker imports the manifest itself through `apply_model`,
rl_engine/executors/bridge.py:617
↓ 4 callersClassVLLMInProcessWeightReloadAdapter
Install a manifest through vLLM's in-process `reload_weights` utility path. This adapter is for single-process vLLM deployments, for example
rl_engine/executors/bridge.py:327
↓ 4 callersClassVLLMSamplerConfig
Configuration for vLLM-backed GRPO rollout sampling.
rl_engine/executors/vllm_sampler.py:12
↓ 4 callersClassWeightUpdateManifest
Immutable public record for a complete published weight update.
rl_engine/executors/bridge.py:1387
↓ 4 callersClass_EmbeddingLMHeadModel
rl_engine/executors/deepspeed_trainer.py:54
↓ 3 callersClassBatchOnlyWorker
tests/test_stateless_training_contract.py:22
↓ 3 callersClassFakeRayModule
tests/test_ray_actor_manager.py:68
↓ 3 callersClassFakeVLLMEngine
tests/test_weight_sync_bridge.py:562
↓ 3 callersClassPerformanceProfiler
Automated end-to-end performance profiling suite. Measures Tokens/sec, TFLOPS, and peak VRAM across different GPU targets for RL-Kernel
benchmarks/profiler.py:156
↓ 3 callersClassRayActorManager
Create, wrap, and clean up Ray actors for RL-Kernel workers.
rl_engine/executors/ray_actor_manager.py:75
↓ 3 callersClassRocmFlashAttentionOp
Standard FlashAttention wrapper for ROCm. Demonstrates the reference structure for adding new operator families.
rl_engine/kernels/ops/rocm/attention/flash_attn.py:18
↓ 3 callersClassTorchRLTrainingConfig
Config shared by local and DeepSpeed training workers.
rl_engine/executors/training_contract.py:57
↓ 3 callersClassVLLMCheckpointWeightReloadAdapter
Install a manifest through vLLM's checkpoint-path reload utility path. This path works with vLLM's default EngineCore multiprocessing becaus
rl_engine/executors/bridge.py:436
↓ 2 callersClassCaseCheck
Per-case result for one candidate.
rl_engine/kernels/gtest/op_checks.py:55
↓ 2 callersClassDeepSpeedUnavailableError
Raised when the optional DeepSpeed runtime cannot be imported.
rl_engine/executors/deepspeed_trainer.py:37
↓ 2 callersClassFakeDeepSpeedModule
tests/test_deepspeed_training_worker.py:48
↓ 2 callersClassFakeLLM
tests/test_weight_sync_bridge.py:703
↓ 2 callersClassFakeReferenceModel
tests/test_stateless_executor.py:25
↓ 2 callersClassFakeReloadEngine
tests/test_weight_sync_bridge.py:735
↓ 2 callersClassFakeRemoteActorClass
tests/test_ray_actor_manager.py:50
↓ 2 callersClassFlashAttentionOp
Standard FlashAttention wrapper for CUDA. Demonstrates the reference structure for adding new operator families.
rl_engine/kernels/ops/cuda/attention/flash_attn.py:10
↓ 2 callersClassGPUTargetInfo
Hardware target identification for cross-GPU benchmarking.
benchmarks/profiler.py:29
↓ 2 callersClassIterationSpec
tests/test_ray_actor_manager.py:20
↓ 2 callersClassNormalizedRolloutCandidate
Stable RL-Kernel view over a vLLM request output candidate.
rl_engine/executors/vllm_sampler.py:56
↓ 2 callersClassObjectOutput
tests/test_alignment_model_wrappers.py:16
↓ 2 callersClassOperatorSpec
rl_engine/kernels/gtest/operator_specs.py:18
↓ 2 callersClassOutputCheck
Per-output comparison result.
rl_engine/kernels/gtest/op_checks.py:38
↓ 2 callersClassPagedKVScoringBaseline
Correctness-first baseline for generation-engine-style scoring. This wrapper reserves a paged KV-cache and block table before running the
rl_engine/executors/paged_kv_baseline.py:85
↓ 2 callersClassReferenceModelWrapper
Standard adapter for the frozen reference model used by KL penalties.
rl_engine/alignment/model_wrappers.py:113
↓ 2 callersClassSamplerBackend
rl_engine/kernels/sampling.py:11
↓ 2 callersClassStatelessForwardResult
Scoring tensors and scalar metrics produced by the stateless executor.
rl_engine/executors/stateless_executor.py:72
↓ 2 callersClassStatelessScoringWorker
Attach no-cache reference/reward scores to a completed rollout payload.
rl_engine/executors/training_contract.py:316
↓ 2 callersClassSyntheticRLKernelBatch
Synthetic RL-shaped tensors shared by kernel tests and benchmarks.
rl_engine/testing/rl_batch.py:13
↓ 2 callersClassTrainingStageResult
Result produced by training workers.
rl_engine/executors/training_contract.py:37
↓ 2 callersClass_StateDictModule
benchmarks/benchmark_weight_sync_bridge.py:649
↓ 1 callersClassBenchmarkConfig
benchmarks/benchmark_rl_kernels.py:56
↓ 1 callersClassBenchmarkConfig
benchmarks/benchmark_ratio_kl.py:51
↓ 1 callersClassCacheReturningModel
tests/test_stateless_executor.py:70
↓ 1 callersClassCandidateReport
Aggregate report for one candidate implementation.
rl_engine/kernels/gtest/op_checks.py:66
↓ 1 callersClassConstants
rl_engine/platforms/constants.py:96
↓ 1 callersClassDeviceContext
Hardware-aware context manager for high-performance RL tasks. Provides transparent support for both AMD (ROCm/HIP) and NVIDIA (CUDA) arc
rl_engine/platforms/device.py:10
↓ 1 callersClassFailingReloadEngine
tests/test_weight_sync_bridge.py:772
↓ 1 callersClassFailingVLLMEngine
tests/test_weight_sync_bridge.py:679
↓ 1 callersClassFakeActorHandle
tests/test_ray_actor_manager.py:41
↓ 1 callersClassFakeBothModel
tests/test_stateless_executor.py:220
↓ 1 callersClassFakeDeepSpeedEngine
tests/test_deepspeed_training_worker.py:22
↓ 1 callersClassFakeGenerationReferenceModel
tests/test_paged_kv_baseline.py:21
↓ 1 callersClassFakeObjectRef
tests/test_ray_actor_manager.py:26
↓ 1 callersClassFakeReferenceRewardScorer
tests/test_stateless_training_contract.py:165
↓ 1 callersClassFakeRemoteMethod
tests/test_ray_actor_manager.py:31
↓ 1 callersClassFakeRewardModel
tests/test_stateless_executor.py:50
↓ 1 callersClassFakeRewardScorer
tests/test_stateless_training_contract.py:99
↓ 1 callersClassFallback
tests/test_op_accuracy.py:209
next →1–100 of 193, ranked by callers