k2-fsa / sherpa

Speech-to-text server framework with next-gen Kaldi
https://k2-fsa.github.io/sherpa
Apache License 2.0
477 stars 97 forks source link

Streaming server printing empty lines #478

Open shaynemei opened 9 months ago

shaynemei commented 9 months ago

When using the endpointer, the streaming server would print empty lines like this:

snap 2023-09-26 at 11 35 06 AM

There seems to be one empty line per segment (whenever endpointer is triggered)

Where can disable this behaviour?

csukuangfj commented 9 months ago

Have you changed any code? Can you reproduce it with the latest master?

shaynemei commented 9 months ago

This is from the latest master

csukuangfj commented 9 months ago

Sorry, I cannot reproduce your issue with the latest master after commenting out the following line:

https://github.com/k2-fsa/sherpa/blob/115b8568bf90dfb866d8aa4a682e37862201e609/sherpa/bin/streaming_server.py#L695

Screenshot 2023-09-30 at 22 27 10
csukuangfj commented 9 months ago

This is from the latest master

By the way, your log shows you are actually not using the latest master.

For instance, https://github.com/k2-fsa/sherpa/blob/115b8568bf90dfb866d8aa4a682e37862201e609/sherpa/bin/streaming_server.py#L665-L668

The connected log should be at line 665. But your log shows line 683, which indicates you are actually using a modified version.

csukuangfj commented 9 months ago

Please re-test it with the latest master and see if you still have this issue.