Method of and device for encoding a speech parameter such as the pitch, as a function of time

Abstract: In a device for and a method of encoding a first signal (f₀), for example a speech parameter such as the pitch, as a function of time, to form a second signal, a third signal (k) is derived from the first signal, which third signal is a measure of the curvature of the first signal as a function of time. The extrema (such as k(t₁) in Fig. 1b) in this third signal are determined and the second signal is generated in the form of a sequence of information blocks, of which one information block contains time information corresponding to the instant at which an extremum occurs in the third signal. A special encoding method is described, which is substantially immune to noise in the first signal.

Description: The invention relates to a method for encoding an input speech signal parameter such as a time-dependent speech pitch, to form a second signal which comprises a sequence of information blocks, each block having an indication of a specific instant in time and an amplitude derived from said first signal with respect to that instant, said method comprising the steps of measuring a time-dependent curvature of the first signal, detecting a sequence of peaks in said curvature, and for each peak loading an information block with said amplitude, so that each block identifies one such peak. The invention also relates to a device for carrying out the method. It is known to encode a signal, for example a speech parameter such as the pitch in a speech signal, by determining the extrema in the signal, i.e. the relative and absolute minima and maxima in the signal. Subsequently, the signal is encoded into a sequence of information blocks, each information block indicating the instant at which an extremum occurs in the signal and the associated value of the extremum at this instant. The encoded signal, which is constituted by the sequence of information blocks, can subsequently be transmitted via a transmission medium at a substantially lower bit rate that if the original signal were transmitted via the transmission medium. This is because the encoding provides a significant data reduction, enabling the signal to be transmitted via a transmission medium having a limited bandwidth. After reception of the encoded signal the original signal can be reconstructed by interpolation. The simplest interpolation is that in which the signal at instants situated between the instants of two successive information blocks is obtained by means of a straight line interconnecting two points defined by the information in two successive information blocks. Another possibility is to reconstruct the original signal in that the information in the information blocks which relates to the magnitude of the first signal is approximated to by a higher-order curve. The reconstructed signal, for example the pitch as a function of time, can subequently be used to resynthesize a speech signal, for example by means of a speech chip. An example of such a chip is the Applicant's speech chip PCF 8200, as described in the Elcoma publication no. 217, entitled "Speech Synthesis: the complete approach with the PCF 8200". The known method has the disadvantage that encoding is not always accurate enough and sometimes fails completely, for example with respect to the pitch. From the publication "An efficient encoding method for electrocardiography using spline functions" by H. Imai et al., Systems and Computers in Japan, 1985, No. 3, May-June, pp. 85-94, a method is known which enables the signal to be encoded more accurately. In accordance with this method a third signal is derived from the first signal, which third signal is a measure of the curvature of the first signal as a function of time, extrema in said third signal are determined, and the first signal is encoded in the form of a sequence of information blocks, of which an information block contains time information corresponding to the instant at which an extremum occurs in the third signal. Determining the extrema in the curvature of the signal and encoding a signal on the basis thereof in this way yields a better approximation to the first signal. An example of this is the encoding of a first signal which decreases continuously between a (relative) maximum and a (relative) minimum in conformity with two lines having different slopes and joining one another in a break-point situated between the instants at which the (relative) maximum and the (relative) minimum occur. The first-mentioned encoding method would yield two information blocks corresponding to the instants at which the (relative) maximum and the (relative) minimum occur and, for example, the associated values for the maximum and minimum. After decoding this would yield a reconstructed signal which varies between the maximum and the minimum in accordance with a straight line. The reconstructed signal no longer exhibits the break-point. The secondly mentioned known encoding method allows for this break-point. The break-point yields a maximum or a minimum in the curve representing the curvature, so that also for this break-point an information block is generated. This information block indicates the instant at which the break-point occurs and, for example, the value of the original signal at this instant. When the information blocks are decoded this break-point again occurs in the reconstructed signal. Nevertheless, situations arise in which the improved method of Imai et al. also fails or is still too inaccurate. Therefore, it is an object of the invention to provide a method, and a device for carrying out the method, which encodes the signal even more accurately and which hardly ever fails. To this end the method in accordance with the invention is characterized in that said first signal is sampled at periodic instants, for each such instant a first straight line is determined as approximating a limited set of said amplitudes at preceding instants, and a second straight line is determined as approximating a limited set of said amplitudes at subsequent instants, and in that for every instant the angle of intersection between said first and second straight lines is determined as a measure for a curvature value pertaining to the instant in question. The invention is based on the recognition of the fact that owing to noise in the first signal the method of encoding the signal as proposed by Imai et al. does not function correctly. If in accordance with the invention every time two lines are determined, the influence of noise is reduced substantially, enabling a better coding to be achieved. In addition to the time information the common value of the two lines at the intersection may be included in every information block. Reconstruction is now possible on the basis of said common value(s). Reconstruction is then achieved by interpolation between the points of intersection. This method may be characterized further in that the two lines to be determined for every instant are derived from the samples situation within the time interval by means of a least-squares method. The device for carrying out the method as defined above, comprising an input terminal for receiving the first signal, for example a speech parameter such as the pitch, as a function of time, an encoding unit having an input coupled to the input terminal, and having an output, which encoding unit is constructed to encode the first signal to form a second signal comprising a sequence of successive information blocks, an information block containing time information corresponding to a specific instant, and containing amplitude information associated with said instant, which amplitude information has been derived from the first signal, and is constructed to supply the second signal at its output, which output is coupled to the output terminal of the device to supply the second signal, in which the encoding unit is adapted to derive from the first signal a third signal which is a measure of the curvature of the first signal as a function of time, to determine extrema in said third signal, and to generate a sequence of information blocks, of which an information block contains time information corresponding to an instant at which an extremum occurs in the third signal, is characterized in that for deriving the third signal the encoding unit is adapted to determine, for each of a number of instants at which a sample of the first signal is available, two lines intersecting one another at said instant and extending through a plurality of samples of the first signal at instants within a time interval within which said instant is situated, and to determine the angle between said two lines. In the latter case the device may be characterized further in that the encoding unit is adapted to derive the lines from those samples of the first signal which are situated within said time interval by means of a least-squares method. The amplitude information in an information block may correspond to the magnitude of the first signal at said instant. However, there are other possibilities of determining the amplitude information of an information block. Another possibility is, for example, that the amplitude information is an information block corresponds to the value at the intersection of the two lines which intersect one another at said instant. Embodiments of the invention will now be described in more detail, by way of example, with reference to the accompanying drawings. In the drawings Fig. 1, in Fig. 1a, shows a first signal, for example the pitch f 0 , as a function of time and, in Fig. 1b, the curvature in the signal of Fig. 1a as a function of time, Fig. 2 shows the encoded signal comprising the sequence of information blocks, Fig. 3 shows the reconstructed signal after decoding, Fig. 4 shows a device for encoding the signal, Fig. 5, in Fig. 5a, diagrammatically illustrates how the instantaneous curvature is determined and, in Fig. 5b, the weighting function used for this purpose, Fig. 6 shows the encoded signal with different amplitude information in the information blocks, and Fig. 7 shows the device for supplying the encoded signal in Fig. 6. Fig. 1 in Fig. 1a diagrammatically shows a first signal, in the present example the pitch f 0 in a speech signal, as a function of time. The signal is represented as a continuous curve. In general the signal is available in the form of samples at equidistant descrete instants ... t i - 1 , t i , t i + 1 ... etc. (for example 20 ms each). Fig. 1b shows diagrammatically the third signal representing the curvature k of the first signal f 0 of Fig. 1a as a function of time. If the signal f 0 takes the form of samples at equidistant instants, the curvature will also be determined for said equidistant instants ... t i - 1 , t i , t i + 1 ... etc. Fig. 1b does not show the actual curvature but a kind of absolute value of the curvature. This means that in the curve of Fig. 1b only the (relative) maxima have to be considered. If the actual curvature had been plotted, in which case for example a convex curvature would yield a positive value and a concave curvature a negative value, both the (relative) maxima and the (relative) minima in the curve would have to be allowed for in order to determine the extrema. From Fig. 1b it is apparent that in the curve k extrema appear for the instants t 1 , t 2 , ..., t 8 . These extrema correspond to points of maximum curvature in the curve f 0 of Fig. 1a. The signal f 0 in Fig. 1a is now encoded by generating a sequence of information blocks, see Fig. 2, in which an information block (such as the block B 1 in Fig. 2) indicates the instant (t 1 ) at which an extremum occurs in the curve k and the value of the pitch at this instant (f 0 (t 1 )). In order to obtain a reconstructed signal f 0R for the pitch the sequence of information blocks is decoded as is indicated by means of the solid line in Fig. 3. By drawing straight lines between the successive points P 1 to P 8 , which correspond to the information in the eight information blocks B 1 to B 8 in Fig. 2, the pitch for the instants ... t i - 1 , t i , t i + 1 ... etc. situated between the instants t 1 to t 8 is obtained, in fact, by interpolation. The broken lines between the instants t 1 and t 3 and between t 3 and t 5 respectively indicate how the reconstructed signal would have been if only the extrema in the signal had been used for encoding the signal. It is obvious that the solid line in Fig. 3 is better in conformity with the original curve of Fig. 1a than the broken line in Fig. 3. Fig. 4 shows diagrammatically a device for encoding the signal. The device comprises an input terminal 1 for receiving the first signal. The input terminal 1 is coupled to an input 2 of an encoding device 3. The encoding device 3 processes the signal as described with reference to Figs. 1 and 2 and produces the sequence of information blocks on its output 4, which is coupled to the output terminal 5, where this sequence of information blocks is available, for example for the purpose of transmission via a transmission medium. The encoding device 3 comprises a first unit 6, having an input 7 constituting the input 2 of the encoding device 3. The firt unit 6 is constructed to determine for every instant the curvature k of the signal f 0 and to produce the curve k represetning this curvature on an output 8. This output 8 is coupled to an input 9 of an extreme-value detector 10. This extreme value detector 10 determines the extreme values in the curve k and supplies information about the instants (t 1 to t 8 ) at which said extreme values occur to an output 11. This output 11 is coupled to a first input 12 of a combination circuit 13. The extreme-value detector 10 in general detects absolute and relative extreme values, i.e. maxima and minima, namely when the curvature is plotted for positive values (for example if it is a convex curvature) and for negative values (if it is a concave curvature). If only an absolute value is plotted for the curvature the extreme-value detector 10 will determine only absolute and relative maxima. The input 2 of the encoding device 3 is coupled to a second input 14 of the combination circuit 13. For every instant applied via the input 12 the combination circuit 13 determines the value of the signal f 0 associated with this instant and applied via the the input 14, and generates the sequence of information blocks (B 1 to B 8 ) as shown in Fig. 2 on an output 15. The output 15 is coupled to the output terminal 4 of the encoding device 3. The curvature k can be determined in various ways. A known method is to start from the second time derivative of the signal f 0 . The curvature k can be computed, for example, by means of the following formula: k = f 0 "/{1+(f 0 ') 3/2 } where f 0 ' and f 0 " are the first time derivative and the second time derivative of the signal f 0 . Computing the second derivative in fact means subjecting the signal f 0 to a strong high-pass filtration. This results in brief and rapid pitch variations being amplified because these have a highfrequency content. These variations belong to the domain of what is called micro-intonation, i.e. they are perceptually non-significant. Micro-intonation may be regarded as a form of noise in the signal, which disturbs the computation of the derivatives. For this reason the computation of the derivatives should be preceded by a substantial smoothing (of the pitch contour), which only leaves the more gradual perceptually relevant pitch variations in tact. However, this does not yet provide a satisfactory encoding accuracy. Another consequence of thus determining the curvature is that if a time interval of a comparatively steady pitch is followed by a time interval in which the pitch varies rapidly, the curve representing the curvature will exhibit a maximum which is shifted to some extent towards the stable interval. In order to preclude this the curvature k, in accordance with the invention, is now determined in a manner to be explained with reference to Fig. 5. First of all, in order to determine the curvature k i = k(t i ) at a specific instant t i two straight lines L 1 and L 2 are determined for this instant. In Fig. 5a these two lines are represented as broken lines L 1 and L 2 . The two lines should intersect at the instant t i . The lines L 1 and L 2 are determined as approximations to lines through the points f 0 (t i - n ) to f 0 (t i + m ). Both lines can be determined by means of a least-squares method. This enables the influence of time samples for instants further away from t i to be reduced by means of a weighting function as illustrated in Fig. 5b. If desired, the amplitude for the pitch may be included in the weighting function. The values n and m may be equal to one another. Approximation by means of the least-squares method implies that the quantity M, which can be expressed by means of the formula: should be minimal. In the formula p i is the common value of the two lines at the intersection of the two lines at the instant t i . This enables the two lines to be determined. The angle α(i) between the two lines L 1 and L 2 is now a measure of the curvature of the pitch f 0 at the instant t i . For every instant t i the above process is carried out, so that for all instants t i the value α(i) is obtained. Determining the instants for which the curvature is maximal now means that the minima and the maxima in the function α(i) must be determined. It is possible to use the common values P i at the instants t 1 to t 8 for the amplitude information in an information block. This is represented by the second signal in Fig. 6. The device shown in Fig. 4 should then be slightly adapted, see Fig. 7. The first unit 6′ is now slightly modified and now has a second output to which the value P i are applied, which are subsequently transferred to the input 14 of the extreme-value detector 10. This extreme-value detector 10 selects exactly those values P i associated with the instants t 1 to t 8 . The signal shown in Fig. 6 will then appear on the output 15. It is to be noted that the invention is not limited to the embodiments described herein. The invention also applies to those embodiments which differ from the embodiments shown in respects which are not relevant to the invention. For example, the method and the device may be used for encoding signals other than those representing the pitch. An example of this is the encoding of the curves for the formant frequencies as a function of time.

Claims: A method for encoding an input speech signal parameter such as a time-dependent speech pitch, to form a second signal which comprises a sequence of information blocks, each block having an indication of a specific instant in time and an amplitude derived from said first signal with respect to that instant, said method comprising the steps of measuring a time-dependent curvature of the first signal, detecting a sequence of peaks in said curvature, and for each peak loading an information block with said amplitude, so that each block identifies one such peak, characterized in that said first signal is sampled at periodic instants, for each such instant a first straight line is determined as approximating a limited set of said amplitudes at preceding instants, and a second straight line is determined as approximating a limited set of said amplitudes at subsequent instants, and in that for every instant the angle of intersection between said first and second straight lines is determined as a measure for a curvature value pertaining to the instant in question. A method as claimed in Claim 1, characterized in that said straight lines are derived by a least-square method. A device for carrying out the method as claimed in Claims 1 or 2, comprising a terminal for receiving the input signal, and an encoding unit fed by said terminal and provided with an output, which encoding unit is constructed to encode the input signal to form a second signal which comprises a sequence of information blocks, each block having an indication of a specific instant in time and an amplitude derived from said first signal with respect to that instant, said unit being arranged for measuring a time-dependent curvature of the input signal, detecting a sequence of peaks in said curvature, and for each peak loading an information block with said amplitude, so that each block identifies one such peak, characterized in that the unit is arranged for sampling said first signal at periodic instants, for each such instant determining a first straight line as approximating a limited set of said amplitudes at preceding instants, and determining a second straight line as approximating a limited set of said amplitudes at subsequent instants, and in determining for every instant the angle of intersection between said first and second straight lines as a measure for a curvature value pertaining to the instant in question. A device as claimed in Claim 3, wherein said unit is arranged for determining said straight lines by means of a least-squares method. A device as claimed in Claims 3 or 4, characterized in that the amplitude information in an information block corresponds to the magnitude of the first signal at said instant. A device as claimed in Claim 3 or 4, characterized in that the amplitude information in an information block corresponds to the value at the intersection of the two lines which intersect one another at said instant.

Inventors: HERMES DIRK JAN, HERMES, DIRK JAN
Applicants: PHILIPS ELECTRONICS NV, PHILIPS ELECTRONICS N.V.
Application year: 1989
Main classification: G10L9
IPC codes: H03M3, G10L19, G10L11