Enum SensorType
- Namespace
- DotCompute.Abstractions.Health
- Assembly
- DotCompute.Abstractions.dll
Defines the types of sensors available for device health monitoring.
public enum SensorType
Fields
ComputeUtilization = 2Compute utilization percentage (0-100). Indicates how busy the device's compute cores are.
For GPUs: Percentage of time at least one kernel is executing For CPUs: Average utilization across all cores
Custom = 999Custom vendor-specific sensor. Used for platform-specific metrics not covered by standard types.
Check SensorReading.Name property for vendor-specific identifier. Examples:
- NVIDIA: NVLink throughput
- AMD: Infinity Fabric metrics
- Intel: EU (Execution Unit) utilization
ErrorCount = 16Number of compute errors detected. Includes ECC errors, kernel crashes, and device resets.
High error counts may indicate:
- Hardware issues
- Driver instability
- Overheating
- Power supply problems
FanSpeed = 4Fan speed percentage (0-100). Only available on devices with active cooling fans.
Typically only available on:
- Desktop discrete GPUs
- Some high-end workstation CPUs Not available on mobile devices or passively cooled hardware.
GraphicsClock = 5Graphics (core) clock frequency in MHz. Indicates current operating frequency of compute cores.
May vary dynamically based on:
- Workload
- Temperature
- Power limits
- Boost clocks
MemoryClock = 6Memory clock frequency in MHz. Indicates current operating frequency of device memory.
MemoryFreeBytes = 9Available (free) device memory in bytes. Calculated as: TotalMemory - UsedMemory
MemoryTotalBytes = 8Total device memory capacity in bytes.
MemoryUsedBytes = 7Absolute amount of memory currently used in bytes. Different from MemoryUtilization which measures bandwidth.
MemoryUtilization = 3Memory utilization percentage (0-100). Indicates memory bandwidth usage, not capacity.
Measures memory controller activity, not allocated memory. For capacity usage, see MemoryUsedBytes and MemoryTotalBytes.
PcieLinkGeneration = 10PCIe generation in use (e.g., 3 for PCIe 3.0, 4 for PCIe 4.0). Only applicable to PCIe-attached devices.
Not available for:
- Integrated GPUs
- Apple Silicon unified memory systems
- CPU backends
PcieLinkWidth = 11PCIe link width (number of lanes, e.g., 8, 16). Only applicable to PCIe-attached devices.
PcieThroughputRx = 13PCIe receive throughput in bytes per second. Measures data received from device to host.
PcieThroughputTx = 12PCIe transmit throughput in bytes per second. Measures data sent from host to device.
PowerDraw = 1Power consumption in watts. Primarily supported by discrete GPUs with power monitoring.
NVIDIA GPUs: Available via NVML AMD GPUs: Available via ROCm SMI Intel GPUs: Limited availability CPUs: Available on some platforms via RAPL (Running Average Power Limit)
PowerThrottlingStatus = 15Power throttling status (0 = none, >0 = active throttling). Indicates performance reduction due to power limits.
Temperature = 0Temperature sensor in degrees Celsius. Supported by most GPU and CPU devices.
Typical ranges:
- GPU: 30-95°C (throttling typically begins at 80-85°C)
- CPU: 30-100°C (varies by model and TDP)
ThrottlingStatus = 14Thermal throttling status (0 = none, >0 = active throttling). Indicates performance reduction due to thermal limits.
Values may indicate severity:
- 0: No throttling
- 1: Slight throttling
- 2: Moderate throttling
- 3+: Severe throttling
Check vendor documentation for specific meanings.
Remarks
Different compute devices support different sensor types. CPU devices typically support temperature and utilization sensors, while GPU devices may additionally support power, fan speed, clock frequencies, and memory statistics.
Availability varies by:
- Backend type (CUDA, OpenCL, Metal, CPU)
- Hardware vendor (NVIDIA, AMD, Intel, Apple)
- Driver version and capabilities
- Operating system
Applications should check sensor availability before querying values.