diff options
| author | schneefux <schneefux+commit@schneefux.xyz> | 2014-10-07 19:32:42 +0200 |
|---|---|---|
| committer | schneefux <schneefux+commit@schneefux.xyz> | 2014-10-07 19:32:42 +0200 |
| commit | 7e6e87cf45831e53fd0b1bcc73315068738402f6 (patch) | |
| tree | 6c6a5e30b7254dd82a25d2d8a0f3f4c6c7cc7fe5 /client/stt.py | |
| parent | 016cc20ad8605371e820e509f9881c2750019d09 (diff) | |
| parent | 68704f36d7c05e06ffdf65e2593aa296ffd3a64d (diff) | |
| download | jasper-client-7e6e87cf45831e53fd0b1bcc73315068738402f6.tar.gz jasper-client-7e6e87cf45831e53fd0b1bcc73315068738402f6.zip | |
Merge pull request #210 from Holzhaus/diagnose-improvements
Diagnose improvements
Diffstat (limited to 'client/stt.py')
| -rw-r--r-- | client/stt.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/client/stt.py b/client/stt.py index cfaced6..485f5d9 100644 --- a/client/stt.py +++ b/client/stt.py @@ -5,12 +5,12 @@ import traceback import wave import json import tempfile -import pkgutil import logging from abc import ABCMeta, abstractmethod import requests import yaml import jasperpath +import diagnose """ The default Speech-to-Text implementation which relies on PocketSphinx. @@ -171,7 +171,7 @@ class PocketSphinxSTT(AbstractSTTEngine): @classmethod def is_available(cls): - return (pkgutil.get_loader('pocketsphinx') is not None) + return diagnose.check_python_import('pocketsphinx') """ Speech-To-Text implementation which relies on the Google Speech API. @@ -274,7 +274,7 @@ class GoogleSTT(AbstractSTTEngine): @classmethod def is_available(cls): - return True + return diagnose.check_network_connection() """ Returns a Speech-To-Text engine. |
