pub struct CaptureBridge;Expand description
Bridge for materialized values between independent capture devices.
Only initialized tensors have handles in the capture backend, so values reaching this bridge
are concrete and can safely initialize a tensor in another capture scope. Computed tensors have
no materialized handle and are rejected by CaptureChannel::get_tensor_handle first.
Trait Implementations§
Source§impl MultiBackendBridge for CaptureBridge
impl MultiBackendBridge for CaptureBridge
Source§type TensorHandle = TensorData
type TensorHandle = TensorData
The type that can be used to point to a tensor of any kind.
Source§type Device = CaptureDevice
type Device = CaptureDevice
Device type used by the backends.
Source§fn change_backend_float(
tensor: TensorData,
_shape: Shape,
_target: &Self::Device,
) -> TensorData
fn change_backend_float( tensor: TensorData, _shape: Shape, _target: &Self::Device, ) -> TensorData
Change the backend of the given float tensor.
Source§fn change_backend_int(
tensor: TensorData,
_shape: Shape,
_target: &Self::Device,
) -> TensorData
fn change_backend_int( tensor: TensorData, _shape: Shape, _target: &Self::Device, ) -> TensorData
Change the backend of the given int tensor.
Source§fn change_backend_bool(
tensor: TensorData,
_shape: Shape,
_target: &Self::Device,
) -> TensorData
fn change_backend_bool( tensor: TensorData, _shape: Shape, _target: &Self::Device, ) -> TensorData
Change the backend of the given bool tensor.
Auto Trait Implementations§
impl Freeze for CaptureBridge
impl RefUnwindSafe for CaptureBridge
impl Send for CaptureBridge
impl Sync for CaptureBridge
impl Unpin for CaptureBridge
impl UnsafeUnpin for CaptureBridge
impl UnwindSafe for CaptureBridge
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more