unilab.training.cuda_process_sharing.probe_cuda_process_sharing¶
- unilab.training.cuda_process_sharing.probe_cuda_process_sharing(requested, learner_device, collector_device, *, backend, rank=0, world_size=1, torch_module=None, run_command=<function run>)[source]¶
Validate one rank’s requested CUDA process-sharing mode.
- Parameters:
requested (
Any) – Owner valuenullormps.learner_device (
str) – Rank-local learner CUDA device.collector_device (
str|None) – Backend-bound collector CUDA device, when applicable.backend (
str) – Configured owner backend identity.rank (
int) – Current off-policy DP rank.world_size (
int) – Current single-host off-policy DP world size.torch_module (
Any|None) – Injectable Torch module for deterministic tests.run_command (
Callable[...,Any]) – Injectable subprocess runner for deterministic tests.
- Return type:
- Returns:
Evidence suitable for a per-rank runtime-manifest diagnostic section.
- Raises:
ValueError – The first unmet prerequisite for an explicit request.