georgepar / kaldi-grpc-server

Deploy Kaldi models using grpc for bidirectional streaming.
Apache License 2.0
17 stars 6 forks source link

problems when using kaldi-grpc package #14

Open tamarlasker opened 2 years ago

tamarlasker commented 2 years ago

Hi

First of all, Thanks for your great job.

I'm trying to use your library but getting an error I'm not sure if the reason is the way I'm sending the information or if something else is wrong the data is a .wav file that I read into my code.

for example the begging of the data looks like: "RIFF\xa4\xba\x15\x00WAVEfmt \x10\x00\x00\x00\x01\x00\x01\x00@\x1f\x00\x00\x80>"

I'm getting this error:

<_MultiThreadedRendezvous of RPC that terminated with: status = StatusCode.UNAVAILABLE details = "failed to connect to all addresses" debug_error_string = "{"created":"@1653553707.429000000","description":"Failed to pick subchannel","file":"src/core/ext/filters/client_channel/client_channel.cc","file_line":3218,"referenced_errors":[{"created":"@1653553707.429000000","description":"failed to connect to all addresses","file":"src/core/lib/transport/error_utils.cc","file_line":165,"grpc_status":14}]}"

Do you know what can cause this error?

georgepar commented 2 years ago

Hi, I could try to help you out a bit, but I would need more info.

For example

  1. I assume you have deployed a DNN-HMM model. Does the wav match what the model accepts (e.g. 16KHz, mono etc)?
  2. Are you using stream or batch request? For wavs > 1-2 min it is recommended to use the streaming API
  3. What client are you using? I would suggest you start with the command line client to eliminate most factors, and then move to the python client.
    • pip install kaldigrpc-client
    • kaldigrpc-transcribe --streaming --streaming-output --host 127.0.0.1 --port 50051 my.wav
georgepar commented 2 years ago

Though the error you posted indicates that the client fails to connect to the server.