mirror of
https://github.com/morgan9e/macos-stats
synced 2026-04-14 00:04:15 +09:00
fix: limit the GPU utilization to 100% (#649)
This commit is contained in:
@@ -157,7 +157,10 @@ internal class InfoReader: Reader<GPUs> {
|
||||
self.gpus.list[idx].state = state == 0
|
||||
}
|
||||
|
||||
if let value = utilization {
|
||||
if var value = utilization {
|
||||
if value > 100 {
|
||||
value = 100
|
||||
}
|
||||
self.gpus.list[idx].utilization = Double(value)/100
|
||||
}
|
||||
if let value = temperature {
|
||||
|
||||
Reference in New Issue
Block a user