Audio processing method, apparatus and system, electronic device, storage medium and computer program product
The audio processing method uses a machine learning model to extract and quantize feature information, addressing scalability and bitrate issues in audio codecs, enabling efficient compression and downstream task performance.
Patent Information
- Application Number
- PCT/CN2025/107631
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-07-10
- Filing Date
- 2025-07-09
- Publication Date
- 2026-01-15
AI Technical Summary
Existing audio codecs face challenges in scalability and bitrate, with neural network-based codecs having high computing complexity and deployment complications, while traditional codecs require higher bitrates for diverse audio types.
An audio processing method involving a machine learning model that extracts feature information, quantizes it using a codebook, and provides quantized feature information to a downstream task processor, reducing data size and complexity through techniques like residual vector quantization and frequency-domain processing.
This approach enables efficient audio processing with reduced computational demands and improved scalability, allowing for effective audio compression and utilization in downstream tasks like sound event detection and speech recognition without significant performance degradation.
Smart Images

Figure CN2025107631_15012026_PF_FP_ABST
Abstract
Description
AUDIO PROCESSING METHOD, APPARATUS AND SYSTEM, ELECTRONIC DEVICE, STORAGE MEDIUM AND COMPUTER PROGRAM PRODUCTCROSS-REFERENCE TO RELATED APPLICATIONS
[0001] This application claims priority to PCT Patent Application No. PCT / CN2024 / 104770, and filed on July 10, 2024. The entire disclosure of the prior application is hereby incorporated by reference in its entirety.TECHNICAL FIELD
[0002] This disclosure relates to the field of audio processing technology, in particular to an audio processing method, an audio processing apparatus, an audio processing system, an electronic device, a computer readable storage medium and a computer program product.BACKGROUND
[0003] Audio codecs can be partitioned into two broad categories, waveform codecs and parametric codecs. Waveform codecs aim at reconstructing original waveform as faithful as possible at the decoder side. Parametric codecs aim at generating audio that is perceptually similar to the original.
[0004] The main difference between waveform codecs and parametric codecs is that parametric codecs makes assumptions about the source audio to be coded (in most cases, speech) , this makes it possible to encode audio with low bitrates.SUMMARY
[0005] According to some embodiments of the present disclosure, there is provided an audio processing method including: extracting, using an encoder, first feature information of an audio signal; quantizing the first feature information to obtain quantized feature information, the size of the quantized feature information being smaller than the size of the audio signal ; and providing the quantized feature information to a downstream task processor to allow the downstream task processor to perform an audio processing based on the quantized feature information.
[0006] In some embodiments, the providing the quantized feature information to the downstream task processor includes: sending the quantized feature information to a decoder, to allow the decoder to provide the downstream task processor with the first feature information after decompressing the quantized feature information into the first feature information.
[0007] In some embodiments, the audio processing includes at least one of sound event detection or speech recognition.
[0008] In some embodiments, the quantizing the first feature information to obtain the quantized feature information, includes: performing a quantizing process on the first feature information according to a codebook; and generating a bitstream as the quantized feature information according to a result of the quantizing process.
[0009] In some embodiments, the encoder includes a machine learning model configured to obtain the first feature information based on the audio signal, the codebook being determined during a training process of the machine learning model.
[0010] In some embodiments, the quantizing the first feature information to obtain the quantized feature information includes: projecting the first feature information into a second feature information, where a number of dimensions of the second feature information is less than a number of dimensions of the first feature information; and quantizing the second feature information to obtain the quantized feature information.
[0011] In some embodiments, the projecting the first feature information into the second feature information including: projecting the first feature information into the second feature information according to a factorization factor, the number of dimensions of the second feature information being determined according to the factorization factor.
[0012] In some embodiments, the audio signal is a time-domain audio signal, and the extracting, using the encoder, the first feature information of the audio signal includes: converting the time-domain audio signal to a frequency-domain audio signal; and extracting, using the encoder, the first feature information of the frequency-domain audio signal.
[0013] In some embodiments, the encoder includes a machine learning model, and the extracting, using the encoder, the first feature information of the frequency-domain audio signal includes at least one of followings: performing a two-dimensional convolution process on the frequency-domain audio signal using the encoder; processing the frequency-domain audio signal using a residual network block of the encoder; or performing a down sampling process on the frequency-domain audio signal using the encoder.
[0014] In some embodiments, the encoder includes a machine learning model, and the extracting, using the encoder, the first feature information of the frequency-domain audio signal includes: performing a first two-dimensional convolution process, a first residual network block process, a down sampling process, a second residual network block process, and a second two-dimensional convolution process, in sequence, on the frequency-domain audio signal, using the encoder.
[0015] According to still other embodiments of the present disclosure, there is provided an audio processing apparatus comprising: an extracting module configured to extract, using an encoder, first feature information of an audio signal; a quantizing module configured to quantize the first feature information to obtain quantized feature information, the size of the quantized feature information being smaller than the size of the audio signal; and a sending module configured to provide the quantized feature information to a downstream task processor to allow the downstream task processor to perform an audio processing based on the quantized feature information.
[0016] In some embodiments, the sending module sends the quantized feature information to a decoder , to allow the decoder to provide the downstream task processor with the first feature information after decompressing the quantized feature information into the first feature information.
[0017] In some embodiments, the audio processing includes at least one of sound event detection or speech recognition.
[0018] In some embodiments, the quantizing module performs a quantizing process on the first feature information according to a codebook; and generating a bitstream as the quantized feature information according to a result of the quantizing process.
[0019] In some embodiments, the encoder includes a machine learning model configured to obtain the first feature information based on the audio signal, the codebook being determined during a training process of the machine learning model.
[0020] In some embodiments, the quantizing module projects the first feature information into a second feature information, where a number of dimensions of the second feature information is less than a number of dimensions of the first feature information; and quantizing the second feature information to obtain the quantized feature information.
[0021] In some embodiments, the quantizing module projects the first feature information into the second feature information according to a factorization factor, the number of dimensions of the second feature information being determined according to the factorization factor.
[0022] In some embodiments, the audio signal is a time-domain audio signal, and the extracting module converts the time-domain audio signal to a frequency-domain audio signal; and extracting, using the encoder, the first feature information of the frequency-domain audio signal.
[0023] In some embodiments, the encoder includes a machine learning model, and the extracting module performs at least one of followings: performing a two-dimensional convolution process on the frequency-domain audio signal using the encoder; processing the frequency-domain audio signal using a residual network block of the encoder; or performing a down sampling process on the frequency-domain audio signal using the encoder.
[0024] In some embodiments, the encoder includes a machine learning model, and the extracting module performs a first two-dimensional convolution process, a first residual network block process, a down sampling process, a second residual network block process, and a second two-dimensional convolution process, in sequence, on the frequency-domain audio signal, using the encoder.
[0025] According to some embodiments of the present disclosure, there is provided an audio signal encoding method, including: extracting related a feature of an audio signal to be encoded using a pre-trained model in an encoder; and quantizing the feature using a codebook to generate a bitstream..
[0026] In some embodiments, the audio signal encoding method according to claim 1, further including: evaluated a performance of the encoder.
[0027] According to still other embodiments of the present disclosure, there is provided an audio signal decoding method, including: decompressing a bitstream from the encoding side to a feature using a decoder; and using the feature by multiple tasks.
[0028] In some embodiments, the audio signal decoding method according to claim 3, further including: evaluated a performance of the decoder.
[0029] According to still other embodiments of the present disclosure, there is provided an audio processing system, including: an audio signal encoding apparatus, configured to implement an audio signal encoding method according to any one of the above embodiments; and an audio signal decoding apparatus, configured to implement an audio signal decoding method according to any one of the above embodiments.
[0030] According to still other embodiments of the present disclosure, there is provided an audio processing system, including: an audio signal processing apparatus be configured to implement an audio signal processing method according to any one of the above embodiments; and a downstream task processor be configured to perform an audio processing based on quantized feature information provided by the audio signal processing apparatus.
[0031] According to still other embodiments of the present disclosure, there is provided an audio signal encoding apparatus, including: an extracting module configured to extract related a feature of an audio signal to be encoded using a pre-trained model in an encoder ; and a quantizing module configured to quantize the feature using a codebook to generate a bitstream.
[0032] According to still other embodiments of the present disclosure, there is provided an audio signal decoding apparatus, including: a decompressing module configured to decompress a bitstream from the encoding side to a feature using a decoder; and a task module configured to use the feature by multiple tasks.
[0033] According to still other embodiments of the present disclosure, there is provided an electronic device, including: a processor; a memory for storing processor executable instructions; where the processor is used to read the executable instructions from the memory and execute the instructions to implement an audio processing method, an audio signal encoding method, or an audio signal decoding method according to any one of the above embodiments.
[0034] According to still other embodiments of the present disclosure, there is provided a computer-readable storage medium having stored thereon a computer program that, when executed by a processor, implements an audio processing method, an audio signal encoding method, or an audio signal decoding method according to any one of the above embodiments.
[0035] According to still other embodiments of the present disclosure, there is provided a computer program product, including: instructions that, when executed by a processor, cause the processor to implement an audio processing method, an audio signal encoding method, or an audio signal decoding method according to any one of the above embodiments.
[0036] Other features and advantages of the present disclosure will become apparent from the following detailed description of exemplary embodiments of the present disclosure with reference to the accompanying drawings.BRIEF DESCRIPTION OF THE DRAWINGS
[0037] The accompanying drawings, which are incorporated in and constitute a portion of this specification, illustrate embodiments of the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0038] The present disclosure will be more clearly understood from the following detailed description with reference to the accompanying drawings, in which: FIG. 1a shows a schematic diagram of a novel neural audio codec according to some embodiments; FIG. 1b shows a schematic diagram of a novel neural audio codec according to other embodiments; FIG. 2a shows schematic diagram of an audio processing system according to some embodiments of the present disclosure; FIG. 2b shows schematic diagram of an audio processing system according to some embodiments of the present disclosure; FIG. 3 shows schematic diagram of a neural audio codec and its downstream tasks in Codec-SUPERB; FIG. 4a-4b show schematic diagrams of an audio processing system according to other embodiments of the present disclosure; FIG. 5a shows schematic diagrams of an audio processing system; FIG. 5b shows schematic diagrams of an audio processing system according to other embodiments of the present disclosure; FIG. 6a shows a flow diagram of an audio processing method according to some embodiments of the present disclosure; FIG. 6b shows schematic diagrams of an audio processing system according to other embodiments of the present disclosure; FIG. 7 shows schematic diagrams of an audio processing system according to other embodiments of the present disclosure; FIG. 8 shows schematic diagrams of mAP for three systems; FIG. 9 shows a block diagram of an electronic device according to other embodiments of the present disclosure; FIG. 10 shows a block diagram of an electronic device according to further embodiments of the present disclosure; FIG. 11 shows a block diagram of an audio processing apparatus according to some embodiments of the present disclosure; FIG. 12 shows a block diagram of an audio processing system according to other embodiments of the present disclosure.DETAILED DESCRIPTION
[0039] Various exemplary embodiments of the present disclosure will now be described in detail with reference to the accompanying drawings. Notice that, unless otherwise specified, the relative arrangement, numerical expressions and numerical values of the components and steps set forth in these examples do not limit the scope of the disclosure.
[0040] At the same time, it should be understood that, for ease of description, the dimensions of the plurality of parts shown in the drawings are not drawn to actual proportions.
[0041] The following description of at least one exemplary embodiment is in fact merely illustrative and is in no way intended as a limitation to the disclosure, its application or use.
[0042] Techniques, methods, and apparatus known to those of ordinary skill in the relevant art may not be discussed in detail, but where appropriate, these techniques, methods, and apparatuses should be considered as part of the specification.
[0043] Of all the examples shown and discussed herein, any specific value should be construed as merely illustrative and not as a limitation. Thus, other examples of exemplary embodiments may have different values.
[0044] Notice that, similar reference numerals and letters are denoted by the like in the accompanying drawings, and therefore, once an item is defined in a drawing, there is no need for further discussion in the accompanying drawings.
[0045] The terms used in this disclosure are described as following: ACoM (Audio Coding for Machine) ; mAP (Mean Average Precision) ; WER (Word Error Rate) ; DER (Diarization Error Rate) ; STFT (Short Time Fourier Transform) ; ISTFT (Inverse Short Time Fourier Transform) ; FFT (Fast Fourier Transform) ; DSP (Digital Signal Processing) ; CNN (Convolutional Neural Network) ; GAN (Generative Adversarial Networks) ; RVQ (Residual Vector Quantization) .
[0046] Developing either type of these codecs requires a deep understanding of signal processing, which makes the development of audio codec obscure and difficult to understand. With the development of machine learning, neural network is used more frequently in audio codecs. It is quite promising to replace DSP-based audio codecs with neural network audio codecs. On the one hand, developing neural network is a data-driven task, the requirement for deep understanding of signal processing can be converted to the variety of datasets. Generally speaking, the datasets used in audio codec is unsupervised (label is not needed by default) , it is much easier to increase the amount of data (cover more patterns and features) than to find patterns and features for audio manually. Therefore, the overall development cost can be reduced. On the other hand, scalability and bitrate are two conflicting problems in DSP-based audio codecs, higher bit rate is required for codec which covers several audio types than audio codec designed for a specific audio type (speech) . With the help of neural network and related techniques like vector quantization, scalability and bitrate can be considered at the same time.
[0047] However, those benefits of introducing neural network in audio codec comes with certain price. For example, computing complexity of neural network audio codec is quite large compared with DSP-based audio codec, and deployment is rather complicated since model inference needs support of neural network inference tools.
[0048] In the related arts, audio codecs have been developed for decades. These codecs can efficiently encode common audio such as speech and music, support various sampling rates, and the encoding and decoding process is also real-time and efficient.
[0049] The neural network based audio codecs have been developing since 2019, most of them can be divided into three parts: encoder, decoder and vector quantization. LPCNet only encodes and decodes speech, therefore it is not in the category of general audio codecs and will not be discussed later. SoundStream, Encoder, and Penguin are all general audio codecs with similar time domain network structure, all of them choose to introduce GAN in training pipeline and better results (subjective scores and objective scores) is achieved compared with traditional codecs. The following is a general description of these schemes:
[0050] SoundStream is a novel neural audio codec that can efficiently compress speech, music and general audio at bitrates normally targeted by speech-tailored codecs. The model is composed of a fully convolutional encoder / decoder network and a residual vector quantizer. The detailed block diagram is shown below.
[0051] FIG. 1a shows a schematic diagram of a novel neural audio codec according to some embodiments.
[0052] In FIG. 1a, the encoder architecture is illustrated and follows the same structure as the streaming SEANet encoder, but without skip connections. It consists of a ID convolution layer (with Cenc channels) , followed by Benc convolution blocks. Each of the blocks consists of three residual units, containing dilated convolutions with dilation rates of 1, 3, and 9, respectively, followed by a down-sampling layer in the form of a strided convolution. The number of channels is doubled whenever down-sampling, starting from Cenc. A final 1D convolution layer with a kernel of length 3 and a stride of 1 is used to set the dimensionality of the embeddings to D. To guarantee real-time inference, all convolutions are causal. This means that padding is only applied to the past but not the future in both training and offline inference, whereas no padding is used in streaming inference. The ELU activation is used and any normalization is not applied. The number Benc of convolution blocks and the corresponding striding sequence determines the temporal resampling ratio between the input waveform and the embeddings. For example, when Benc= 4 and using (2, 4, 5, 8) as strides, one embedding is computed every M = 2·4·5·8=320 input samples. Thus, the encoder outputs enc (x) =RS×D with S = T / M.
[0053] The decoder architecture follows a similar design, as illustrated in FIG. 1a. A 1D convolution layer is followed by a sequence of Bdec convolution blocks. The decoder block mirrors the encoder block, and consists of a transposed convolution for up-sampling followed by the same three residual units. The same strides is used as the encoder, but in reverse order, to reconstruct a waveform with the same resolution as the input waveform. The number of channels is halved whenever up-sampling, so that the last decoder block outputs Caec channels. A final 1D convolution layer with one filter, a kernel of size 7 and stride 1 projects the embeddings back to the waveform domain to produce In FIG. 1a, the same number of channels in both the encoder and the decoder is controlled by the same parameter, i.e., Cenc = Cdec = C. The cases is also investigate in which Cenc ≠ Cdee, which results in a computationally lighter encoder and a heavier decoder, or vice-versa.
[0054] The 24kHz audio signal is converted to a 75Hz embedding after encoder. This embedding is quantized with a vector quantizer. However, original vector quantizer is not applicable here because the size of codebook would be huge even for low bitrate. For example, target bit rate is 6kbps, if a plain vector quantizer is used, the required codebook size is 2^80, which is obviously unfeasible. To address this issue, SoundStream adopt a Residual Vector Quantizer, which cascades N layers of VQ to reduce the size of single codebook. If N is set to 8 for the above example, each VQ only needs a codebook of size 1024.
[0055] Furthermore, SoundStream proposed a method to train multi-bitrate simultaneously. A dropout scheme is introduced in RVQ to randomly use first M quantizer. When M is set to 5 for the above example, final bit rate of bitstream is 3kbps, which means 3kbps and 6bps is training simultaneously.
[0056] FIG. 1b shows a schematic diagram of a novel neural audio codec according to other embodiments.
[0057] In FIG. 1b, Encodec is also a CNN based encoder, decoder model similar to SoundStream, extra LSTM is introduced in encoder and decoder for better temporal modeling. In addition, a transformer-based entropy coding is introduced after RVQ, which further improving the compression ratio. Encodec can encode and decode audio at 24kHz and 48kHz.
[0058] Penguin is still fully convolutional networks for time-domain signal. Audio signals will be preprocessed before sending to the model, it will be split into low-band and high-band, low-band will go through their model to get quantized indexes, and audio features is extracted from high-band signal and transmitted along with indexes. Their quantization module consists of scalar quantization and entropy coding for lower bit rate.
[0059] During the training of the three models mentioned above, discriminators are introduced and the reconstruction quality of audio signal is greatly improved.
[0060] FIG. 2a shows schematic diagram of an audio processing system according to some embodiments of the present disclosure.
[0061] In FIG. 2a, an audio processing system is proposed to replaced the input of encoder from time domain signals to frequency domain features. Basic block for encoder and decoder have been converted to ConV2D from ConV1D. The benefits gained is showed from this replacement.
[0062] Based on the information mentioned above, it can be concluded the following framework for neural network audio codec, codebook mentioned in 3.2 is both stored in encoder and decoder, encoder and decoder are both neural networks deployed with neural network inference tools. Transmission is supposed to be lossless for this framework, error correction is required if lossy transmission is considered, this is not considered in this invention.
[0063] There are 5 stages in neural network audio codec:
[0064] FIG. 2b shows schematic diagram of an audio processing system according to some embodiments of the present disclosure.
[0065] In FIG. 2b, Stage1 is feature extraction: it is used to extract audio features from audio signals. Feature extraction do nothing in a time-domain audio codec, in frequency-domain audio codec, it is a traditional STFT module.
[0066] Stage2 is the encoding process: it contains inference of encoder and vectorization of latent generated by encoder. The main blocks in encoder is ConV1D in time-domain audio codec and ConV2D in frequency-domain audio codec. Pre-trained codebooks are used here to get indices of each latent in each vector quantizer, so the size of bitstream is much smaller since it is a series of indices rather than vectors. Usually indices is limited by a certain range, 1024 for examples, so only 10 bits is needed to encode single index.
[0067] Stage3 is the transmission process: bitstream of indices if transferred using network or media device, this process is supposed to be loss-less in this invention.
[0068] Stage4 is the decoding process: it contains inference of decoder and de-vectorization of indices. The main blocks in decoder is ConV1D in time-domain audio codec and ConV2D in frequency-domain audio codec. Same codebook as the one mentioned in Stage2 is used here to extract z_q using indices.
[0069] Stage5 is the feature converter: it is used to generated recovered audio using features generated by decoder. Feature converter do nothing in a time-domain audio codec, in frequency-domain audio codec, it is a traditional ISTFT module.
[0070] Residual vector quantization is an important part in audio codec. The goal of the quantizer is to compress the output of the encoder to a target bitrate R, expressed in bits / seconds (bps) . Usually the size of indices is much smaller than the size of tensors, therefore a much smaller bitstream can be transferred with less bandwidth. The codebook of vector quantizer can be learned during training of neural audio codec in an end-to-end fashion.
[0071] RVQ cascades Nq layers of VQ and is called multi-stage vector quantizer. The input vector is passed through the first VQ and quantization residuals are computed, the residuals are the iteratively quantized by a sequence of additional Nq-1 layers.
[0072] For example, the algorithm of RVQ may be implemented with the following:
[0073] If developing a codec with bitrate R = 6000bps from 24000kHz audio with stride 320, the shape of input vector is 75 × feature_dims. This corresponds to r = 6000 / 75 = 80 bits allocated to each frame. For a plain VQ, the codebook size is N=280, which is obviously unfeasible.
[0074] But if replacing this plain VQ with a RVQ with Nq=8, each VQ uses a codebook of size Total size of codebook is reduced from N=280 to Nq*N=8192.
[0075] The quality of RVQ is important for the reconstruction quality of neural audio codecs, so properly training methods should be chosen. There are two typical methods to train RVQ.
[0076] For example, the EMA update of each codebook in RVQ includes:
[0077] is the number of vectors in E (x) in the mini-batch that are quantized to codebook item ei, , and γ is a decay parameter with a value between 0 and 1 (default γ = 0.99 is used in experiments) . For example, the released VQ-VAE implementation may be used in the Sonnet library.
[0078] For example, the codebook loss may be:
[0079] The quality of RVQ can be measured by codebook usage, which mean how well each entry is utilized in RVQ, however there is no specific metric to measure this. Therefore, perplexity is introduced here to approximate the overall codebook usage of a RVQ.
[0080] Calculation of perplexity (Shape of input is [batch_size, num_frames, embedding_dims] ) :
[0081] i. Find indices for input using distance function (cosine similarity or euclidean distance) , min_encoding_indices is a tensor of integer with shape [batch_size × num_frames] .
[0082] ii. Given min_encoding_indices, the number of occurrence of each index can be calculated, for example, index 0 is chosen 7 times, index 3 is chosen 38 times ... And probability can be calculated by divide counts with total number.
[0083] iii. Calculate perplexity using following function:
[0084] MPEG-ACoM (audio coding for machines) has been introduced in WG6 which aims to define a bitstream and data format for compressing audio, multi-dimensional streams, or features extracted from such signals that is efficient in terms of bitrate / size and can be used by a network of machines after decompression to perform multiple tasks without significantly degrading task performance.
[0085] According to the definition above, 11 use cases related to ACoM has been identified. Potential ACoM architecture and its requirements is also listed in the document. In order to further prove the feasibility of ACoM, a possible system which shows benefits on efficiency of compression of bitstream and performs well in downstream tasks is demonstrated.
[0086] Given the 11 use cases, four tasks can be concluded from our perspective: Automatic Speech Recognition, Speaker Verification and Speaker Diarization and Sound Event Detection. Datasets and related metrics used in those tasks are listed below: Table 1
[0087] Sound Event Detection is chosen as the evaluation task in this report because most user cases are related to it. There are lots of datasets suitable for the training of sound event detection models, Audio Set is the most famous one and it consists of an expanding ontology of 632 audio event classes and a collection of 2, 084, 320 human-labeled 10-second sound clips drawn from YouTube videos. Those sound clips are encoded by YouTube and should be viewed as lossy representation of original sound, however, it can be found that when audio is retrieved, an option called "-bestaudio" is added to ensure that the bitrate of most audio files is above 128kbps. Those sound clips are encoded and decoded with AAC at different bps (16k, 32k, etc) and evaluated mAP using the same classification model, There is a relationship between bps and mAP -the lower bps used, the lower mAP got. So AudioSet is not perfect but sufficient for our evaluation.
[0088] There exists a lot of pre-trained models (PANNs, AST, MAE, BEATs) based on Audio Set which could be used directly as downstream tasks for the evaluation of ACoM system. Although MAE and BEATs achieve higher mAP on the evaluation dataset provided by AudioSet, they require fine-tuning on specific datasets after training, meaning that the feature they extract can only be used in a single situation. After examining their model structure, It is more suitable to use them as a feature extraction model. Therefore, Ultimately chosing PANNs as our evaluation model, as it is also more straightforward to re-train the PANNs model if new features are used rather than Log-Mel feature.
[0089] FIG. 3 shows schematic diagram of a neural audio codec and its downstream tasks in Codec-SUPERB.
[0090] Referring to FIG. 3, although neural audio codec could be used to compress audio for transmission and decompress audio for downstream machine learning tasks without certain degradation on performance, it requires reconstruction of original audio which is not always a good practice in case of privacy. Meanwhile, the computation budget introduced by the decoder will make it much hard to deploy this system on edge devices. Therefore, a general audio feature is required which could be used directly by multiple downstream tasks.
[0091] For example. neural audio codec is proposed to be developed in frequency domain and the reconstruction quality of audio can be improved by using new residual vector quantization. The neural audio codec is suggested to be trained as mentioned above and only use the encoder part of neural audio codec and quantization module to get audio latent features for downstream tasks, this is also a possible solution for ACoM.
[0092] Referring to FIG. 2a, the dimension of input feature changes form 3D [batch_size, channels, samples] to 4D [batch_size, channels, frequency, frames] since frequency-domain feature is uesed instead of time-domain signal. ConV1D is not sufficient and ConV2D is used instead. The encoder keeps reducing dimension of frequency domain by using stride of 2 while keeping frames the same by using stride of 1. So number of frequency bins is halved after each Downsample, and final number of frequency bins is only 1 / 16 of original ones. ResNetBlock is added to increase the depth of the model. Two additional ResNetBlock layers are added to process extracted features. And a final ConV2D is used before output the features to RVQ to adjust its channels. Latent z is obtained after encoder, and it is not suitable for transmission before quantization. A normal RVQ is applied here same as Encodec / SoundStream for better comparison, its codebooks (e) are update using EMA. After RVQ, latent z is converted into latent z_q, z_q will be transmitted to the decoder side for spectral reconstruction. The decoder adopts a symmetric structure to the encoder, where the downsample module in the encoder is replaced with the upsample module in the decoder. Finally, ISTFT is applied to get time domain signal for further usage.
[0093] FIG. 4a-4b show schematic diagrams of an audio processing system according to other embodiments of the present disclosure.
[0094] In FIG. 4a-4b, Stage1 becomes extract frequency-domain features using STFT and Stage5 becomes recover time-domain signal using ISTFT, detailed implementation is listed with those blocks marked as red, extra STFT and ISTFT modules are added before encoder and after decoder.
[0095] For example, as shown in FIG. 4a, the parameters of the time-domain audio comprise: dimension = channels × num_samples, mono: channels = 1, stereo: channels = 2, num_samples = samplerate × durations, samplerate: 16khz, 22.05kHz, 24kHz, 32kHz, 44.1khz..., durations: audio length measured in seconds; fully conventionally encoder extracts latent z, and num_samples is reduced into latent_dims using parameter called stride in each conv layer; the parameters of the latent z comprise: dimension = channels × num_frame ×latent_dims, num_frames is calculated with encoder's paramater: stride, and typical value for latent_dims is 128, 256, 512.
[0096] For example, as shown in FIG. 4b, the parameters of the latent z_q comprise: dimension = channels × num_frame × latent_dims, num_frames is calculated with encoder's paramater: stride, and typical value for latent_dims is 128, 256, 512; the decoder may be a Conv2D based model; the parameters of the recovered time-domain audio comprise: dimension = channels × num_samples, mono channels =1, stereo channels = 2; num_samples = samplerate × durations, samplerate: 16khz, 22.05kHz, 24kHz, 32kHz, 44.1khz..., durations: audio length measured in seconds.
[0097] It can be find that the proposed model always work on frequency domain. Spectrum has several advantages over time domain signal, it usually contains more information about fundamental frequencies and their harmonics, its adjacent frames usually contains similar feature and is more suitable for compression. Therefore, frequency domain signals are more suitable for audio codec.
[0098] The time domain and frequency domain losses are simultaneously adopted to jointly optimize the reconstruction quality of the spectrum. The time domain part is L1 Loss, and the frequency domain part is multi-resolution STFT loss. Three fft sizes are used, namely 1024, 2048, and 512. The RVQ part ensures the latent converges to codebook with additional commitment loss. Since our model works on frequency domain, extra ISTFT is need before apply time domain loss. loss= (ltime+lfreq) *weightreconstruction+lcommitment*weightcommit ltime=L1Loss () (WAVtarget, ISTFT (STFTrecover) ) ) lfreq=MultiResolutionSTFTLoss (fftsize= (1024, 2048, 512) (STFTtarget, STFTrecover) where sg is the stop gradient sign.
[0099] Setting weightreconstructionto 20 and weightcommitto 1 can best balance reconstruction quality and quantization error. So it is proposed to replace the Balancer and previous weights used in soundstream weightreconstruction=1 to this new value for frequency-domain neural audio codec.
[0100] Two discriminators are uesd simultaneously, one of them works in time domain and the other in the frequency domain. The time domain discriminator is trained to distinguish the reconstructed signal from original signal, and the frequency domain discriminator is trained to distinguish the complex spectrum of reconstructed signal from original signal using different FFT size.
[0101] Codebooks are updated as following for traditional RVQ:
[0102] is the number of vectors in E (x) in the mini-batch that are quantized to codebook item ei, , and γ is a decay parameter with a value between 0 and 1 (default γ = 0.99 is used in experiments) . For example, the released VQ-VAE implementation may be used in the Sonnet library.
[0103] The problem is not every codebook item ei will be updated. Each vector in the mini-batch will be used to update the codebook item with minimum distance to it, there will be a number of dead codes in traditional RVQ, which leads to low codebook usage and degrades reconstruction quality.
[0104] A simple yet useful methods is to reset dead code in RVQ's codebook with sample vectors from current mini-batch. It is needed to count how long each code has not been used, for example, the a codebook in RVQ is a tensor with shape [num_embeddings, embedding_dims] , a tensor named D with shape [num_embeddings] is created with integer values. Di means how long the vector codebooki has not been used. If Di exceeds our threshold = 2, the vector may be reset with input vector randomly sampled from the mini-batch.
[0105] The RVQ1 improved neural audio codec performance a lot compared with original VQVAE, however, its PESQ value is still lower than auto encoder. To tackle this problem, it is proposed to use a technique called factorization which greatly improve reconstruction quality with slightly increase on computational budget.
[0106] FIG. 5a shows schematic diagrams of an audio processing system.
[0107] FIG. 5b shows schematic diagrams of an audio processing system according to other embodiments of the present disclosure.
[0108] In FIG. 5b, The input of RVQ is z of shape nembedding*dembedding, dembedding is usually large and it is proposed to do factorization on it to reduce feature dimension of codebook so that higher codebook usage is possible. A projection layer is introduced before input latent into RVQ, so the shape of zfactorizaion becomes nembedding*dembedding / factorizaionfactor. And another projection layer is introduced before output layer to convert zfactorizaionto zwith original shape. This process may be gained improvement on image coding.
[0109] It is also useful for frequency-domain neural audio codec especially for factorization factor 4. For example, input dimension is 256, after projection layer, dimension becomes 64 and after codebook lookup stage, it is converted back to 256 using another projection layer.
[0110] The following is an exemplary illustration, using some embodiments, of how to provide a general audio feature for the processing of downstream tasks.
[0111] FIG. 6a shows a flow diagram of an audio processing method according to some embodiments of the present disclosure.
[0112] As shown in FIG. 6a, in step 110, first feature information of an audio signal is extracted, using an encoder. For example, the encoder includes a pre-trained machine learning model configured to obtain the first feature information based on the audio signal.
[0113] In step 120, the first feature information is quantized to obtain quantized feature information, the size of the quantized feature information being smaller than the size of the audio signal.
[0114] In step 130, the quantized feature information is provided to a downstream task processor to allow the downstream task processor to perform an audio processing based on the quantized feature information. For example, the audio processing includes at least one of sound event detection or speech recognition.
[0115] Thus, on the one hand, the feature information of the audio signal can be extracted by the encoder to provide a unified processing basis for the downstream task, which improves the efficiency of the audio processing; on the other hand, there is no need to transmit a larger original audio signal to the downstream task processor, and the audio processing can be accomplished by transmitting only a smaller feature information, which reduces the demand of the channel resources and improves the efficiency of the audio processing.
[0116] The following is an exemplary illustration, using some embodiments, of how the feature extraction in step 110 may be implemented.
[0117] In some embodiments, the audio signal is a time-domain audio signal, the time-domain audio signal is converted to a frequency-domain audio signal; and the first feature information of the frequency-domain audio signal is extracted, using the encoder.
[0118] In some embodiments, the encoder includes a machine learning model, performing a two-dimensional convolution process on the frequency-domain audio signal using the encoder; processing the frequency-domain audio signal using a residual network block of the encoder; or performing a down sampling process on the frequency-domain audio signal using the encoder.
[0119] In some embodiments, the encoder includes a machine learning model, performing a first two-dimensional convolution process, a first residual network block process, a down sampling process, a second residual network block process, and a second two-dimensional convolution process, in sequence, on the frequency-domain audio signal, using the encoder.
[0120] The following is an exemplary illustration, using some embodiments, of how the quantizing process in step 120 may be implemented.
[0121] In some embodiments, performing a quantizing process on the first feature information according to a codebook; and generating a bitstream as the quantized feature information according to a result of the quantizing process. For example, RVQ in any embodiment above may quantize the first feature information use codebook and generate a bitstream with much smaller size than the original audio.
[0122] Thus, there is no need to transmit a larger original audio signal to the downstream task processor, and the audio processing can be accomplished by transmitting only a smaller bitstream, which reduces the demand of the channel resources and improves the efficiency of the audio processing.
[0123] In some embodiments, the encoder includes a machine learning model configured to obtain the first feature information based on the audio signal, the codebook being determined during a training process of the machine learning model. For example, a pre-trained model is used as a feature extractor. After training, the parameters of all the modules in encoder and decoder, codebooks in RVQ are frozen.
[0124] Thus, the codebook for quantization can be determined in the training phase, which improves the efficiency of the audio processing.
[0125] In some embodiments, projecting the first feature information into a second feature information, where a number of dimensions of the second feature information is less than a number of dimensions of the first feature information; and quantizing the second feature information to obtain the quantized feature information.
[0126] In some embodiments, projecting the first feature information into the second feature information according to a factorization factor, the number of dimensions of the second feature information being determined according to the factorization factor. For example, the factorization factor may be 4 so that the input dimension is 256, after projection layer, dimension becomes 64 and after codebook lookup stage, it is converted back to 256 using another projection layer.
[0127] Thus, the amount of data to be transmitted by the encoder is further reduced, which reduces the demand of the channel resources and improves the efficiency of the audio processing.
[0128] The following is an exemplary illustration, using some embodiments, of how the providing process in step 130 may be implemented.
[0129] In some embodiments, sending the quantized feature information to a decoder, to allow the decoder to provide the downstream task processor with the first feature information after decompressing the quantized feature information into the first feature information.
[0130] For example, the bitstream may be transferred to the decoder and decompressed to the first feature information given codebooks to be used in downstream tasks. The first feature information may be used by multiple tasks like sound event detection and automatic speech recognition.
[0131] Thus, the feature information of the audio signal can be extracted by the encoder to provide a unified processing basis for the downstream task, which improves the efficiency of the audio processing.
[0132] In the following, using the embodiments in FIG. 6b, it is exemplarily illustrated how to a general audio feature for the processing of downstream tasks.
[0133] FIG. 6b shows schematic diagrams of an audio processing system according to other embodiments of the present disclosure.
[0134] In FIG. 6b, a pre-trained model is used as a feature extractor. After training, the parameters of all the modules in encoder and decoder, codebooks in RVQ may be frozen. The encoder may be used to extract related features, while RVQ may quantize this feature use codebook and generate a bitstream with much smaller size than the original audio. This bitstream may be transferred to the decoder and decompressed to features given codebooks to be used in downstream tasks. This feature could be used by multiple tasks like sound event detection and automatic speech recognition.
[0135] FIG. 7 shows schematic diagrams of an audio processing system according to other embodiments of the present disclosure.
[0136] The performance on sound event detection is evaluated. The performance of proposed system is also evaluated according the evaluation approach described in FIG. 7, AAC (Advanced Audio Codec) is chosen as our anchor system.
[0137] FIG. 8 shows schematic diagrams of mAP for three systems.
[0138] In FIG. 8, mAP is tested as different bitrate for neural audio codec (bd_acom 8a) , neural audio codec serve as feature extractor (bd_acom_enc 8c, proposed system) and aac 8b. Although bd_acom_enc performs worse than bd_acom in 32kbps and 16kbps, indicating that further improvement is needed, it performs better than aac in 16kbps and demonstrates its potential for ACoM (considering lower bit rate and privacy protection) .
[0139] FIG. 9 shows a block diagram of an electronic device according to other embodiments of the present disclosure.
[0140] As shown in FIG. 9, the electronic device 9 includes: a memory 91 and a processor 92 coupled to the memory 91, the processor 92 configured to, based on instructions stored in the memory 91, carry out the method according to any one of the embodiments of the present disclosure.
[0141] Where, the memory 91 may include, for example, system memory, a fixed non-transitory storage medium, or the like. The system memory stores, for example, an operating system, applications, a boot loader, a database, and other programs.
[0142] FIG. 10 shows a block diagram of the electronic device according to further embodiments of the present disclosure.
[0143] As shown in FIG. 10, the electronic device 10 of the embodiments includes: a memory 1010 and a processor 1020 coupled to the memory 1010, the processor 1020 configured to, based on instructions stored in the memory 1010, carry out the method according to any one of the embodiments of the present disclosure.
[0144] The memory 1010 may include, for example, system memory, a fixed non-transitory storage medium, or the like. The system memory stores, for example, an operating system, application programs, a boot loader, and other programs.
[0145] The electronic device 10 for generating the fitness regimen information may further include an input-output interface 1030, a network interface 1040, a storage interface 1050, and the like. These interfaces 1030, 1040, 1050, the memory 1010 and the processor 1020 may be connected through a bus 1060, for example. Where, the input-output interface 1030 provides a connection interface for input-output devices such as a display, a mouse, a keyboard, a touch screen, a microphone, a loudspeaker, etc. The network interface 1040 provides a connection interface for various networked devices. The storage interface 1050 provides a connection interface for external storage devices such as an SD card and a USB flash disk.
[0146] FIG. 11 shows a block diagram of an audio processing apparatus according to some embodiments of the present disclosure;
[0147] As shwon in FIG. 11, an audio processing apparatus 11 comprising: an extracting module 111 configured to extract, using an encoder, first feature information of an audio signal; a quantizing module 112 configured to quantize the first feature information to obtain quantized feature information, the size of the quantized feature information being smaller than the size of the audio signal; and a sending module 113 configured to provide the quantized feature information to a downstream task processor to allow the downstream task processor to perform an audio processing based on the quantized feature information.
[0148] In some embodiments, the sending module 113 sends the quantized feature information to a decoder , to allow the decoder to provide the downstream task processor with the first feature information after decompressing the quantized feature information into the first feature information.
[0149] In some embodiments, the audio processing includes at least one of sound event detection or speech recognition.
[0150] In some embodiments, the quantizing module 112 performs a quantizing process on the first feature information according to a codebook; and generating a bitstream as the quantized feature information according to a result of the quantizing process.
[0151] In some embodiments, the encoder includes a machine learning model configured to obtain the first feature information based on the audio signal, the codebook being determined during a training process of the machine learning model.
[0152] In some embodiments, the quantizing module 112 projects the first feature information into a second feature information, where a number of dimensions of the second feature information is less than a number of dimensions of the first feature information; and quantizing the second feature information to obtain the quantized feature information.
[0153] In some embodiments, the quantizing module 112 projects the first feature information into the second feature information according to a factorization factor, the number of dimensions of the second feature information being determined according to the factorization factor.
[0154] In some embodiments, the audio signal is a time-domain audio signal, and the extracting module 111 converts the time-domain audio signal to a frequency-domain audio signal; and extracting, using the encoder, the first feature information of the frequency-domain audio signal.
[0155] In some embodiments, the encoder includes a machine learning model, and the extracting module 111 performs at least one of followings: performing a two-dimensional convolution process on the frequency-domain audio signal using the encoder; processing the frequency-domain audio signal using a residual network block of the encoder; or performing a down sampling process on the frequency-domain audio signal using the encoder.
[0156] In some embodiments, the encoder includes a machine learning model, and the extracting module 111 performs a first two-dimensional convolution process, a first residual network block process, a down sampling process, a second residual network block process, and a second two-dimensional convolution process, in sequence, on the frequency-domain audio signal, using the encoder.
[0157] FIG. 12 shows a block diagram of an audio processing system according to other embodiments of the present disclosure.
[0158] As shown in FIG. 12, an audio processing system 12, including: an audio signal processing apparatus 121 be configured to implement an audio signal processing method according to any one of the above embodiments; and a downstream task processor 122 be configured to perform an audio processing based on quantized feature information provided by the audio signal processing apparatus.
[0159] According to still other embodiments of the present disclosure, there is provided an electronic device, including: a processor; a memory for storing processor executable instructions; where the processor is used to read the executable instructions from the memory and execute the instructions to implement an audio processing method, an audio signal encoding method, or an audio signal decoding method according to any one of the above embodiments.
[0160] According to still other embodiments of the present disclosure, there is provided a computer-readable storage medium having stored thereon a computer program that, when executed by a processor, implements an audio processing method, an audio signal encoding method, or an audio signal decoding method according to any one of the above embodiments.
[0161] According to still other embodiments of the present disclosure, there is provided a computer program product, including: instructions that, when executed by a processor, cause the processor to implement an audio processing method, an audio signal encoding method, or an audio signal decoding method according to any one of the above embodiments.
[0162] Those skilled in the art should understand that the embodiments of the present disclosure may be provided as a method, a system, or a computer program product. Therefore, embodiments of the present disclosure can take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment containing both hardware and software elements. Moreover, the present disclosure may take the form of a computer program product embodied on one or more computer-usable non-transitory storage media (including but not limited to disk storage, CD-ROM, optical memory, etc. ) having computer-usable program code embodied therein.
[0163] Heretofore, the method, apparatus device, computer-readable storage medium and computer program product according to the present disclosure have been described in detail. In order to avoid obscuring the concepts of the present disclosure, some details known in the art are not described. Based on the above description, those skilled in the art can understand how to implement the technical solutions disclosed herein.
[0164] The method and system of the present disclosure may be implemented in many ways. For example, the method and system of the present disclosure may be implemented by software, hardware, firmware, or any combination of software, hardware, and firmware. The above sequence of steps of the method is merely for the purpose of illustration, and the steps of the method of the present disclosure are not limited to the above-described specific order unless otherwise specified. In addition, in some embodiments, the present disclosure may also be implemented as programs recorded in a recording medium, which include machine-readable instructions for implementing the method according to the present disclosure. Thus, the present disclosure also covers a recording medium storing programs for executing the method according to the present disclosure.
[0165] Although some specific embodiments of the present disclosure have been described in detail by way of example, those skilled in the art should understand that the above examples are only for the purpose of illustration and are not intended to limit the scope of the present disclosure. It should be understood by those skilled in the art that the above embodiments may be modified without departing from the scope and spirit of the present disclosure.The scope of the disclosure is defined by the following claims.
Claims
1.An audio processing method comprising:extracting, using an encoder, first feature information of an audio signal;quantizing the first feature information to obtain quantized feature information, the size of the quantized feature information being smaller than the size of the audio signal; andproviding the quantized feature information to a downstream task processor to allow the downstream task processor to perform an audio processing based on the quantized feature information.2.The audio processing method according to claim 1, wherein the providing the quantized feature information to the downstream task processor comprises:sending the quantized feature information to a decoder , to allow the decoder to provide the downstream task processor with the first feature information after decompressing the quantized feature information into the first feature information.3.The audio processing method according to claim 2, wherein the audio processing comprises at least one of sound event detection or speech recognition.4.The audio processing method according to any one of claims 1 to 3, wherein the quantizing the first feature information to obtain the quantized feature information, comprises:performing a quantizing process on the first feature information according to a codebook; andgenerating a bitstream as the quantized feature information according to a result of the quantizing process.5.The audio processing method according to claim 4, wherein the encoder comprises a machine learning model configured to obtain the first feature information based on the audio signal, the codebook being determined during a training process of the machine learning model.6.The audio processing method according to any one of claims 1 to 5, wherein the quantizing the first feature information to obtain the quantized feature information comprises:projecting the first feature information into a second feature information, wherein a number of dimensions of the second feature information is less than a number of dimensions of the first feature information; andquantizing the second feature information to obtain the quantized feature information.7.The audio processing method according to claim 6, wherein the projecting the first feature information into the second feature information comprising:projecting the first feature information into the second feature information according to a factorization factor, the number of dimensions of the second feature information being determined according to the factorization factor.8.The audio processing method according to any one of claims 1 to 7, wherein the audio signal is a time-domain audio signal, andthe extracting, using the encoder, the first feature information of the audio signal comprises:converting the time-domain audio signal to a frequency-domain audio signal; andextracting, using the encoder, the first feature information of the frequency-domain audio signal.9.The audio processing method according to claim 8, wherein the encoder comprises a machine learning model, andthe extracting, using the encoder, the first feature information of the frequency-domain audio signal comprises at least one of followings:performing a two-dimensional convolution process on the frequency-domain audio signal using the encoder;processing the frequency-domain audio signal using a residual network block of the encoder; orperforming a down sampling process on the frequency-domain audio signal using the encoder.10.The audio processing method according to claim 8, wherein the encoder comprises a machine learning model, andthe extracting, using the encoder, the first feature information of the frequency-domain audio signal comprises:performing a first two-dimensional convolution process, a first residual network block process, a down sampling process, a second residual network block process, and a second two-dimensional convolution process, in sequence, on the frequency-domain audio signal, using the encoder.11.An audio processing apparatus comprising:an extracting module configured to extract, using an encoder, first feature information of an audio signal;a quantizing module configured to quantize the first feature information to obtain quantized feature information, the size of the quantized feature information being smaller than the size of the audio signal; anda sending module configured to provide the quantized feature information to a downstream task processor to allow the downstream task processor to perform an audio processing based on the quantized feature information.12.An audio processing system, comprising:an audio processing apparatus be configured to implement an audio processing method of any one of claims 1 to 10; anda downstream task processor be configured to perform an audio processing based on quantized feature information provided by the audio processing apparatus.13.An electronic device, comprising:a processor;a memory for storing processor executable instructions;wherein the processor is used to read the executable instructions from the memory and execute the instructions to implement an audio processing method of any one of claims 1 to 10.14.A computer readable storage medium storing thereon a computer program that, when executed by a processor, causes the processor to implement an audio processing method of any one of claims 1 to 10.15.A computer program product, comprising:instructions that, when executed by a processor, cause the processor to implement an audio processing method of any one of claims 1 to 10.
Citation Information
Patent Citations
Voice data processing method and device, computer equipment and storage medium
CN113823296A
Audio encoding device and method, and audio decoding device and method
CN116324979A
End-to-end speech coding method and system based on vector prediction and fusion technology
CN117672237A
Audio processing method and device, storage medium and electronic equipment
CN118136030A
System and method for digital steganography purification
US20210192019A1