mirror of
https://github.com/modelscope/FunASR
synced 2025-09-15 14:48:36 +08:00
Update funasr_wss_server.py (#1322)
解决报
```python
return await cast(
File "funasr_wss_server.py", line 188, in ws_serve
int(websocket.status_dict_asr_online["chunk_size"][1]) * 60 / websocket.chunk_interval)
ValueError: invalid literal for int() with base 10: ','
^CTraceback (most recent call last):
File "funasr_wss_server.py", line 302, in <module>
asyncio.get_event_loop().run_forever()
```
This commit is contained in:
parent
3f487c4290
commit
6cdbcf4b0a
@ -179,7 +179,8 @@ async def ws_serve(websocket, path):
|
||||
if "wav_name" in messagejson:
|
||||
websocket.wav_name = messagejson.get("wav_name")
|
||||
if "chunk_size" in messagejson:
|
||||
websocket.status_dict_asr_online["chunk_size"] = messagejson["chunk_size"]
|
||||
chunk_size = messagejson["chunk_size"].split(',')
|
||||
websocket.status_dict_asr_online["chunk_size"] = [int(x) for x in chunk_size]
|
||||
if "encoder_chunk_look_back" in messagejson:
|
||||
websocket.status_dict_asr_online["encoder_chunk_look_back"] = messagejson["encoder_chunk_look_back"]
|
||||
if "decoder_chunk_look_back" in messagejson:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user