alumae / kaldi-gstreamer-server

Real-time full-duplex speech recognition server, based on the Kaldi toolkit and the GStreamer framwork.
BSD 2-Clause "Simplified" License
1.07k stars 341 forks source link

AttributeError: 'DecoderPipeline' object has no attribute 'get_adaptation_state' #9

Closed lifefeel closed 9 years ago

lifefeel commented 9 years ago

When I ran client.py, the result is no problem.

the result is:

THE.
ONE TWO THREE FOUR FIVE SIX SEVEN EIGHT.

But, after printing result, client.py not finished. I found that worker has a error.

the error is:

Traceback (most recent call last):
  File "/home/auc/kaldi-trunk/kaldi-gstreamer-server/kaldigstserver/decoder.py", line 140, in _on_eos
    self.eos_handler[0](self.eos_handler[1])
  File "kaldigstserver/worker.py", line 194, in _on_eos
    self.send_adaptation_state()
  File "kaldigstserver/worker.py", line 209, in send_adaptation_state
    adaptation_state = self.decoder_pipeline.get_adaptation_state()
AttributeError: 'DecoderPipeline' object has no attribute 'get_adaptation_state'

could you solve this problem?

thanks.

alumae commented 9 years ago

Fixed. Adaptation state is only supported by the newer nnet-based decoder ("decoder2"). Fixed so that the adaptation state is not queried if the underlying decoder doesn't support it.