pub struct NvmlDevice<'a> { /* private fields */ }Expand description
2026-09-26: One device’s queries. Ok(None) when the entry point is absent
or answers NVML_ERROR_NOT_SUPPORTED or NVML_ERROR_NO_PERMISSION;
Err(code) for any other failure.
Implementations§
Source§impl NvmlDevice<'_>
impl NvmlDevice<'_>
pub fn power_mw(&self) -> Result<Option<u32>, NvmlReturn>
pub fn total_energy_mj(&self) -> Result<Option<u64>, NvmlReturn>
pub fn clock_mhz(&self, clock: c_uint) -> Result<Option<u32>, NvmlReturn>
pub fn temperature_c(&self) -> Result<Option<u32>, NvmlReturn>
pub fn clocks_event_reasons(&self) -> Result<Option<u64>, NvmlReturn>
pub fn memory(&self) -> Result<Option<NvmlMemory>, NvmlReturn>
pub fn pcie_kbps(&self, counter: c_uint) -> Result<Option<u32>, NvmlReturn>
Sourcepub fn nvlink_active_links(&self) -> Option<u32>
pub fn nvlink_active_links(&self) -> Option<u32>
2026-09-26: The number of links in 0..NVML_NVLINK_MAX_LINKS whose
state query succeeds with state 1; None when no link query succeeds.
A failed per-link query counts as no such link, not as an error.
Trait Implementations§
impl Send for NvmlDevice<'_>
Auto Trait Implementations§
impl<'a> Freeze for NvmlDevice<'a>
impl<'a> RefUnwindSafe for NvmlDevice<'a>
impl<'a> !Sync for NvmlDevice<'a>
impl<'a> Unpin for NvmlDevice<'a>
impl<'a> UnwindSafe for NvmlDevice<'a>
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