pub struct Device {Show 14 fields
pub id: usize,
pub name: String,
pub backend: DeviceBackend,
pub memory_mb: u64,
pub compute_units: u32,
pub pci_bus_id: Option<String>,
pub partition_id: Option<String>,
pub driver_version: Option<String>,
pub cuda_version: Option<String>,
pub compute_capability: Option<String>,
pub utilization_gpu_pct: Option<u32>,
pub temperature_c: Option<u32>,
pub supports_fp16: bool,
pub supports_int8: bool,
}Fields§
§id: usize§name: String§backend: DeviceBackend§memory_mb: u64§compute_units: u32§pci_bus_id: Option<String>§partition_id: Option<String>Stable partition identifier for sub-device addressing.
For NVIDIA devices this is the GPU UUID (e.g.
"GPU-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"), which survives
index reordering. For MIG compute instances the MIG UUID
(e.g. "MIG-GPU-xxx/0/0") is stored here instead.
Matched by GpuPreference::Partition using the mig:<id> or
partition:<id> selector syntax. None for backends that do
not expose a stable UUID.
driver_version: Option<String>Driver version string (when available).
cuda_version: Option<String>CUDA version string (e.g. “12.0”) for CUDA-capable devices.
compute_capability: Option<String>CUDA compute capability (e.g. “8.6”) for CUDA devices.
utilization_gpu_pct: Option<u32>§temperature_c: Option<u32>§supports_fp16: bool§supports_int8: boolTrait Implementations§
Source§impl<'de> Deserialize<'de> for Device
impl<'de> Deserialize<'de> for Device
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Device
impl RefUnwindSafe for Device
impl Send for Device
impl Sync for Device
impl Unpin for Device
impl UnsafeUnpin for Device
impl UnwindSafe for Device
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