Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 74efc2cb42 | |||
| db3096bbaf | |||
| a4339bd3f1 | |||
| 2b26e5e20c | |||
| d3727d4fd7 |
+2
-2
@@ -30,7 +30,7 @@ from lib.data_types import (
|
|||||||
BenchmarkResult
|
BenchmarkResult
|
||||||
)
|
)
|
||||||
|
|
||||||
VERSION = "0.2.0"
|
VERSION = "0.2.1"
|
||||||
|
|
||||||
MSG_HISTORY_LEN = 100
|
MSG_HISTORY_LEN = 100
|
||||||
log = logging.getLogger(__file__)
|
log = logging.getLogger(__file__)
|
||||||
@@ -417,7 +417,7 @@ class Backend:
|
|||||||
|
|
||||||
async def tail_log():
|
async def tail_log():
|
||||||
log.debug(f"tailing file: {self.model_log_file}")
|
log.debug(f"tailing file: {self.model_log_file}")
|
||||||
async with await open_file(self.model_log_file, encoding='utf-8', errors='ignore'):
|
async with await open_file(self.model_log_file, encoding='utf-8', errors='ignore') as f:
|
||||||
while True:
|
while True:
|
||||||
line = await f.readline()
|
line = await f.readline()
|
||||||
if line:
|
if line:
|
||||||
|
|||||||
+2
-2
@@ -146,6 +146,7 @@ class Metrics:
|
|||||||
def _set_mtoken(self, mtoken: str) -> None:
|
def _set_mtoken(self, mtoken: str) -> None:
|
||||||
self.mtoken = mtoken
|
self.mtoken = mtoken
|
||||||
|
|
||||||
|
|
||||||
#######################################Private#######################################
|
#######################################Private#######################################
|
||||||
|
|
||||||
async def __send_delete_requests_and_reset(self):
|
async def __send_delete_requests_and_reset(self):
|
||||||
@@ -216,7 +217,7 @@ class Metrics:
|
|||||||
id=self.id,
|
id=self.id,
|
||||||
mtoken=self.mtoken,
|
mtoken=self.mtoken,
|
||||||
version=self.version,
|
version=self.version,
|
||||||
loadtime=(loadtime_snapshot or 0.0),
|
loadtime=(loadtime_snapshot or 0.0),
|
||||||
new_load=self.model_metrics.workload_processing,
|
new_load=self.model_metrics.workload_processing,
|
||||||
cur_load=self.model_metrics.cur_load,
|
cur_load=self.model_metrics.cur_load,
|
||||||
rej_load=self.model_metrics.workload_rejected,
|
rej_load=self.model_metrics.workload_rejected,
|
||||||
@@ -280,7 +281,6 @@ class Metrics:
|
|||||||
|
|
||||||
if sent:
|
if sent:
|
||||||
# clear the one-shot loadtime only if we actually sent *this* value
|
# clear the one-shot loadtime only if we actually sent *this* value
|
||||||
self.system_metrics.reset(expected=loadtime_snapshot)
|
|
||||||
self.update_pending = False
|
self.update_pending = False
|
||||||
self.model_metrics.reset()
|
self.model_metrics.reset()
|
||||||
self.last_metric_update = time.time()
|
self.last_metric_update = time.time()
|
||||||
|
|||||||
+1
-1
@@ -8,4 +8,4 @@ Requests~=2.32
|
|||||||
transformers~=4.52
|
transformers~=4.52
|
||||||
utils==1.0.*
|
utils==1.0.*
|
||||||
hf_transfer>=0.1.9
|
hf_transfer>=0.1.9
|
||||||
vastai-sdk>=0.2.0g
|
vastai-sdk>=0.2.0
|
||||||
Reference in New Issue
Block a user