Qilan2 commited on
Commit
0856fa5
·
verified ·
1 Parent(s): 46e33eb

Update sbx/a/c.py

Browse files
Files changed (1) hide show
  1. sbx/a/c.py +2 -2
sbx/a/c.py CHANGED
@@ -83,8 +83,8 @@ def check_system_resources():
83
  memory_usage = memory.percent
84
 
85
  # 检查CPU和内存占用是否超过85%
86
- if cpu_usage >= 90:
87
- # if cpu_usage >= 90 or memory_usage >= 90:
88
  print("占用过高")
89
  # 可选:打印具体的使用率
90
  print(f"CPU使用率: {cpu_usage}%")
 
83
  memory_usage = memory.percent
84
 
85
  # 检查CPU和内存占用是否超过85%
86
+ # if cpu_usage >= 90:
87
+ if cpu_usage >= 90 or memory_usage >= 95:
88
  print("占用过高")
89
  # 可选:打印具体的使用率
90
  print(f"CPU使用率: {cpu_usage}%")