Methods, apparatus, and systems for enabling adaptive prediction and quantization in frequency domain predictors

Dynamic adjustment of quantization in frequency domain predictors addresses suboptimal rate-distortion issues by adapting to signal statistics, resulting in improved encoding performance for biomedical and audio signals.

WO2026122426A1PCT designated stage Publication Date: 2026-06-11DOLBY LABORATORIES LICENSING CORP +1

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
DOLBY LABORATORIES LICENSING CORP
Filing Date
2025-12-01
Publication Date
2026-06-11

AI Technical Summary

Technical Problem

Existing frequency domain predictors use static quantization and dequantization processes, leading to suboptimal rate-distortion performance in encoding prediction residual samples.

Method used

Implementing a dynamically adjustable quantization process that adapts on a sample-by-sample basis, considering quantizer effects and statistical measures of the input signal to improve rate-distortion performance.

🎯Benefits of technology

Achieves lower bitrates and reduced distortion in encoded FD samples, particularly for biomedical and audio signals, by optimizing quantization based on signal statistics.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure US2025057474_11062026_PF_FP_ABST
    Figure US2025057474_11062026_PF_FP_ABST
Patent Text Reader

Abstract

An aspect of the present disclosure relates to a method for encoding an input signal, the method comprising obtaining at least one input frequency-domain, FD, frame. The method comprises for the at least one input FD frame applying a residual coding operation to the FD frame. The residual coding operation comprises for each bin, quantizing a prediction residual of the input FD sample of the bin with a quantizer to form a quantized sample and dequantizing the quantized sample of the bin with a dequantizer to form a reconstructed sample, determining a residual sample based on the reconstructed sample and the input FD sample; and forming an encoded bitstream comprising encoded representations of each residual sample. Wherein the quantization process of at least the quantizer is dynamically adjusted over the input FD frames based on the input signal.
Need to check novelty before this filing date? Find Prior Art

Description

METHODS, APPARATUS, AM) SYSTEMS FOR ENABLING ADAPTIVE PREDICTION AND QUANTIZATION IN FREQUENCY DOMAIN PREDICTORSCROSS-REFERENCE TO RELATED APPLICATIONS

[0001] This application claims the benefit of priority from United States Provisional Patent Application 63 / 726,823, filed on 2 December 2024, and European Patent Application No.25183837.1, filed on 18 June 2025, each of which is incorporated by reference herein in its entirety.TECHNICAL FIELD OF THE INVENTION

[0002] The present disclosure relates generally to encoding and decoding, more specifically to methods and devices for quantizing and dequantizing prediction residual samples in an encoder.BACKGROUND OF THE INVENTION

[0003] Frequency domain predictors are used to form prediction residual samples that can be encoded. For many types of signals and predictors the prediction residual samples have a smaller energy compared to the original samples whereby prediction residual coding often results in encodings of lower bitrates.GENERAL DISCLOSURE OF THE INVENTIONAccording to a first aspect there is provided a method for encoding an input signal, the method comprises obtaining at least one input frequency-domain (FD) frame, each input FD frame comprising a set of input FD samples, wherein each input FD sample represents a respective frequency bin (band). The method further comprises, for the at least one input FD frame, applying a residual coding operation to the FD frame. The residual coding operation comprises, for each bin quantizing a prediction residual of the input FD sample of the bin with a quantizer to form a quantized sample dequantizing the quantized sample of the bin with a dequantizer to form a reconstructed sample and determining a residual sample based on the reconstructed sample and the input FD sample. The method further comprises forming an encoded bitstream comprising encoded representations of each residual sample wherein the quantization process of at least the quantizer is dynamically adjusted over the input FD frames based on the input signal.

[0004] The first aspect is at least partially based on the understanding that the rate distortion (RD) performance of adaptive prediction followed by quantization and coding ofprediction residual samples can be improved by considering quantizer effects during adaptation of the predictor samples and / or by changing the properties of the quantizer, such as dynamically adjusting the quantization process on a sample-by-sample basis.

[0005] The method of the first aspect results in encoded and quantized FD prediction residual samples which may be provided to a decoder, mirroring the setup of the encoder, for decoding and reconstruction of the FD samples (and optionally the associated time-domain samples by using an inverse transform). With the dynamic adjustment of the quantization process of the present disclosure, the quantization and / or dequantization process may be adjusted on a sample-by-sample basis resulting in an encoded bitstream ultimately having a lower bitrate and / or wherein the reconstructed FD samples may suffer from less distortion. Compared to using e.g. a static quantization / dequantization process, the dynamic adjustment of the present disclosure has shown to result in improved (e.g. lower) rate-distortion for the encoder-decoder chain.

[0006] The proposed dynamic adjustment quantization process in a FD predictor may bring rate-distortion improvements for FD samples originating from any type of input signal. For example, the input signal is a biomedical input signal, such as a time-domain biomedical signal which has been transformed to the frequency-domain.

[0007] According to a second aspect there is provided a computer program product comprising instructions to cause a computer to execute the steps of the method according to the first aspect.

[0008] According to a third aspect there is provided a computer readable storage medium comprising instructions which, when the program is executed by a computer, cause the computer to carry out the method according to the first aspect.

[0009] According to a fourth aspect there is provided a frequency domain predictor comprising a processor and memory, wherein the processor is configured to perform the method according to the first aspect

[0010] The second through fourth aspect features the same or equivalent benefits as the first aspect. Any functions described in relation to the method, may have corresponding features in a system, computer program product and / or computer readable storage medium.BRIEF DESCRIPTION OF THE DRAWINGS

[0011] Embodiments of the present invention will be described in more detail with reference to the appended drawings, showing currently preferred embodiments of the invention.

[0012] Figure 1 A is a graph illustrating an example for deriving the bias using a straight lines fit to an optimal measured bias.

[0013] Figure IB is a graph showing the converged bias for gaussian noise after 5000 samples.

[0014] Figure 1C is a graph illustrating the percentage rate distortion advantage of using a dynamically adjustable bias compared to using a static bias according to some implementations.

[0015] Figure 2A is a flowchart illustrating a method for predicting a residual sample with a frequency-domain predictor.

[0016] Figure 2B is a flowchart illustrating a method for predicting a residual sample with a frequency-domain predictor implementing multiple candidate quantization processes to facilitate dynamic adjustment of the quantization process.

[0017] Figure 3 is a block diagram illustrating a system for performing residual encoding with dynamically adjusted quantization according to some implementations.DETAILED DESCRIPTION OF CURRENTLY PREFERRED EMBODIMENTS

[0018] Embodiments of the present invention will be described in the following with reference to exemplary methods for dynamically adjusting a quantization process.

[0019] Systems and methods disclosed in the present application may be implemented as software, firmware, hardware or a combination thereof. In a hardware implementation, the division of tasks does not necessarily correspond to the division into physical units; to the contrary, one physical component may have multiple functionalities, and one task may be carried out by several physical components in cooperation.

[0020] The computer hardware may for example be a server computer, a client computer, a personal computer (PC), a tablet PC, a set-top box (STB), a personal digital assistant (PDA), a cellular telephone, a smartphone, a web appliance, a network router, switch or bridge, or any machine capable of executing instructions (sequential or otherwise) that specify actions to be taken by that computer hardware. Further, the present disclosure shall relate to any collection of computer hardware that individually or jointly execute instructions to perform any one or more of the concepts discussed herein.

[0021] Certain or all components may be implemented by one or more processors that accept computer-readable (also called machine-readable) code containing a set of instructions that when executed by one or more of the processors carry out at least one of the methods described herein. Any processor capable of executing a set of instructions (sequential or otherwise) that specify actions to be taken are included. Thus, one example is a typical processing system (i.e. a computer hardware) that includes one or more processors. Each processor may include one or more of a CPU, a graphics processing unit, and a programmable DSP unit. The processing system further may include a memory' subsystem including a harddrive. SSD. RAM and / or ROM. A bus subsystem may be included for communicating between the components. The software may reside in the memory subsystem and / or within the processor during execution thereof by the computer system.

[0022] The one or more processors may operate as a standalone device or may be connected, e.g., networked to other processor(s). Such a network may be built on various different network protocols, and may be the Internet, a Wide Area Network (WAN), a Local Area Network (LAN), or any combination thereof.

[0023] The software may be distributed on computer readable media, which may comprise computer storage media (or non-transitory media) and communication media (or transitory media). As is well known to a person skilled in the art, the term computer storage media includes both volatile and non-volatile, removable and non-removable media implemented in any method or technology7for storage of information such as computer readable instructions, data structures, program modules or other data. Computer storage media includes, but is not limited to. physical (non-transitory) storage media in various forms, such as EEPROM, flash memory or other memory technology, CD-ROM, digital versatile disks (DVD) or other optical disk storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can be accessed by a computer. Further, it is well know n to the skilled person that communication media (transitory) ty pically embodies computer readable instructions, data structures, program modules or other data in a modulated data signal such as a carrier wave or other transport mechanism and includes any information delivery7media.

[0024] A frequency -domain (FD) predictor operates on FD samples provided as FD frames. Each FD frame comprises a plurality of FD samples and each FD sample is associated with a frequency band or frequency bin. To form the FD prediction residual the FD predictor predicts a FD sample based on one or more previously reconstructed bins, computes the residual sample (the prediction error) by comparing to the original sample, quantizes the FD residual sample and subsequently dequantizes the quantized FD residual sample and reconstructs the sample. Optionally, the FD predictor further applies a non-linear least mean square scheme to predict the FD prediction residual sample of one bin based on one or more previously predicted samples of higher and / or lower bins.

[0025] In this disclosure, the FD predictor may be any suitable predictor operating in the frequency domain and predicts FD samples based on previously reconstructed samples. In some implementations, the FD predictor is a backwards, or ‘downward’, residual predictor, in which the sequential processing of the predictive coding operation proceeds in order from high to low frequency bins. It is noted that this approach may enable efficient coding for many types of timedomain input signals, such as biomedical and audio signals. In other implementations, the FD predictor is an upward predictor, configured to perform sequential processing of the bins from low to high frequency bins. For example, the FD predictor of U.S. Provisional Patent Application No. 63 / 713,216 or European patent application number 24209441.5 which is herewith incorporated by reference in its entirety. The FD predictor may be configured to apply a predictive coding operation to the FD frame wherein the predictive coding operation comprises sequentially processing the bins (also referred to as bands), to determine, for each of the bins, a predicted sample, a prediction residual, and a reconstructed sample. In the case of downward prediction, the highest frequency bin n = N — 1 will typically be initialized prior to predicting samples for the lower frequency bins n < N — 1. Correspondingly, in case of upward prediction, the lowest frequency bin n = 0 will typically be initialized prior to predicting samples for the higher frequency bins n > 0. The prediction residual sample of each bin forms the output FD prediction residual frame.

[0026] The frequency domain may be any type of frequency domain, such as DCT or DST.

[0027] The input signal to the FD predictor may be a FD transform of a time domain input signal. For example, the time domain input signal may comprise a sequence of time domain samples, wherein the set of input FD domain samples obtained by the FD predictor may be samples of FD transform domain representation of (a channel of) a frame of the time domain input signal.

[0028] The time domain input signal used to form the FD input signal, may be a time domain biomedical signal comprising one or more channels of time domain biomedical signal samples. A biomedical signal in the context of the present disclosure may be a signal that relates to physiological information, and the signal may be electrical, physical or biochemical. The biomedical signal may relate to biological systems and conditions, examples of which may include Electrocardiography (ECG) data, Electroencephalography (EEG) data, Electromyography (EMG) data, and Photoplethysmogram (PPG) data, or signals for blood sugar level, heart rate, body temperature, respiratory rate and oxygen saturation. Further, a biomedical signal may comprise one or more channels of time domain biomedical signal samples. In other examples, the biomedical signals may relate to muscle and / or skin measurements. Any other medical signal and / or physical response would also be understood to be comprised by this definition. As another example, a time domain input signal may be a time domain audio signal comprising a sequence of time domain audio samples. However, the present disclosure is not limited to time domain input signals, but may more generally be applied to encode also other types of input signals that may be transformed into a frequency domain representation and whichmay benefit from improved rate-distortion. More generally, the input signal may be a waveform domain input signal and comprise a sequence of waveform domain samples distributed in a spatial dimension, with each sample indicating a property at a position in space. For example, an input signal may represent one or more channels of an image, with each sample representing a value (e.g. color, brightness, etc.) associated with an individual pixel of the channel of the image.

[0029] Traditionally, the quantizer and dequantizer of a FD predictor are static and perform the same quantization process (and corresponding dequantization process) for all bins and for all frames. For example, the quantization process is floor quantization process with a predetermined bias. The predetermined bias may be 0.5. Alternatively, the predetermined bias is 0.4054 which has been found to improve distortion when the FD predictor is used with an entropy encoder.

[0030] In a first embodiment, the bias is dynamically adjusted based on a statistical measure of the input signal or the residual signal.

[0031] In the first embodiment, a statistical measure is determined for a current bin of a cunent FD frame based on either: one or more other frequency bins of the current frame (alternative A) or based on the current bin of one or more preceding frames (alternative B). Alternative A does not require multiple preceding frames to be stored, which may bring some benefits in terms of reduced memory requirements. However, both alternative A and alternative B could be used. In the below, alternative B is described in detail, but it is understood that alternative is analogous, with the difference being that the statistical measure is determined using one or more other bins of the same frame instead of the same bin of one or more preceding frames.

[0032] Optionally, the quantizer intervals of the quantization process are based on an estimate of the signal variance per frequency bin (band) over time.

[0033] A memory and computation efficient estimate of the variance per frequency bin is obtained by first order IIR filtering of the past quantizer input samples for a given frequency bin while performing adaptive prediction. The IIR filter may have history weight of about 0.8.

[0034] In an alternative, less memory efficient, implementation the statistical measure may be estimated per frequency bin by averaging over preceding frames per frequency bin.

[0035] The dynamic rounding bias to use in the quantization process may now be estimated based on the variance measure or based on a standard deviation measure. The standard deviation measure may be based on the variance measure. A computational efficient computation of the standard deviation measure that avoids a square root operation of the variance may be obtained by averaging the absolute value of the quantizer input samples. Under an assumption of the probability density function of the quantizer input signal the standard deviation may bederived from the average absolute value by applying a constant gain. Under the assumption of a normal probability distribution density’ function the gain for example is about 1 .25.

[0036] In some implementations, the bias is determined based on an assumption of the signal probability density function and minimization of an objective function (cost function) which may incorporate distortion and bitrate. Examples of signal probability density functions that are applicable to many types of signals is normal distribution or Laplacian distribution. The objective function may be based on a rate-distortion RD metric which is determined in closed loop fashion by encoding the FD prediction residual frame (including quantization and entropyencoding), decoding the encoded frame and comparing the decoded frame to the original frame.

[0037] In one embodiment, the best rounding bias (e.g. in terms of rate and / or distortion) is empirically found and stored in a table as a function of quantization step size and the statistical measure (such as the signal variance). For each frame and each frequency bin, the rounding bias can therefore be found using the look-up table using the step size and statistical measure.

[0038] The dynamically adjusted rounding bias may also be based on an estimated expected magnitude rather than the variance measure.

[0039] In one exemplary embodiment, the rounding bias B is determined based on the expected magnitude E [| X |] asB = max 0.5_ __ . 0.1, 0.1(1)wherein S is the step size of the quantization process and E[|X|] is the expected magnitude based on past quantizer input samples X. The relationship between the bias B and expected magnitude E [ |X|] of equation 1 is merely exemplary and other relationships are envisaged. The same applies to other statistical measures such as the variance. For example, a higher order polynomial may be used to determine the bias B for a specific frequency bin based on a statistical measure determined based on the samples of the specific frequency bin in preceding frames, or more memory efficient, based on the past quantizer input samples in the same frame.The relationship between the bias B and the statistical measure may be based on a straight line fit of the measured optimal bias in terms of distortion and bitrate where the straight line fit may be constructed for multiple ranges of the statistical measure as shown in FIG. 1 A. FIG. 1 A illustrates an example for deriving the bias using straight lines fit to optimal measured bias. In FIG. 1A, line B is the function y = a + bx with a = 0.5 and b = -0.085 and line A is the function y = a + bx with a = 1.725 and b = -0.575. Line C illustrates the optimum achieved with training data (lambda 0. l l).

[0040] Line C shows the rate-distortion optimal bias B for a specific entropy coder and gaussian noise input over the normalized quantization step size (normalized by the standarddeviation). In an some implementations, the optimal bias B may be derived based on the quantization step size and the estimated standard deviation (which may be derived also more efficiently from the averaged magnitude) by a simple straight line fit as shown by lines A and B which are parametrized with 4 parameters (two each). If the normalized step size parameter is below 2.5, then line B is used, otherwise line C is used. Using only few parameters for this mapping has the advantage that the parameters could be adapted using the initial parameters shown in FIG. 1 A to a specific entropy coder.

[0041] In another embodiment, the relationship between the bias B and the statistical measure may be stored in a table and the bias B derived by indexing into the table where the index is related to the statistical measure. The table may store the bias values shown in line C in FIG. 1A. Good bias values that may be stored in that table may also be found by means of equation (6) for example for gaussian noise at fixed variance and varying the quantization step size. The result of this procedure for 5000 samples and biases averaged over 2048 runs is shown in FIG. IB. That is, FIG. IB shows the converged bias for gaussian noise after 5000 samples.

[0042] The expected magnitude may be determined as the average magnitude of the same frequency bin of preceding frames

[0043] FIG. 1 C is graph showing the Percentage Rate Distortion (PRD) as a function of bits per sample when a static quantization process with a bias of 0.4054 is used (line D) and when a dynamically adjusted quantization process based on the expected magnitude of the FD sample in accordance with equation 1 is used (line E). As seen, the dynamically adjusted bias archives better performance in terms of low er PRD for all bits per sample.

[0044] In a second embodiment, the quantization process is dynamically adjusted by applying two candidate, different, quantization processes on a frequency bin i, wherein the quantization process which yields the best result (e g. in terms of rate and / or distortion) over the following (higher or lower) n frequency bins is selected and applied in a final quantization process.

[0045] In some implementations, the two candidate quantization processes comprise one quantization process which uses the next higher quantization index (i.e. ceiling quantization) and one quantization process that uses the closest lower quantization index (i.e. floor quantization). Both candidate quantization processes are attempted and it is evaluated how the performance is affected. For example two candidate predictors are defined (each using a respective candidate quantization process) and it is determined how the predictors perform for the n frequency bins in FD frame. For example, the candidate quantization processes are attempted for a start bin and one or more subsequent frequency bins. The candidate quantization process which performs bestfor the start bin and the one or more subsequent bins is selected and used to quantize at least the start bin. The process then moves to next bin and is repeated.

[0046] After the candidate quantization processes have operated over the n bins it is determined which path is better by a cost measure which takes into account the overall distortion of the n bins and / or a counted or estimated number of bits needed for noiseless coding of the bins. Again an RD metric may be computed to evaluate the performance.

[0047] Based on the performance of the predictions (prediction gain, energy of quantized residual or other available measures, such as RD measure) the quantization process is dynamically selected.

[0048] Overall, the quantization process of the FD predictor is updated after n bins have been processed with the two candidate FD predictors and the one associated with the best performance has been selected.

[0049] FIG. 2B is a flowchart illustrating a method for dynamically adjusting the quantization process using this “trial and error’ procedure. FIG. 2A is a flowchart showing the default steps that are performed to predict and quantize a sample of a frequency bin.

[0050] With reference to FIG. 2A the method starts with S 1 where the input sample of frequency bin i obtained. The method then goes to step S2 involving quantizing and inverse quantizing the residual w.r.t. to a prediction of the sample of frequency bin i to form a reconstructed residual sample rqi. The reconstructed residual sample may be used to update the prediction filter of the FD predictor which is done updated at step S3 to facilitate better (more accurate) prediction in subsequent bins. Finally, the method goes to step S4 wherein the preceding method steps are repeated, but this time for frequency bin index i +1.

[0051] FIG. 2B illustrates the method of the second embodiment. Steps SI, S3 and S4 are the same as in the flowchart of FIG. 2A. At step S21 prediction data including filter coefficients priand filter states are saved. The method then goes to step S22 involving identifying two candidate quantization processes that results in two different reconstructed residual samples rqii and rqi2 for frequency bin i. For example, one candidate quantization process takes the next higher quantization index and the other candidate quantization process takes the next lower quantization index.

[0052] The method then goes to steps S23 and S24. In step S23 the saved filter coefficients pu and filter states are used as initial state and for the n-i next bins the following substeps are performed in the current FD frame starting with reconstructed samples rqii: updating the prediction parameters of the adaptive predictor predicting the sample of the relevant frequency bin in the current framequantizing the residual according to the current quantization process (the first candidate quantization process)

[0053] Finally, after the above steps have been performed, an overall distortion and / or rate metric is determined for the n bins of the current FD frame.

[0054] Step S24 is similar to step S23 but a difference is that in step S24 the second candidate quantization process is used instead of the first candidate quantization process. That is, in step S24 the saved filter coefficients priand filter states are used and for the n-1 next bins the following substeps are performed in the current frame starting with reconstructed samples rqi2: updating the prediction parameters of the adaptive predictor predicting the sample of relevant frequency bin in the current frame quantizing the residual according to the current quantization process (the second candidate quantization process)

[0055] Finally, after the above steps have been performed, an overall distortion and / or rate metric is determined for the n bins (from the current frame).

[0056] The method then goes to step S25 comprising setting the reconstructed sample rq, of the “start” bin to rqii or rqi2 depending which candidate quantization process achieved the best bitrate and / or distortion considering the next bins which where attempted (e.g. the best candidate quantization process is the one associated with the lowest RD metric). The method then goes to step S26 comprising restoring the saved filter coefficients priand filter states before the method continues with steps S3 and S4. In step S3 rqii or rqi2 is used.

[0057] After the candidate quantization processes have been evaluated over n bins the selected quantization process may be used for a plurality of the n bins such as all n bins to save computational complexity. In some implementations, selected quantization process may only be used for the starting bin or “current” bin.

[0058] In a third embodiment the bias is dynamically adjusted based on an equal expected magnitude (EEM) approach. The envisaged equal expected magnitude approach may be implemented in two variants, a first variant and a second variant. The two variants are mathematically equivalent but the second variant may have some advantages in terms of reduced computational complexity.

[0059] The first variant will now be described as it operates over a sequence of consecutive FD frames in a specific frequency bin i. The same process may be repeated for each frequency bin.

[0060] The quantization process at frame N is governed by a step size S and a bias B. In this formulation, it is assumed that B is greater than or equal to 0 and less than 1. The FD sampleis labelled C. A quantization index of C is found by deriving an intermediate non-negative variable m and then applying the sign of C:and k = sign(C * m. (3)

[0061] A dequantized reconstruction R of C may then be determined aswhich corresponds to|7?| = m * S. (5)

[0062] A predetermined initial value of Boid is defined. For example the predetermined initial value of Boid is about 0.4. An update step e is also defined. The update step e is defined as 0 < e « 1. For example, e = 0.01.

[0063] Now. for each frame, Boid of a preceding frame is obtained and the quantization and dequantization reconstruction is performed using B = Boid in accordance with equations 2-5 above. That is, in a current frame Boid of a preceding frame is obtained and the quantization and dequantization reconstruction using B=Boid. It may then be evaluated if m > 0. If this is the case, an updated bias Bnew is calculated based on Bold and the update step e as=e(KI - I) DnewDold ' g (6)

[0064] Bnew is an updated bias which replaces Boid and is used when processing frequency bin i in the next frame. This process is repeated for each frame whereby each frame for which m > 0 and there is a difference between | C | — | / ?| results in an incremental update of the bias which is then used in the next frame. Depending on the properties of the signal, the bias may hereby rapidly converge to a value which favors equal expected magnitudes of the FD sample C and the reconstruction R which is beneficial in terms of distortion. In the first variant the bias BnewandBoldare bounded to the interval 0 to 0.5.

[0065] From equation 6 it is seen that the process of updating the bias involves a division with S. Divisions may be computationally complex and to reduce computational complexity a second variant of the EEM-based bias adjustment process will now be described.

[0066] The quantization process at frame N is again governed by a static step size S and a bias B. The FD sample is labelled C. A quantization of C is found as:and dequantized reconstruction R of C may then be determined as| ? | = | / c| * S (8)

[0067] A predetermined initial value of Boid is defined and scaled with S. For example the predetermined initial value of Boid is about 0.4*S. An update step e is also defined. The update step e is defined as 0 < e « 1. For example, e = 0.01.

[0068] Now. for each frame Boid of a preceding frame is obtained and the quantization and dequantization reconstruction is performed using B = Boid in accordance with equations 7-8 above. That is, in a current frame Boid of a preceding frame is obtained and the quantization and dequantization reconstruction using B=Boid. It may then be evaluated ifm > 0. If this is the case, an updated bias Bnew is calculated based on Bold and the update step e asBnew = Bold +e(.\C\ — \R \). (9)Bncw is an updated bias which replaces Boid and is used when processing frequency bin i in the next frame. This process is repeated for each frame whereby each frame for which there is a difference between | C | — | / ? | results in an incremental update of the bias which is then used in the next frame. Depending on the properties of the signal, the bias may hereby rapidly converge to a value which favors equal expected magnitudes of the FD sample C and the reconstruction R which is beneficial in terms of distortion.

[0069] Compared to the first variant (see equation 7), the second variant does not use division in the updated step of equation 9 which may be beneficial in terms of being more computationally efficient. In the second variant the bias Bnewand Boldare bounded to the interval 0 to 0.5*S.

[0070] It is understood that in all of the above embodiments the quantization process and dequantization process may be dynamically adjusted together such that the dequantizer employs the dequantization process corresponding to the current quantization process used in the quantizer.

[0071] FIG. 3 is a block diagram showing an encoding system 1 for quantizing and encoding prediction residual samples using FD prediction. The encoding system 1 comprises a quantization controller 2 configured to perform a method according to any of the embodiments described in the present disclosure. That is, the quantization controller 2 is configured to dynamically adjust the quantization / dequantization process of the quantizer 3 and / or dequantizer 4 based on the samples of the input signal (in the same FD frame or in or more preceding FD frames). The output of the quantization controller may hereby be a quantization and / or dequantization bias to be used in the quantizer and / or quantizer 3 and / or dequantizer 4. In some implementations, the output from the quantization controller 2 is a type of quantization and / or dequantization which should be performed. For example, the quantization controller 2 instructs the quantizer 3 and / or dequantizer 4 to use a selected one of floor quantization and ceilingquantization. The selected quantization type may be obtained using the method illustrated in FIG. 2B wherein at least two candidate quantization processes are attempted over n > 2 samples.

[0072] The FD prediction may be obtained with a frequency domain predictor as show n in FIG. 3. An input sample for frequency bin i is provided to a residual calculator 5 which calculates the residual between the input sample and a prediction of said input sample. The prediction of the sample in bin i is based on one more previously predicted bins other than bin i. The residual is quantized with quantizer 3 and entropy coded with entropy coder 7 so as to form a bitstream. The quantized residual sample is provided to a dequantizer 4 which dequantizes the quantized sample to form a reconstructed residual sample.

[0073] The reconstructed residual sample is provided to a prediction sample updater 7 w hich updates the prediction algorithm for predicting samples of new- frequency bins based on previously predicted frequency bin using the new reconstructed residual sample. The dequantized residual sample is provided to summation point 6 wherein the prediction residual of the sample is added to the prediction. The result of the summation is added to the buffer and prediction module 8 which predicts a predicted sample for the next frequency bin that is to be processed.

[0074] This process may be repeated for all FD samples in a frame forming an encoded prediction residual at the output, which is included in the bitstream.

[0075] In the first embodiment, a statistical measure associated w ith the frequency bin i obtained based on frequency bin i in or more preceding frames is obtained at the output of the quantizer by the quantization controller 2 which dynamically adjusts the quantization and dequantization process of the quantizer 3 and dequantizer 4 based on the statistical measure as described above. For example, the statistical measure is the variance of the samples in frequency bin i calculated over tw o or more preceding frames. As another example, the statistical measure is the expected magnitude of the predicted samples determined based on the samples in frequency bin i over tw o or more preceding frames.

[0076] In the second embodiment, the quantization controller 2 is configured to perform the method according to FIG. 2B. This involves attempting two candidate quantization processes over two or more frequency bins, evaluating the performance (e.g. in terms of bitrate and distortion) and selecting a candidate quantizer based on the performance. Evaluation of the performance of the candidate quantization processes may involve running the entropy encoder 7 and a local decoder (not shown) to obtain a bitrate and / or distortion metric.

[0077] In the third embodiment, the quantization controller 2 obtains the prediction residual magnitude from the output of the quantizer and the reconstructed sample magnitude (i.e. the output from the dequantizer 4), compares these entities and incrementally updates aquantization bias based on the comparison in accordance with equations 2 - 9 above. The bias of the quantization process is therefore dynamically adjusted on a frame-by-frame basis and the most recent bias value is used to control the quantization process and dequantization process of the quantizer 3 and dequantizer 4.

[0078] Side information may also be included in the bitstream, the side information indicating which quantization process is used for each residual sample. This allows a decoder to employ the same type of dynamically adjusted dequantization.

[0079] Unless specifically stated otherwise, as apparent from the following discussions, it is appreciated that throughout the disclosure discussions utilizing terms such as "processing", ■‘computing”, “calculating”, “determining”, “analyzing” or the like, refer to the action and / or processes of a computer hardware or computing system, or similar electronic computing devices, that manipulate and / or transform data represented as physical, such as electronic, quantities into other data similarly represented as physical quantities.

[0080] It should be appreciated that in the above description of exemplary embodiments of the invention, various features are sometimes grouped together in a single embodiment, figure, or description thereof for the purpose of streamlining the disclosure and aiding in the understanding of one or more of the various inventive aspects. This method of disclosure, however, is not to be interpreted as reflecting an intention that the claimed embodiments require more features than are expressly recited in each claim. Rather, as the following claims reflect, inventive aspects lie in less than all features of a single foregoing disclosed embodiment. Thus, the claims following the Detailed Description are hereby expressly incorporated into this Detailed Description, with each claim standing on its own as a separate embodiment of this invention. Furthermore, while some embodiments described herein include some, but not other features included in other embodiments, combinations of features of different embodiments are meant to be within the scope of the invention, and form different embodiments, as w ould be understood by those skilled in the art. For example, in the following claims, any of the claimed embodiments can be used in any combination.

[0081] Furthermore, some of the embodiments are described herein as a method or combination of elements of a method that can be implemented by a processor of a computer system or by other means of carrying out the function. Thus, a processor with instructions for carrying out such a method or element of a method forms a means for carrying out the method or element of a method. Note that when the method includes several elements, e.g., several steps, no ordering of such elements is implied, unless specifically stated. Furthermore, an element described herein of an apparatus embodiment is an example of a means for carrying out the function performed by the element for the purpose of carrying out the embodiments of theinvention. In the description provided herein, numerous specific details are set forth. However, it is understood that embodiments of the invention may be practiced without these specific details. In other instances, well-known methods, structures and techniques have not been shown in detail in order not to obscure an understanding of this description.

[0082] Various aspects of the present disclosure may be appreciated from the following enumerated example embodiments (EEEs):

[0083] EEE 1. A method for encoding an input signal, the method comprising: obtaining at least one input frequency -domain, FD, frame, each input FD frame comprising a set of input FD samples, wherein each input FD sample represents a respective frequency bin; for the at least one input FD frame: applying a residual coding operation to the FD frame, the residual coding operation comprises for each bin: quantizing a prediction residual of the input FD sample of the bin with a quantizer to form a quantized sample; dequantizing the quantized sample of the bin with a dequantizer to form a reconstructed sample; determining a residual sample based on the reconstmcted sample and the input FD sample; and forming an encoded bitstream comprising encoded representations of each residual sample, wherein the quantization process of at least the quantizer is dynamically adjusted over the input FD frames based on the input signal.

[0084] EEE 2. The method according to EEE 1 , further comprising: determining a statistical measure of the input signal in at least a first bin by analyzing the FD samples of the first bin in one or more preceding frames to the at least one FD frame, wherein the quantization process is dynamically adjusted based on the statistical measure.

[0085] EEE 3. The method according to EEE 1, further comprising: determining a statistical measure of the input signal in at least one bin by analyzing the FD bin and one or more other bins in the same frame, wherein the quantization process is dynamically adjusted based on the statistical measure .

[0086] EEE 4. The method according to EEE 2 or EEE 3, wherein the statistical measure is the vanance of the first bin determined over two or more preceding input FD frames or based on the FD bin and preceding bins in the same frame.

[0087] EEE 5. The method according to EEE 2 or EEE 3. wherein the statistical measure is the mean absolute value of the first bin determined over two or more preceding input FD frames or based on the FD bin and the one or more other bins in the same frame.

[0088] EEE 6. The method according to EEE 4 or EEE 5, wherein the statistical measure is determined using first order IIR filtering of the first bin over one or more preceding FD frames or on the FD bin and preceding bins in the same frame.

[0089] EEE 7. The method according to any of EEEs 2 - 6. further comprising: obtaining a signal probability density7function; and dynamically adjusting the quantization process to minimize an objective function incorporating at least one of distortion and bitrate.

[0090] EEE 8. The method according to EEE 2 or EEE 3, wherein the statistical measure is the average of the squared samples or absolute samples of the first frequency bin over two or more preceding input frequency domain frames or the statistical measure is the average of the squared samples or absolute samples of first bin and one or more other bins of the same FD frame.

[0091] EEE 9. The method according to any of the preceding EEEs, wherein dynamically adjusting the quantization process comprises adjusting the bias of the quantization process.

[0092] EEE 10. The method according to EEE 9 when depending on EEE 2 or EEE 3, wherein bias values are stored in a look-up table as a function of quantization step size and values of the statistical measure, and wherein dynamically adjusting the bias of quantization process comprises locating a bias in the look-up table using the determined statistical measure and the quantization step size.

[0093] EEE 11. The method according to EEE 9 when depending on EEE 2 or EEE 3, wherein bias values are derived by mapping the statistical measure as a function of quantization step size to the bias using straight line mapping or multiple straight lines mapping covering different ranges of the function of statistical measure and quantization step size.

[0094] EEE 12. The method according to any of the preceding EEEs, further comprising for n > 2 adjacent frequency bins in an FD frame: in a first quantization simulation, determining a first residual sample for a current frequency bin out of the n bins by:- quantizing the residual of the predicted input sample of the current bin with a first candidate quantizer to form a first quantized sample;- dequantizing the first quantized sample of the current bin with a first dequantizer to form a first reconstructed sample; and- determining the next n-1 residual samples and quantizing them with the first candidate quantizer to form n first residual samples, while updating the adaptive predictor based on preceding first reconstructed samples and input samples; and in a second quantization simulation, determining a second residual sample for the current frequency bin by:- quantizing the residual sample of the current bin with a second candidate quantizer to form a second quantized sample;- dequantizing the second quantized sample of the current bin with a second dequantizer to form a second reconstructed sample; and- determining the next n-1 residual samples and quantizing them with the second candidate quantizer to form n second residual samples, while updating the adaptive predictor based on previous second reconstructed sample and input samples; determining a bitrate and / or distortion associated with the first and second residual samples of the first bin and the subsequent n-1 frequency bins of each respective residual sample and quantization simulation; selecting the first or second candidate quantizer / dequantizer pair based on the bitrate and / or distortion; and forming an encoded bitstream comprising encoded representations of at least one of the n frequency bins obtained using the selected candidate quantizer / dequantizer pair.

[0095] EEE 13. The method according to EEE 12, wherein the first quantizer is a floor quantizer and the second quantizer is a ceiling quantizer.

[0096] EEE 14. The method according to EEE 12 or EEE 13, wherein the encoded bitstream comprises the current frequency bin obtained using the selected candidate quantizer / dequantizer pair.

[0097] EEE 15. The method according to EEE 12 or EEE 13, wherein the encoded bitstream comprises the current frequency bin and between 1 and n-1 additional frequency bins of the n frequency bins obtained using the selected candidate quantizer / dequantizer pair.

[0098] EEE 16. The method according to EEE 1, further comprising: obtaining for a first frequency bin for a current FD frame a bias associated with the first frequency bin of a preceding FD frame, wherein the bias of the quantizer and dequantizer is set to the bias associated with the preceding FD frame; determining a modification term or factor based on the difference between the magnitude of the frequency domain sample of the first bin in the current FD frame and the magnitude of the reconstructed sample of the first bin in the current FD frame; modifying the bias associated with the first frequency bin of the preceding FD frame with modification term or factor to form a bias associated with the first frequency bin of the current FD frame; and wherein the bias of the quantizer and dequantizer in the first bin of at least one subsequent FD frame is set to the bias associated with the first frequency bin of the current FD frame.

[0099] EEE 17. The method according to EEE 16, wherein a predetermined bias is used for the quantizer and dequantizer in a first frame of the signal.

[0100] EEE 18. The method according to EEE 17. wherein the predetermined bias is between 0.3 and 0.5.

[0101] EEE 19. A computer program product comprising instructions to cause a computer to execute the steps of the method according to any of the preceding EEEs.

[0102] EEE 20. A computer readable storage medium comprising instructions which, when the program is executed by a computer, cause the computer to carry out the method according to any of EEEs 1-18.

[0103] EEE 21 . A frequency domain predictor comprising a processor and memory, wherein the processor is configured to perform the method according to any of EEEs 1 - 18.

[0104] The person skilled in the art realizes that the envisaged embodiments by no means are limited to the preferred embodiments described above. On the contrary, many modifications and variations are possible within the scope of the appended claims. For example, the dynamic adjustment of the quantization process according to any of the above described embodiments may be combined. Additionally, it is understood that side information describing the quantization process used may be included in the bitstream making it available to a decoder.

Claims

CLAIMS1. A method for encoding an input signal, the method comprising: obtaining at least one input frequency-domain, FD, frame, each input FD frame comprising a set of input FD samples, wherein each input FD sample represents a respective frequency bin; for the at least one input FD frame: applying a residual coding operation to the FD frame, the residual coding operation comprises for each bin: quantizing a prediction residual of the input FD sample of the bin with a quantizer to form a quantized sample; dequantizing the quantized sample of the bin with a dequantizer to form a reconstructed sample; determining a residual sample based on the reconstructed sample and the input FD sample; and forming an encoded bitstream comprising encoded representations of each residual sample, wherein the quantization process of at least the quantizer is dynamically adjusted over the input FD frames based on the input signal.

2. The method according to claim 1, further comprising: determining a statistical measure of the input signal in at least a first bin by analyzing the FD samples of the first bin in one or more preceding frames to the at least one FD frame, wherein the quantization process is dynamically adjusted based on the statistical measure.

3. The method according to claim 1, further comprising: determining a statistical measure of the input signal in at least one bin by analyzing the FD bin and one or more other bins in the same frame, wherein the quantization process is dynamically adjusted based on the statistical measure.

4. The method according to claim 2 or claim 3. wherein the statistical measure is the variance of the first bin determined over two or more preceding input FD frames or based on the FD bin and preceding bins in the same frame.

5. The method according to claim 2 or claim 3, wherein the statistical measure is the mean absolute value of the first bin determined over two or more preceding input FD frames or based on the FD bin and the one or more other bins in the same frame.

6. The method according to claim 4 or claim 5, wherein the statistical measure is determined using first order HR filtering of the first bin over one or more preceding FD frames or on the FD bin and preceding bins in the same frame.

7. The method according to any of claims 2 - 6, further comprising: obtaining a signal probability density function; and dynamically adjusting the quantization process to minimize an objective function incorporating at least one of distortion and bitrate.

8. The method according to claim 2 or claim 3, wherein the statistical measure is the average of the squared samples or absolute samples of the first frequency bin over two or more preceding input frequency domain frames or the statistical measure is the average of the squared samples or absolute samples of first bin and one or more other bins of the same FD frame.

9. The method according to any of the preceding claims, wherein the quantization process is a floor quantization process having a bias, wherein dynamically adjusting the quantization process comprises adjusting the bias of the quantization process.

10. The method according to claim 9 when depending on claim 2 or claim 3, wherein bias values are stored in a look-up table as a function of quantization step size and values of the statistical measure, and wherein dynamically adjusting the bias of quantization process comprises locating a bias in the look-up table using the determined statistical measure and the quantization step size.

11. The method according to claim 9 when depending on claim 2 or claim 3, wherein bias values are derived by mapping the statistical measure as a function of quantization stepsize to the bias using straight line mapping or multiple straight lines mapping covering different ranges of the function of statistical measure and quantization step size.

12. The method according to any of the preceding claims, further comprising for n > 2 adjacent frequency bins in an FD frame: in a first quantization simulation, determining a first residual sample for a current frequency bin out of the n bins by:- quantizing the residual of the predicted input sample of the current bin with a first candidate quantizer to form a first quantized sample;- dequantizing the first quantized sample of the current bin with a first dequantizer to form a first reconstructed sample; and- determining the next n-1 residual samples and quantizing them with the first candidate quantizer to form n first residual samples, while updating the adaptive predictor based on preceding first reconstructed samples and input samples: and in a second quantization simulation, determining a second residual sample for the current frequency bin by:- quantizing the residual sample of the current bin with a second candidate quantizer to form a second quantized sample;- dequantizing the second quantized sample of the current bin with a second dequantizer to form a second reconstructed sample; and- determining the next n-1 residual samples and quantizing them with the second candidate quantizer to form n second residual samples, while updating the adaptive predictor based on previous second reconstructed sample and input samples; determining a bitrate and / or distortion associated with the first and second residual samples of the first bin and the subsequent n-1 frequency bins of each respective residual sample and quantization simulation; selecting the first or second candidate quantizer / dequantizer pair based on the bitrate and / or distortion; and forming an encoded bitstream comprising encoded representations of at least one of the n frequency bins obtained using the selected candidate quantizer / dequantizer pair.

13. The method according to claim 12, wherein the first quantizer is a floor quantizer and the second quantizer is a ceiling quantizer.

14. The method according to claim 12 or claim 13, wherein the encoded bitstream comprises the current frequency bin obtained using the selected candidate quantizer / dequantizer pair.

15. The method according to claim 12 or claim 13, wherein the encoded bitstream comprises the current frequency bin and between 1 and n-1 additional frequency bins of the n frequency bins obtained using the selected candidate quantizer / dequantizer pair.

16. The method according to claim 1, further comprising: obtaining for a first frequency bin for a current FD frame a bias associated with the first frequency bin of a preceding FD frame, wherein the bias of the quantizer and dequantizer is set to the bias associated with the preceding FD frame; determining a modification term or factor based on the difference between the magnitude of the frequency domain sample of the first bin in the current FD frame and the magnitude of the reconstructed sample of the first bin in the current FD frame; modifying the bias associated with the first frequency bin of the preceding FD frame with modification term or factor to form a bias associated with the first frequency bin of the current FD frame; and wherein the bias of the quantizer and dequantizer in the first bin of at least one subsequent FD frame is set to the bias associated with the first frequency bin of the current FD frame.

17. The method according to claim 16. wherein a predetermined bias is used for the quantizer and dequantizer in a first frame of the signal.

18. The method according to claim 17, wherein the predetermined bias is between 0.3 and 0.5.

19. The method according to any preceding claim, wherein the prediction residual is obtained by predicting, by an FD predictor, an FD sample based on one or more previously reconstructed bins.

20. The method of claim 19, comprising sequentially processing the bins to determine a prediction residual for each bin.

21. The method of claim 20, wherein the FD predictor is a backwards residual predictor.

22. The method of any preceding claim, wherein the FD input samples are samples of a FD representation of a frame of the time-domain input signal.

23. The method of claim 22, wherein the time domain input signal is a time-domain biomedical signal comprising one or more channels of time-domain biomedical signal samples.

24. A computer program product comprising instructions to cause a computer to execute the steps of the method according to any preceding claim.

25. A computer readable storage medium comprising instructions which, when the program is executed by a computer, cause the computer to carry out the method according to any one of claims 1-23.

26. A frequency-domain predictor comprising a processor and memory, wherein the processor is configured to perform the method according to any one of claims 1 to 23.