websocket
This commit is contained in:
parent
00dc9b02eb
commit
c21f7a8d38
@ -47,8 +47,9 @@ def start_train_algorithm():
|
||||
def wrapped_function():
|
||||
param = request.args.get('param')
|
||||
id = request.args.get('id')
|
||||
t = Thread(target=func, args=(param, id))
|
||||
#t = Process(target=func, args=(param, id), name=id)
|
||||
dict = manager.active_connections_dist
|
||||
# t = Thread(target=func, args=(param, id))
|
||||
t = Process(target=func, args=(param, id, dict[id]), name=id)
|
||||
set_value(key=id, value=False)
|
||||
t.start()
|
||||
return output_wrapped(0, 'success', '成功')
|
||||
@ -302,6 +303,7 @@ def error_return(id: str, data):
|
||||
# 启动训练
|
||||
@start_train_algorithm()
|
||||
def train_R0DY(params_str, id, getsomething):
|
||||
manager.active_connections_dist[id] = getsomething
|
||||
print('**********************************')
|
||||
print(params_str)
|
||||
print('**********************************')
|
||||
|
Loading…
x
Reference in New Issue
Block a user