pub struct Gpus {
pub count: Option<GpuCount>,
pub ids: Vec<String>,
pub driver: Option<String>,
pub capabilities: Vec<String>,
pub options: IndexMap<String, String>,
}Expand description
The GPUs a machine is given. A container gets the host’s GPUs through its runtime; a VM gets them passed through by its hypervisor (Proxmox) or sized with them (a cloud’s GPU instance types).
Fields§
§count: Option<GpuCount>How many GPUs, or all the host has. Default: one, unless ids names them.
ids: Vec<String>Which GPUs, by the host’s ids: a device index or UUID for a container, a PCI address
(0000:01:00.0) or a resource mapping’s name on Proxmox. Not with count.
driver: Option<String>The GPUs’ vendor driver (nvidia, amd, intel). Default: nvidia.
capabilities: Vec<String>What the container may use the GPUs for, as NVIDIA’s runtime names it (compute,
utility, video, graphics, display). Default: the runtime’s own. A VM gets the
whole device, so every capability.
options: IndexMap<String, String>Options for the container runtime’s GPU driver, passed as they are (Compose only).
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Gpus
impl<'de> Deserialize<'de> for Gpus
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>,
impl Eq for Gpus
impl StructuralPartialEq for Gpus
Auto Trait Implementations§
impl Freeze for Gpus
impl RefUnwindSafe for Gpus
impl Send for Gpus
impl Sync for Gpus
impl Unpin for Gpus
impl UnsafeUnpin for Gpus
impl UnwindSafe for Gpus
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.