libsent/include/sent/stddefs.h File Reference

Basic common definitions. More...

#include <sent/config.h>
#include <stdio.h>
#include <stdlib.h>
#include <strings.h>
#include <string.h>
#include <math.h>
#include <unistd.h>
#include <sys/time.h>
#include <errno.h>
#include <fcntl.h>
#include <sys/types.h>
#include <sent/machines.h>
#include <sent/util.h>

Go to the source code of this file.

Defines

#define PI   3.14159265358979
 Static PI value.
#define TPI   6.28318530717959
 Static 2*PI value.
#define LOGTPI   1.83787706640935
 Static log_e(TPI).
#define LOG_TEN   2.30258509
 Static log_e(10).
#define INV_LOG_TEN   .434294482
 Static 1 / LOG_TEN.
#define TRUE   1
#define FALSE   0
#define R_OK   4
#define W_OK   2
#define X_OK   1
#define F_OK   0
#define max(A, B)   ((A)>=(B)?(A):(B))
#define min(A, B)   ((A)<(B)?(A):(B))
#define abs(X)   ((X)>0?(X):-(X))
#define strmatch   !strcmp
 String match function, 0 if the given strings did not match.
#define strnmatch   !strncmp
 String match function with length limit, 0 if the given strings did not match.
#define DELM   " \t\n"
 Common text delimiter.
#define LOG_ZERO   -1000000
 definition of log(0) used to represent 'no value' in likelihood computation
#define LOG_ADDMIN   -13.815510558
 -log_e(-LOG_ZERO)
#define MAX_WORD_NUM   65535
 Maximum size of vocabulary.
#define WORD_INVALID   65535
 Out of word ID to represent no-existence of word.
#define MAXLINELEN   1024
 Assumed maximum number of bytes per input line.
#define MAXPATHLEN   1024
 Limit of maximum length of a file path.

Typedefs

typedef unsigned char boolean
 Boolean type.
typedef float PROB
 Typedefs to handle speech inputs, parameters and words.
typedef float LOGPROB
 Log probability.
typedef short SP16
 16bit speech data
typedef float VECT
 Vector element.
typedef unsigned short WORD_ID
 Typedef for word ID.

Enumerations

enum  LogOutputLevel { LOG_NORMAL, LOG_VERBOSE, LOG_DEBUG }
 To specify log output level. More...
enum  { DIR_LR, DIR_RL }
 To specify the direction of N-gram when reading ARPA file. More...


Detailed Description

Basic common definitions.

This is a common header that should be included in all the Julius related sources. This file contains include list of basic C headers, definition of common static values and function macro, and basic typedefs to handle speech input and words.

The unix function macro definition for Win32 environment is also included.

Only the important part is documented. Fof all the definition, see the source.

See also:
machines.h
Author:
Akinobu LEE
Date:
Sat Feb 12 11:49:37 2005
Revision
1.1.1.1

Definition in file stddefs.h.


Define Documentation

#define LOG_ADDMIN   -13.815510558

-log_e(-LOG_ZERO)

See also:
libsent/src/phmm/output.c

Definition at line 165 of file stddefs.h.

Referenced by addlog(), and addlog_array().


Typedef Documentation

typedef float PROB

Typedefs to handle speech inputs, parameters and words.

Probability

Definition at line 183 of file stddefs.h.


Enumeration Type Documentation

enum LogOutputLevel

To specify log output level.

Enumerator:
LOG_NORMAL  Normal level.
LOG_VERBOSE  Verbose level.
LOG_DEBUG  Debug level.

Definition at line 168 of file stddefs.h.

anonymous enum

To specify the direction of N-gram when reading ARPA file.

Enumerator:
DIR_LR  left-to-right (for 2-gram)
DIR_RL  right-to-left (for reverse 3-gram)

Definition at line 175 of file stddefs.h.


Generated on Tue Dec 18 16:01:37 2007 for Julius by  doxygen 1.5.4