Mojo struct
Device
struct Device
Fields
- idx (
Int
): - device (
_DeviceImpl
):
Implemented traits
AnyType
,
UnknownDestructibility
,
Writable
Methods
__init__
__init__(out self, idx: Int = 0)
__copyinit__
__copyinit__(out self, existing: Self)
get_driver_version
get_driver_version(self) -> DriverVersion
Returns NVIDIA driver version.
max_mem_clock
max_mem_clock(self) -> Int
max_graphics_clock
max_graphics_clock(self) -> Int
mem_clocks
mem_clocks(self) -> List[Int, True]
graphics_clocks
graphics_clocks(self, memory_clock_mhz: Int) -> List[Int, True]
set_clock
set_clock(self, mem_clock: Int, graphics_clock: Int)
gpu_turbo_enabled
gpu_turbo_enabled(self) -> Bool
Returns True if the gpu turbo is enabled.
set_gpu_turbo
set_gpu_turbo(self, enabled: Bool = True)
Sets the GPU turbo state.
get_persistence_mode
get_persistence_mode(self) -> Bool
Returns True if the gpu persistence mode is enabled.
set_persistence_mode
set_persistence_mode(self, enabled: Bool = True)
Sets the persistence mode.
set_max_gpu_clocks
set_max_gpu_clocks(device)
__str__
__str__(self) -> String
write_to
write_to[W: Writer](self, mut writer: W)
__repr__
__repr__(self) -> String
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!