bugfix
This commit is contained in:
parent
a4dc6ef93c
commit
183c50fd51
@ -6,8 +6,6 @@ from aiortc import VideoStreamTrack, AudioStreamTrack
|
||||
class LLMAudioStreamTrack(AudioStreamTrack):
|
||||
def __init__(self, omni_infer):
|
||||
super().__init__()
|
||||
self.ckpt_dir = ckpt_dir
|
||||
# self.oi = OmniInference(ckpt_dir=ckpt_dir)
|
||||
self.oi = omni_infer
|
||||
self.audio_iters = []
|
||||
self.cur_iters = None
|
||||
|
@ -50,7 +50,6 @@ class RTCLLM:
|
||||
def __init__(self, ws_url, iceServers):
|
||||
# self.stt_model = WhisperModel('large-v3', device="cuda", compute_type="float16")
|
||||
self.ws_url = ws_url
|
||||
self.omni_infer =
|
||||
self.omni_infer = OmniInference(ckpt_dir='/d/models/mini-omni')
|
||||
self.iceServers = iceServers
|
||||
self.peers = DictObject()
|
||||
@ -116,7 +115,7 @@ class RTCLLM:
|
||||
async def auto_accept_call(self, data):
|
||||
opts = DictObject(iceServers=self.iceServers)
|
||||
pc = RTCPeerConnection(opts)
|
||||
llmtrack = LLMAudioStreamTrack('/d/models/mini-omni')
|
||||
llmtrack = LLMAudioStreamTrack(self.omni_infer)
|
||||
feed = awaitify(self.llmtrack._feed)
|
||||
self.peers[data['from'].id] = DictObject(**{
|
||||
'info':data['from'],
|
||||
|
Loading…
Reference in New Issue
Block a user