Abstract:
This invention presents a voicing determination algorithm for classification of a speech signal segment as voiced or unvoiced. The algorithm is based on a normalized autocorrelation where the length of the window is proportional to the pitch period. The speech segment to be classified is further divided into a number of sub-segments, and the normalized autocorrelation is calculated for each sub-segment. If a certain number of the normalized autocorrelation values is above a predetermined threshold, the speech segment is classified as voiced. To improve the performance of the voicing determination algorithm in unvoiced to voiced transients, the normalized autocorrelations of the last sub-segments are emphasized. The performance of the voicing decision algorithm can be enhanced by utilizing also the possible lookahead information.

Description:
BACKGROUND OF THE INVENTION  
         [0001]    The present invention relates to speech processing, and more particularly to a voicing determination of the speech signal having a particular, but not exclusive, application to the field of mobile telephones.  
           [0002]    In known speech codecs the most common phonetic classification is a voicing decision, which classifies a speech frame as voiced or unvoiced. Generally speaking, voiced segments are typically associated with high local energy and exhibit a distinct periodicity corresponding to the fundamental frequency, or equivalently pitch, of the speech signal, whereas unvoiced segments resemble noise. However, speech signal also contains segments, which can be classified as a mixture of voiced and unvoiced speech where both components are present simultaneously. This category includes voiced fricatives and breathy and creaky voices. The appropriate classification of mixed segments as either voiced or unvoiced depends on the properties of the speech codec.  
           [0003]    In a typical known analysis-by-synthesis (A-b-S) based speech codec the periodicity of speech is modelled with a pitch predictor filter, also referred to as a long-term prediction (LTP) filter. It characterises the harmonic structure of the spectrum based on the similarity of adjacent pitch periods in a speech signal. The most common method used for pitch extraction is the autocorrelation analysis, which indicates the similarity between the present and delayed speech segments. In this approach the lag value corresponding to the major peak of the autocorrelation function is interpreted as the pitch period. It is typical that for voiced speech segments with a clear pitch period the voicing determination is closely related to pitch extraction.  
           [0004]    According to a first aspect of the present invention there is provided a method for determining the voicing of a speech signal segment, comprising the steps of: dividing a speech signal segment into sub-segments, determining a value relating to the voicing of respective speech signal sub-segments, comparing said values with a predetermined threshold, and making a decision on the voicing of the speech segment based on the number of the values on one side of the threshold.  
           [0005]    According to a second aspect of the present invention there is provided a device for determining the voicing of a speech signal segment, comprising means ( 106 ) for dividing a speech signal segment into sub-segments, means ( 110 ) for determining a value relating to the voicing of respective speech signal sub-segments, means ( 112 ) for comparing said values with a predetermined threshold and means ( 112 ) for making a decision on the voicing of the speech segment based on the number of the values on one side of the threshold.  
         SUMMARY OF THE INVENTION  
         [0006]    The invention provides a method for voicing determination to be used particularly, but not exclusively, in a narrow-band speech coding system. An aim of the invention is to address the problems of prior art by determining the voicing of the speech segment based on the periodicity of its sub-segments. The embodiments of the present invention give an improvement in the operation in a situation where the properties of the speech signal vary rapidly such that the single parameter set computed over a long window does not provide a reliable basis for voicing determination.  
           [0007]    A preferred embodiment of the voicing determination of the present invention divides a segment of speech signal further into sub-segments. Typically the speech signal segment comprises one speech frame. Furthermore, it may optionally include a possible lookahead which is a certain portion of the speech signal from the next speech frame. A normalised autocorrelation is computed for each sub-segment. The normalised autocorrelation values of these sub-segments are forwarded to classification logic, which compares them to the predefined threshold value. In this embodiment, if a certain percentage of normalised autocorrelation values exceeds a threshold, the segment is classified as voiced.  
           [0008]    In one embodiment of the present invention, a normalised autocorrelation is computed for each sub-segment using a window whose length is proportional to the estimated pitch period. This ensures that a suitable number of pitch periods is included to the window.  
           [0009]    In addition to the above, a critical design problem in voicing determination algorithms is the correct classification of transient frames. This is especially true in transients from unvoiced to voiced speech as the energy of the speech signal is usually growing. If no separate algorithm is designed for classifying the transient frames, the voicing determination algorithm is always a compromise between the misclassification rate and the sensitivity to detecting transient frames appropriately.  
           [0010]    To improve the performance of the voicing determination algorithm during transient frames without increasing the misclassification rate practically at all, one embodiment of the present invention provides rules for classifying the speech frame as voiced. This is done by emphasising the voicing decisions of the last sub-segments in a frame to detect the transients from unvoiced to voiced speech. That is, in addition to having a certain number of sub-segments having a normalised autocorrelation value exceeding a threshold value, the frame is classified as voiced also if all of a predetermined number of the last sub-segments have a normalised autocorrelation value exceeding the same threshold value. Detection of unvoiced to voiced transients is thus further improved by emphasising the last sub-segments in the classification logic.  
           [0011]    The frame may be classified as voiced if only the last sub-segment has a normalised autocorrelation value exceeding the threshold value.  
           [0012]    Alternatively, the frame may be classified as voiced if a portion of the sub-segments out of the whole speech frame have a normalised autocorrelation value exceeding the threshold. The portion may, for example be substantially a half, or substantially a third of the sub-segments of the speech frame.  
           [0013]    The voiced/unvoiced decision can be used for two purposes. One option is to allocate bits within the speech codec differently for voiced and unvoiced frames. In general, voiced speech segments are perceptually more important than unvoiced segments and thus it is especially important that a speech frame is correctly classified as voiced. In the case of A-b-S type of codec, this can be done e.g. by re-allocating bits from the adaptive codebook (e.g. from LTP-gain and LTP-lag parameters) to the excitation signal when the speech frame is classified as unvoiced to improve the coding of the excitation signal. On the other hand the adaptive codebook in a speech codec can then be even switched off during the unvoiced speech frame which will lead to reduced total bit rate. Because of this on/off switching of LTP-parameters it is especially important that a speech frame is correctly classified as voiced. It has been noticed that, if a voiced speech frame is incorrectly classified as unvoiced and the LTP parameters are switched off, this leads to a decreased sound quality at the receiving end. Accordingly, the present invention provides a method and device for a voiced/unvoiced decision to make a reliable decision, especially, so that voiced speech frames are not incorrectly decided as unvoiced.  
       
    
    
     BRIEF DESCRIPTION OF THE DRAWINGS  
       [0014]    Exemplary embodiments of the invention are hereinafter described with the reference to the accompanying drawings, in which:  
         [0015]    [0015]FIG. 1 shows a block diagram of an apparatus of the present invention;  
         [0016]    [0016]FIG. 2 shows a speech signal framing of the present invention;  
         [0017]    [0017]FIG. 3 shows a flow diagram in accordance with the present invention;  
         [0018]    [0018]FIG. 4 shows a block diagram of a radiotelephone utilising the invention. 
     
    
     DETAILED DESCRIPTION OF THE INVENTION  
       [0019]    [0019]FIG. 1 shows a device  1  for voicing determination according to the first embodiment of the present invention. The device comprises a microphone  101  for receiving an acoustical signal  102 , typically a voice signal, generated by a user, and converting it into an analog electrical signal at line  103 . An A/D converter  104  receives the analog electrical signal at line  103  and produces a digital electrical signal y(t) of the user&#39;s voice at line  105 . A segmentation block  106  then divides speech signal to predefined sub-segments at line  107 . A frame of 20 ms (160 samples) can for example divided into 4 sub-segments of 5 ms. After segmentation a pitch extraction block  108  extracts the optimum open-loop pitch period for each speech sub-segment. The optimum open-loop pitch is estimated by minimising the sum-squared error between the speech segment and its delayed and gain-scaled version as following:  
               J        (     t   ,   τ   ,     g        (   t   )         )       =       ∑     i   =   0       N   -   1              (       y        (     t   +   i     )       -       g        (   t   )            y        (     t   +   i   -   τ     )           )     2               (   1   )                               
 
         [0020]    where y(t) is the first speech sample belonging to the window of length N, τ is the integer pitch period and g(t) is the gain.  
         [0021]    The optimum value of g(t) is found by setting the partial derivative of the cost function (1) with respect to the gain equal to zero. This yields  
                 g        (   t   )       =       R        (     t   ,   τ     )         R        (     t   -   τ     )                
        where           (   2   )                 R        (     t   ,   τ     )       =       ∑     i   =   0       N   -   1              y        (     t   +   i     )              y        (     t   +   i   -   τ     )                             (   3   )                               
 
         [0022]    is the autocorrelation of y(t) with delay τ and,  
               R        (   t   )       =       R        (     t   ,   0     )       =       ∑     i   =   0       N   -   1              y   2          (     t   +   i     )                   (   4   )                               
 
         [0023]    By substituting the optimum gain to equation (1), the pitch period is estimated by maximising the latter term of  
               J        (     t   ,   τ     )       =       R        (   t   )       -         R   2          (     t   ,   τ     )         R        (     t   -   τ     )                   (   5   )                               
 
         [0024]    with respect to delay τ. The pitch extraction block  108  is also arranged to send the above determined estimated open-loop pitch estimate τ at line  113  to the segmentation block  106  and to a value determination block  110 . An example of the operation of the segmentation is shown in FIG. 2, which is described later.  
         [0025]    The value determination block  110  also receives the speech signal y(t) from the segmentation block  106  at line  107 . The value determination block  110  is arranged to operate as following:  
         [0026]    To eliminate the effects of the negative values of the autocorrelation function when maximising the function, a square root of the latter term of equation (5) is taken. The term to be maximised is thus:  
           C   0 ( t, τ)= R ( t, τ)/{square root}{square root over ( R ( t− τ))}  (6)  
         [0027]    During voiced segments the gain g(t) tends to be near unity and thus it is often used for voicing determination. However, during unvoiced and transient regions the gain g(t) fluctuates achieving also values near unity. A more robust voicing determination is achieved by observing the values of equation (6). To cope with the power variations of the signal, R(t,) is normalised to have a maximum value of unity resulting:  
                 C   1          (     t   ,   τ     )       =       R        (     t   ,   τ     )             R        (   t   )                R        (     t   -   τ     )                     (   7   )                               
 
         [0028]    According to one aspect of the invention the window length in (7) is set to the found pitch period τ plus some offset M to overcome the problems related to a fixed-length window. The periodicity measure used is thus  
                   C   2          (     t   ,   τ     )       =         R   w          (     t   ,   τ     )               R   w          (   t   )                  R   w          (     t   -   τ     )                    
        where           (   8   )                     R   w          (     t   ,   τ     )       =       ∑     i   =   0       τ   +   M   -   1              y        (     t   +   i     )            y        (     t   +   i   -   τ     )                  
        and           (   9   )                   R   w          (   t   )       =         R   w          (     t   ,   0     )       =       ∑     i   =   0       τ   +   M   -   1              y   2          (     t   +   i     )                   (   10   )                               
 
         [0029]    The parameter M can be set, e.g. to 10 samples. A voicing decision block  112  is to receive the above determined periodicity measure C 2 (t, τ) at line  111  from the value determination block  110  and parameters K, K tr , C tr  to make the voicing decision. The decision logic of voiced/unvoiced decision is further described in FIG. 3 below.  
         [0030]    It should be emphasised that the pitch period used in (8) can also be estimated in other ways than described in equations (1)-(6) above. A common modification is to use pitch tracking in order to avoid pitch multiples described in a Finnish patent application FI 971976. Another optional function for the open-loop pitch extraction is that the effect of the formant frequencies is removed from the speech signal before pitch extraction. This can be done for example by a weighting filter.  
         [0031]    Modified signals e.g. residual signal, weighted residual signal or weighted speech signal, can also be used for voicing determination instead of the original speech signal. Residual signal is obtained by filtering the original speech signal by linear prediction analysis filter.  
         [0032]    It may also be advantageous to estimate the pitch period from the residual signal of the linear prediction filter instead of the speech signal, because the residual signal is often more clearly periodic.  
         [0033]    Residual can be further low-pass filtered and down-sampled before the above procedure. Down-sampling reduces the complexity of correlation computation. In one further example the speech signal is first filtered by a weighting filter before the calculation of autocorrelation is applied as described above.  
         [0034]    [0034]FIG. 2 shows an example of dividing a speech frame into four sub-segments whose starting positions are t1, t2, t3 and t4. The window lengths N1, N2, N3 and N4 are proportional to the pitch period found as described above. The lookahead is also utilised in the segmentation. In this example, the number of sub-segments is fixed. Alternatively the number of sub-segments can variable based on the pitch period. This can be done for example by selecting the subsegments by t2=t1+τ+L, t3=t2+τ+L, etc. until all available data is utilised. In this example L is constant and can be set e.g. −10 resulting overlapping sub-segments.  
         [0035]    [0035]FIG. 3 shows a flow diagram of the method according to one embodiment of the present invention. The procedure is started by step  301  where the open-loop pitch period τ is extracted as exemplified above in equations (1)-(6). At step  302  C 2 (t, τ) is calculated for each sub-segment of the speech as described in equation (8). Next at step  303  the number of sub-segments n is calculated where C 2 (t, τ) is above a certain first threshold value C tr . The comparator  304  determines whether the number of sub-segments n, determined at step  303 , exceeds a certain second threshold value K. If the second threshold value K is exceeded the speech frame is classified as voiced. Otherwise the procedure continues to step  305 . In this embodiment, at step  305  the comparator determines if a certain number K tr  of last sub-segments have a value C 2 (t, τ) exceeding the threshold C tr . If the threshold is exceeded the speech frame is classified as a voiced frame. Otherwise the speech frame is classified as unvoiced frame.  
         [0036]    The exact parameter values C tr , K tr  and K presented above are not limited to certain values but are dependent on the system specified and can be selected empirically using a large speech database. For example, if the speech segment is divided into 9 sub-segments suitable values can be e.g. C tr =0.6, K tr =4 and K=6. An appropriate value of K and K tr  is proportional to the number of sub-segments.  
         [0037]    Alternatively, according to present invention, the frame is classified as voiced if only the last sub-segment (i.e. K tr =1) has a normalised autocorrelation value exceeding the threshold value. According to still one modification the frame is classified as voiced if substantially half of the sub-segments out of the whole speech frame (e.g. 4 or 5 sub-segments out of 9) have a normalised autocorrelation value exceeding the threshold.  
         [0038]    [0038]FIG. 4 is a block figure of a radiotelephone describing the relevant parts for the present invention. The radiotelephone comprises of a microphone  61 , keypad  62 , display  63 , speaker  64  and antenna  71  with switch for duplex operation. Further included is a control unit  65 , implemented for example in an ASIC circuit, for controlling the operation of the radiotelephone. FIG. 3 also shows the transmission and reception blocks  67 ,  68  including speech encoder and decoder blocks  69 ,  70 . The device for voicing determination  1  is preferably included within the speech encoder  69 . Alternatively the voicing determination can be implemented separately, not within the speech encoder  69 . The speech encoder/decoder blocks  69 ,  70  and the voicing determination  1  can be implemented by a DSP circuit including the elements known as such, e.g. internal/external memories and registers, for implementing the present invention. The speech encoder/decoder can be based on any standard/technology and the present invention thus forms one part for the operation of such codec. The radiotelephone itself can operate in any existing or future telecommunication standard based on digital technology.  
         [0039]    In the view of foregoing description it will be evident to a person skilled in the art that various modifications may be made within the scope of the present invention.