integrate webrtc logic with whisper-jax-gokul branch

This commit is contained in:
Gokul Mohanarangan
2023-07-10 14:06:04 +05:30
parent 3f1c59abc6
commit 0d3f2c9072
10 changed files with 678 additions and 13 deletions

7
utils.py Normal file
View File

@@ -0,0 +1,7 @@
import asyncio
from functools import partial
def run_in_executor(func, *args, executor=None, **kwargs):
callback = partial(func, *args, **kwargs)
loop = asyncio.get_event_loop()
return asyncio.get_event_loop().run_in_executor(executor, callback)