unilab.ipc.replay_pipelines.transfer.torch_copy

Portable torch-copy replay transfer backend.

Classes

TorchCopyReplayTransferBackend

Portable transfer backend for CPU, MPS, and other torch devices.

class unilab.ipc.replay_pipelines.transfer.torch_copy.TorchCopyReplayTransferBackend[source]

Bases: object

Portable transfer backend for CPU, MPS, and other torch devices.

Parameters:
host_memory_kind = 'pageable_shared'
host_pinned = False
direct_pinned_shared = False
supports_async_submit = False
supports_timing_events = False
__init__(*, device, ring_depth)[source]
Parameters:
h2d_submitter = 'torch_copy'
register_host_slots(slots)[source]
Parameters:

slots (list[Tensor])

Return type:

None

allocate_device_slots(*, count, shape, dtype)[source]
Parameters:
Return type:

list[Tensor]

submit_h2d(*, slot, dst, src, metadata, trace_recorder, trace_cuda_events, h2d_bytes, pack_layout, pack_executor)[source]
Parameters:
Return type:

float

clear_ready(slot)[source]
Parameters:

slot (int)

Return type:

None

ready_query(slot)[source]
Parameters:

slot (int)

Return type:

bool

synchronize_ready(slot)[source]
Parameters:

slot (int)

Return type:

None

wait_current_stream_for_ready(slot)[source]
Parameters:

slot (int)

Return type:

None

close()[source]
Return type:

None