fix again
This commit is contained in:
parent
9977182047
commit
90f1381f4f
|
@ -3,6 +3,7 @@ import time
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
from threading import Semaphore, Thread
|
from threading import Semaphore, Thread
|
||||||
|
|
||||||
|
from llm_server import opts
|
||||||
from llm_server.integer import ThreadSafeInteger
|
from llm_server.integer import ThreadSafeInteger
|
||||||
from llm_server.opts import concurrent_generates
|
from llm_server.opts import concurrent_generates
|
||||||
|
|
||||||
|
@ -22,7 +23,7 @@ class SemaphoreCheckerThread(Thread):
|
||||||
def run(self):
|
def run(self):
|
||||||
global proompters_1_min
|
global proompters_1_min
|
||||||
while True:
|
while True:
|
||||||
self.values.append(self.semaphore._value)
|
self.values.append(opts.concurrent_generates - concurrent_semaphore._value)
|
||||||
proompters_1_min = sum(self.values) / len(self.values)
|
proompters_1_min = sum(self.values) / len(self.values)
|
||||||
time.sleep(1)
|
time.sleep(1)
|
||||||
|
|
||||||
|
|
Reference in New Issue