MCPcopy Create free account
hub / github.com/cppla/ServerStatus / get_cpu

Function get_cpu

clients/client-linux.py:128–134  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

126 return y
127
128def get_cpu():
129 t = delta_time()
130 st = sum(t)
131 if st == 0:
132 st = 1
133 result = 100-(t[len(t)-1]*100.00/st)
134 return round(result, 1)
135
136def liuliang():
137 NET_IN = 0

Callers 1

client-linux.pyFile · 0.70

Calls 1

delta_timeFunction · 0.85

Tested by

no test coverage detected