PocketSphinx
5.0.0
A small speech recognizer
|
Go to the documentation of this file.
62 #ifndef __POCKETSPHINX_H__
63 #define __POCKETSPHINX_H__
69 #include <pocketsphinx/sphinx_config.h>
79 #include <pocketsphinx/export.h>
98 ARG_REQUIRED = (1<<0),
100 ARG_FLOATING = (1<<2),
102 ARG_BOOLEAN = (1<<4),
103 REQARG_INTEGER = (ARG_INTEGER | ARG_REQUIRED),
104 REQARG_FLOATING = (ARG_FLOATING | ARG_REQUIRED),
105 REQARG_STRING = (ARG_STRING | ARG_REQUIRED),
106 REQARG_BOOLEAN = (ARG_BOOLEAN | ARG_REQUIRED)
117 typedef struct ps_arg_s {
682 char const *fdictfile,
char const *format);
1080 double *out_ncpu,
double *out_nwall);
1093 double *out_ncpu,
double *out_nwall);
POCKETSPHINX_EXPORT int ps_decode_senscr(ps_decoder_t *ps, FILE *senfh)
POCKETSPHINX_EXPORT int ps_reinit_feat(ps_decoder_t *ps, ps_config_t *config)
POCKETSPHINX_EXPORT void ps_get_utt_time(ps_decoder_t *ps, double *out_nspeech, double *out_ncpu, double *out_nwall)
const POCKETSPHINX_EXPORT anytype_t * ps_config_set_bool(ps_config_t *config, const char *name, int val)
POCKETSPHINX_EXPORT void ps_expand_model_config(ps_config_t *config)
POCKETSPHINX_EXPORT int ps_process_raw(ps_decoder_t *ps, int16 const *data, size_t n_samples, int no_search, int full_utt)
const POCKETSPHINX_EXPORT anytype_t * ps_config_set_float(ps_config_t *config, const char *name, double val)
POCKETSPHINX_EXPORT ps_config_t * ps_config_init(const ps_arg_t *defn)
POCKETSPHINX_EXPORT ps_config_t * ps_config_retain(ps_config_t *config)
POCKETSPHINX_EXPORT const char * ps_get_hyp(ps_decoder_t *ps, int32 *out_best_score)
Definition of a configuration parameter.
const POCKETSPHINX_EXPORT anytype_t * ps_config_get(ps_config_t *config, const char *name)
Basic type definitions used in Sphinx.
Public API for language models.
const POCKETSPHINX_EXPORT char * ps_config_serialize_json(ps_config_t *config)
POCKETSPHINX_EXPORT char * ps_lookup_word(ps_decoder_t *ps, const char *word)
POCKETSPHINX_EXPORT int ps_process_cep(ps_decoder_t *ps, float32 **data, int n_frames, int no_search, int full_utt)
POCKETSPHINX_EXPORT int ps_config_soundfile(ps_config_t *config, FILE *fh, const char *file)
POCKETSPHINX_EXPORT int ps_get_n_frames(ps_decoder_t *ps)
enum ps_type_e ps_type_t
Types of configuration parameters.
POCKETSPHINX_EXPORT double ps_config_float(ps_config_t *config, const char *name)
POCKETSPHINX_EXPORT ps_decoder_t * ps_retain(ps_decoder_t *ps)
Multi-level alignment structure.
POCKETSPHINX_EXPORT int ps_config_free(ps_config_t *config)
POCKETSPHINX_EXPORT int ps_set_cmn(ps_decoder_t *ps, const char *cmn)
POCKETSPHINX_EXPORT ps_seg_t * ps_seg_next(ps_seg_t *seg)
POCKETSPHINX_EXPORT void ps_get_all_time(ps_decoder_t *ps, double *out_nspeech, double *out_ncpu, double *out_nwall)
Fast integer logarithmic addition operations.
POCKETSPHINX_EXPORT const char * ps_seg_word(ps_seg_t *seg)
const POCKETSPHINX_EXPORT anytype_t * ps_config_set_str(ps_config_t *config, const char *name, const char *val)
ps_type_e
Types of configuration parameters.
Definition: pocketsphinx.h:97
POCKETSPHINX_EXPORT int ps_free(ps_decoder_t *ps)
POCKETSPHINX_EXPORT int ps_config_wavfile(ps_config_t *config, FILE *infh, const char *file)
POCKETSPHINX_EXPORT ps_nbest_t * ps_nbest(ps_decoder_t *ps)
Simple voice activity detection.
POCKETSPHINX_EXPORT int ps_add_word(ps_decoder_t *ps, char const *word, char const *phones, int update)
POCKETSPHINX_EXPORT int32 ps_seg_prob(ps_seg_t *seg, int32 *out_ascr, int32 *out_lscr, int32 *out_lback)
int ps_config_validate(ps_config_t *config)
VAD-based endpointer for PocketSphinx.
POCKETSPHINX_EXPORT int ps_config_nistfile(ps_config_t *config, FILE *infh, const char *file)
POCKETSPHINX_EXPORT void ps_seg_free(ps_seg_t *seg)
POCKETSPHINX_EXPORT int ps_reinit(ps_decoder_t *ps, ps_config_t *config)
Segmentation iterator object.
Model-space linear transforms for speaker adaptation.
POCKETSPHINX_EXPORT logmath_t * ps_get_logmath(ps_decoder_t *ps)
POCKETSPHINX_EXPORT void ps_seg_frames(ps_seg_t *seg, int *out_sf, int *out_ef)
POCKETSPHINX_EXPORT ps_type_t ps_config_typeof(ps_config_t *config, char const *name)
const POCKETSPHINX_EXPORT anytype_t * ps_config_set(ps_config_t *config, const char *name, const anytype_t *val, ps_type_t t)
POCKETSPHINX_EXPORT long ps_config_int(ps_config_t *config, const char *name)
Implementation of logging routines.
Word graph structure used in bestpath/nbest search.
POCKETSPHINX_EXPORT const char * ps_nbest_hyp(ps_nbest_t *nbest, int32 *out_score)
POCKETSPHINX_EXPORT int ps_save_dict(ps_decoder_t *ps, char const *dictfile, char const *format)
POCKETSPHINX_EXPORT int ps_start_stream(ps_decoder_t *ps)
const POCKETSPHINX_EXPORT anytype_t * ps_config_set_int(ps_config_t *config, const char *name, long val)
POCKETSPHINX_EXPORT void ps_nbest_free(ps_nbest_t *nbest)
POCKETSPHINX_EXPORT int32 ps_get_prob(ps_decoder_t *ps)
Integer log math computation class.
POCKETSPHINX_EXPORT const ps_arg_t * ps_args(void)
POCKETSPHINX_EXPORT ps_mllr_t * ps_update_mllr(ps_decoder_t *ps, ps_mllr_t *mllr)
POCKETSPHINX_EXPORT ps_config_t * ps_get_config(ps_decoder_t *ps)
POCKETSPHINX_EXPORT long ps_decode_raw(ps_decoder_t *ps, FILE *rawfh, long maxsamps)
const POCKETSPHINX_EXPORT char * ps_config_str(ps_config_t *config, const char *name)
POCKETSPHINX_EXPORT ps_lattice_t * ps_get_lattice(ps_decoder_t *ps)
N-best hypothesis iterator object.
POCKETSPHINX_EXPORT ps_seg_t * ps_nbest_seg(ps_nbest_t *nbest)
POCKETSPHINX_EXPORT int ps_config_bool(ps_config_t *config, const char *name)
POCKETSPHINX_EXPORT ps_config_t * ps_config_parse_json(ps_config_t *config, const char *json)
POCKETSPHINX_EXPORT int ps_start_utt(ps_decoder_t *ps)
POCKETSPHINX_EXPORT ps_decoder_t * ps_init(ps_config_t *config)
POCKETSPHINX_EXPORT ps_seg_t * ps_seg_iter(ps_decoder_t *ps)
const POCKETSPHINX_EXPORT char * ps_default_modeldir(void)
Speech recognizer object.
POCKETSPHINX_EXPORT int ps_end_utt(ps_decoder_t *ps)
POCKETSPHINX_EXPORT void ps_default_search_args(ps_config_t *config)
POCKETSPHINX_EXPORT int ps_get_in_speech(ps_decoder_t *ps)
const POCKETSPHINX_EXPORT char * ps_get_cmn(ps_decoder_t *ps, int update)
POCKETSPHINX_EXPORT int ps_load_dict(ps_decoder_t *ps, char const *dictfile, char const *fdictfile, char const *format)
POCKETSPHINX_EXPORT ps_nbest_t * ps_nbest_next(ps_nbest_t *nbest)