CN110211610A - Assess the method, apparatus and storage medium of audio signal loss - Google Patents

Assess the method, apparatus and storage medium of audio signal loss Download PDF

Info

Publication number
CN110211610A
CN110211610A CN201910537059.7A CN201910537059A CN110211610A CN 110211610 A CN110211610 A CN 110211610A CN 201910537059 A CN201910537059 A CN 201910537059A CN 110211610 A CN110211610 A CN 110211610A
Authority
CN
China
Prior art keywords
signal
audio
compression
audio signal
original
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910537059.7A
Other languages
Chinese (zh)
Inventor
房树明
王健宗
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN201910537059.7A priority Critical patent/CN110211610A/en
Publication of CN110211610A publication Critical patent/CN110211610A/en
Priority to PCT/CN2019/117908 priority patent/WO2020253054A1/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/27Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 characterised by the analysis technique
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/48Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 specially adapted for particular use
    • G10L25/69Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 specially adapted for particular use for evaluating synthetic or decoded voice signals

Landscapes

  • Engineering & Computer Science (AREA)
  • Computational Linguistics (AREA)
  • Signal Processing (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • Acoustics & Sound (AREA)
  • Multimedia (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

The present invention relates to field of voice signal, it is proposed a kind of method, apparatus and storage medium for assessing audio signal loss, method therein is applied to electronic device, comprising: carries out compression processing to original audio signal, obtains audio compression signal corresponding with the original audio signal;Processing is unziped it to the audio compression signal, obtains audio decompression signal corresponding with the audio compression signal;Obtain the cosine similarity between the audio decompression signal and the original audio signal;According to cosine similarity, the grading system of the original audio signal loss is obtained.The present invention is by establishing general voice signal evaluation rule, the extent of damage of assessment audio signal during processing, convenient for the analysis and judgement to audio signal.

Description

Assess the method, apparatus and storage medium of audio signal loss
Technical field
The present invention relates to speech signal processing technology more particularly to a kind of methods for assessing audio signal loss, dress It sets and computer readable storage medium.
Background technique
In the transmission of audio, the field of signal processing such as speech synthesis, which have, is widely answered for the compression and decompression processing of audio With.Wherein, the audio compression techniques based on μ-law or a-law are common audio compression algorithms, such as μ-law (or Mu- Law) it is standard multimedia digital signal coding and decoding device (compression/de-compression) algorithm for pulse-code modulation.As one kind The method of companding, μ-law can improve S/N rate without increasing more data.
But although audio and original audio after μ-law compression algorithm decompresses again have very high similarity, That is μ-law, which compresses, can sufficiently high signal fidelity, but the loss of still unavoidable signal, to signal processing mistake Cheng Zhong cannot clearly obtain the degree of the loss of signal, will affect analysis and judgement to signal processing results.
Therefore, how to carry out assessment to the extent of damage of audio signal during processing is asking for current urgent need to resolve Topic.
Summary of the invention
The present invention provides a kind of method, electronic device and computer readable storage medium for assessing audio signal loss, Main purpose is the grading system lost by original audio signal, clearly obtains the loss of audio signal during processing Degree, code of points are simply applicable in, and versatility is high.
To achieve the above object, the present invention provides a kind of method for assessing audio signal loss, is applied to electronic device, institute The method of stating includes:
Compression processing is carried out to original audio signal, obtains audio compression signal corresponding with the original audio signal;
Processing is unziped it to the audio compression signal, obtains audio decompression corresponding with the audio compression signal Signal;
Obtain the cosine similarity between the audio decompression signal and the original audio signal;
According to the cosine similarity, the grading system of the original audio signal loss is obtained.
Preferably, described that compression processing is carried out to original audio signal, obtain sound corresponding with the original audio signal The step of frequency compressed signal includes:
Compression processing, the formula of the compression processing are carried out to the original audio signal according to μ-law algorithm are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and x indicates that the original audio signal, F (x) indicate the audio Compressed signal, sgn are sign function.
Preferably, described that processing is unziped it to the audio compression signal, it obtains and the audio compression signal pair The step of audio decompression signal answered includes:
Processing, the formula of the decompression are unziped it to the audio compression signal according to μ-law algorithm are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and y indicates the audio compression signal, F-1(y) sound is indicated Frequency decompression signal, sgn is sign function.
Preferably, the meter for obtaining the cosine similarity between the audio decompression signal and the original audio signal Calculate formula are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
Preferably, the calculation formula of the grading system for obtaining the original audio signal loss are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is the audio decompression signal and the original audio signal Between cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
To achieve the above object, the present invention also provides a kind of electronic device, which includes: memory and processing Device includes the program of assessment audio signal loss in the memory, and the program of the assessment audio signal loss is by the place Reason device realizes following steps when executing:
Compression processing is carried out to original audio signal, obtains audio compression signal corresponding with the original audio signal;
Processing is unziped it to the audio compression signal, obtains audio decompression corresponding with the audio compression signal Signal;
Obtain the cosine similarity between the audio decompression signal and the original audio signal;
According to the cosine similarity, the grading system of the original audio signal loss is obtained.
Preferably, described that compression processing is carried out to original audio signal, obtain sound corresponding with the original audio signal The step of frequency compressed signal includes:
Compression processing, the formula of the compression processing are carried out to the original audio signal according to μ-law algorithm are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and x indicates that original audio signal, F (x) indicate audio compression letter Number, sgn is sign function.
Preferably, described that processing is unziped it to the audio compression signal, it obtains and the audio compression signal pair The step of audio decompression signal answered includes:
Processing, the formula of the decompression are unziped it to the audio compression signal according to μ-law algorithm are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and y indicates audio compression signal, F-1(y) audio decompression letter is indicated Number, sgn is sign function.
Preferably, the meter for obtaining the cosine similarity between the audio decompression signal and the original audio signal Calculate formula are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
To achieve the above object, the present invention also provides a kind of computer readable storage medium, the computer-readable storages It include the program of assessment audio signal loss in medium, it is real when the program of the assessment audio signal loss is executed by processor The method and step of audio signal loss is now assessed as described above.
Method, electronic device and the computer readable storage medium of assessment audio signal loss proposed by the present invention, pass through It obtains to the original audio signal cosine similarity that treated between audio decompression signal and original audio signal, described in acquisition The grading system of original audio signal loss, can be to the loss amount of progress of audio signal during processing by grading system Change, loss of signal degree can be specified, and correctly signal processing results are analyzed and judged.
Detailed description of the invention
Fig. 1 is the application environment schematic diagram of the method specific embodiment of present invention assessment audio signal loss;
Fig. 2 is the module diagram that the program specific embodiment of audio signal loss is assessed in Fig. 1;
Fig. 3 is the flow chart of the method specific embodiment of present invention assessment audio signal loss.
The embodiments will be further described with reference to the accompanying drawings for the realization, the function and the advantages of the object of the present invention.
Specific embodiment
It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, it is not intended to limit the present invention.
The present invention provides a kind of method for assessing audio signal loss, is applied to a kind of electronic device 1.Shown in referring to Fig.1, For the application environment schematic diagram of the method preferred embodiment of present invention assessment audio signal loss.
In the present embodiment, electronic device 1 can be server, smart phone, tablet computer, portable computer, on table Type computer etc. has the terminal device of calculation function.
The electronic device 1 includes: processor 12, memory 11, network interface 14 and communication bus 15.
Memory 11 includes the readable storage medium storing program for executing of at least one type.The readable storage medium storing program for executing of at least one type It can be the non-volatile memory medium of such as flash memory, hard disk, multimedia card, card-type memory 11.In some embodiments, described Readable storage medium storing program for executing can be the internal storage unit of the electronic device 1, such as the hard disk of the electronic device 1.At other In embodiment, the readable storage medium storing program for executing is also possible to the external memory 11 of the electronic device 1, such as the electronic device The plug-in type hard disk being equipped on 1, intelligent memory card (Smart Media Card, SMC), secure digital (Secure Digital, SD) block, flash card (Flash Card) etc..
In the present embodiment, the readable storage medium storing program for executing of the memory 11 is installed on the electronic device commonly used in storage The program 10 etc. of 1 assessment audio signal loss.The memory 11, which can be also used for temporarily storing, to have exported or has incited somebody to action The data to be exported.
Processor 12 can be in some embodiments a central processing unit (Central Processing Unit, CPU), microprocessor or other data processing chips, program code or processing data for being stored in run memory 11, example Such as execute the program 10 of assessment audio signal loss.
Network interface 14 optionally may include standard wireline interface and wireless interface (such as WI-FI interface), be commonly used in Communication connection is established between the electronic device 1 and other electronic equipments.
Communication bus 15 is for realizing the connection communication between these components.
Fig. 1 illustrates only the electronic device 1 with component 11-15, it should be understood that being not required for implementing all show Component out, the implementation that can be substituted is more or less component.
Optionally, which can also include user interface, and user interface may include input unit such as keyboard (Keyboard), speech input device such as microphone (microphone) etc. has the equipment of speech identifying function, voice defeated Device such as sound equipment, earphone etc. out, optionally user interface can also include standard wireline interface and wireless interface.
Optionally, which can also include display, and display is referred to as display screen or display unit. It can be light-emitting diode display, liquid crystal display, touch-control liquid crystal display and Organic Light Emitting Diode in some embodiments (Organic Light-Emitting Diode, OLED) touches device etc..Display is used to show and handle in the electronic apparatus 1 Information and for showing visual user interface.
Optionally, which further includes touch sensor.It is touched provided by the touch sensor for user The region for touching operation is known as touch area.In addition, touch sensor described here can be resistive touch sensor, capacitor Formula touch sensor etc..Moreover, the touch sensor not only includes the touch sensor of contact, proximity may also comprise Touch sensor etc..In addition, the touch sensor can be single sensor, or such as multiple biographies of array arrangement Sensor.
In addition, the area of the display of the electronic device 1 can be identical as the area of the touch sensor, it can also not Together.Optionally, display and touch sensor stacking are arranged, to form touch display screen.The device is based on touching aobvious Display screen detects the touch control operation of user's triggering.
Optionally, which can also include radio frequency (Radio Frequency, RF) circuit, sensor, audio Circuit etc., details are not described herein.
In Installation practice shown in Fig. 1, as may include in a kind of memory 11 of computer storage medium behaviour Make system and assesses the program 10 of audio signal loss;Processor 12 executes the assessment audio signal stored in memory 11 Following steps are realized when the program 10 of loss:
Firstly, carrying out compression processing to original audio signal, audio compression corresponding with the original audio signal is obtained Signal.
In this step, audio compression refers mainly to use number appropriate to original digital audio signal stream (pcm encoder) Signal processing technology, do not lose useful information amount or it is introduced loss it is insignificant under the conditions of, reduce (compression) its code rate, Also referred to as compressed encoding.It must have corresponding inverse transformation, referred to as decompress or decode, and audio signal is passing through a volume solution A large amount of noise and certain distortion may be introduced after code system, using appraisal procedure of the invention, can be existed to audio signal The extent of damage in treatment process carries out quantitative evaluation.
Then, processing is unziped it to the audio compression signal, obtains sound corresponding with the audio compression signal Frequency decompression signal.
In this step, with the development of computer multimedia technology, the data processing amount of audio signal increasingly increases, for up to To improve audio signal transmission rate, reduce signal bandwidth, and reduce audio signal memory space the purpose of, to original Audio signal carries out high proportion compression, and making it easier to actual use seems particularly significant.And decompressing (Decompression) is The inverse process of compression is the appearance being restored to one by various things such as document, the files of Software Compression before compression.
Then, the cosine similarity between the audio decompression signal and the original audio signal is obtained.
Wherein, the calculating for obtaining the cosine similarity between the audio decompression signal and the original audio signal Formula are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
Finally, obtaining the grading system of the original audio signal loss according to the cosine similarity.
Wherein, the calculation formula of the grading system are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is the audio decompression signal and the original audio signal Between cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
The method of assessment audio signal loss of the invention will be carried out detailed with μ-law algorithm as a specific example below It is thin to illustrate.Specifically includes the following steps:
Step 1: carrying out compression processing to original audio signal according to μ-law algorithm, obtain and the original audio signal Corresponding audio compression signal.
In this step, the formula of compression processing is carried out to original audio signal are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and in international standard, μ value 255, x indicates the original sound Frequency signal, F (x) indicate the audio compression signal, and sgn is sign function.
Step 2 unzips it processing to the audio compression signal according to μ-law algorithm, obtains and the audio pressure The corresponding audio decompression signal of contracting signal.
In this step, the formula of processing is unziped it to the audio compression signal are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and in international standard, μ value 255, y indicates the audio pressure Contracting signal, F-1(y) the audio decompression signal is indicated, sgn is sign function.
Step 3 obtains the cosine similarity between audio decompression signal and original audio signal.
Cosine similarity calculation formula is as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
Step 4 obtains former according to the cosine similarity between the audio decompression signal and the original audio signal The grading system of beginning audio signal loss.
Obtain the grading system calculation formula of the original audio signal loss are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is the audio decompression signal and the original audio signal Between cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
The method of the above-mentioned assessment μ-law algorithm loss of signal is equally applicable to a-law etc. to audio signal In the algorithm of reason, in general, audio compression techniques can be divided into lossless (lossless) compression and damage (lossy) compression Two major classes, and according to the difference of compression scheme, and time domain data compression, transformation compression, subband compression and a variety of can be divided into Mixing compression that technology mutually merges etc..A variety of different compress techniques, complexity (including the time complexity of algorithm And space complexity), audio quality, efficiency of algorithm (i.e. compression factor) and encoding and decoding delay etc. be all very different.Respectively The application of kind compress technique is also therefore different.
Wherein, time domain data compression (or being waveform coding) technology, is handled directly against the sample value of audio pcm stream, Code stream is compressed by means such as mute detection, nonlinear quantization, difference.The common feature of such compress technique is algorithm Complexity is low, and sound quality is general, and compression ratio is small (CD Quality > 400kbps), and encoding and decoding are delayed most short (relatively other technologies). Such compress technique is generally chiefly used in compress speech, the occasion of low bit- rate application (source signal bandwidth is small).Time domain data compression technology master It to include that G.711 (G.711 the audio coding mode formulated by International Telecommunication Union (ITU-T), also known as ITU-T, are divided into Alaw and ulaw), ADPCM, LPC, CELP, and the block the companding technology such as NICAM, subband that grow up in these technologies ADPCM (SB-ADPCM) technology.
Below by taking the sample rate 8k of one section of 1ms, bit is the audio signals of 16bit as an example, illustrate the assessment of the loss of signal Process.
If original audio signal X=[2203,0,233,24011,1,7,400,2903].
Step 1: the original audio signal of 16bit is converted to 8bit according to following compression processing formula.
Wherein, μ is the companding parameter for indicating compression degree, and in international standard, μ value 255, x indicates that 16bit's is original Audio signal X, F (x) indicate the audio compression signal, and sgn is sign function.
Obtain X1=F (x)=[194,128,151,248,128,129,160,200].
Step 2: the audio compression signal of 8bit is switched to 16bit according to following decompression formula.
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, in international standard, μ value 255, y=X1, sgn is symbol Function.
Obtain audio decompression signal X2=F-1(y)=[2188,0,228,24133,2,8,399,2879].
Third step obtains X and X2Between cosine similarity.
Wherein, A=X, B=X2, n=1.
4th step, according to X and X2Between cosine similarity, obtain the grading system of original audio signal:
S=5* (1-cos θ)
Wherein, S is grading system, and 5 be full marks grade, and the numerical value of S is bigger, shows that the loss of audio signal is smaller.
In other embodiments, the program 10 for assessing audio signal loss can also be divided into one or more mould Block, one or more module are stored in memory 11, and are executed by processor 12, to complete the present invention.Institute of the present invention The module of title is the series of computation machine program instruction section for referring to complete specific function.Referring to shown in Fig. 2, to be assessed in Fig. 1 The Program modual graph of 10 preferred embodiment of program of audio signal loss.
As shown in Fig. 2, the program 10 of the assessment audio signal loss can be divided into:
Compression processing unit 11 obtains and the original audio signal for carrying out compression processing to original audio signal Corresponding audio compression signal.
Decompression processing unit 12 obtains and the audio pressure for unziping it processing to the audio compression signal The corresponding audio decompression signal of contracting signal.
Similarity acquiring unit 13, for obtaining the cosine between the audio decompression signal and the original audio signal Similarity.
Score unit 14, for obtaining the grading system of the original audio signal loss according to the cosine similarity.
In addition, the present invention also provides a kind of methods for assessing audio signal loss.Referring to shown in Fig. 3, for present invention assessment The flow chart of the method preferred embodiment of audio signal loss.This method can be executed by a device, which can be by soft Part and/or hardware realization.
In the present embodiment, the method for assessing audio signal loss includes:
Step S110: compression processing is carried out to original audio signal, obtains audio corresponding with the original audio signal Compressed signal.
In this step, audio compression refers mainly to use number appropriate to original digital audio signal stream (pcm encoder) Signal processing technology, do not lose useful information amount or it is introduced loss it is insignificant under the conditions of, reduce (compression) its code rate, Also referred to as compressed encoding.It must have corresponding inverse transformation, referred to as decompress or decode, and audio signal is passing through a volume solution A large amount of noise and certain distortion may be introduced after code system, using appraisal procedure of the invention, can be existed to audio signal The extent of damage in treatment process is assessed.
Step S120: processing is unziped it to the audio compression signal, is obtained corresponding with the audio compression signal Audio decompression signal.
In this step, with the development of computer multimedia technology, the data processing amount of audio signal increasingly increases, for up to To improve audio signal transmission rate, reduce signal bandwidth, and reduce audio signal memory space the purpose of, to original Audio signal carries out high proportion compression, and making it easier to actual use seems particularly significant.And decompressing (Decompression) is The inverse process of compression is the appearance being restored to one by various things such as document, the files of Software Compression before compression.
Step S130: the cosine similarity between the audio decompression signal and the original audio signal is obtained.
Wherein, the calculating for obtaining the cosine similarity between the audio decompression signal and the original audio signal Formula are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
Step S140: according to the cosine similarity, the grading system of the original audio signal loss is obtained.
Wherein, the calculation formula of the grading system for obtaining the original audio signal loss are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is the audio decompression signal and the original audio signal Between cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
The method of assessment audio signal loss of the invention will be carried out detailed with μ-law algorithm as a specific example below It is thin to illustrate.Specifically includes the following steps:
Step 1: carrying out compression processing to original audio signal according to μ-law algorithm, obtain and the original audio signal Corresponding audio compression signal.
In this step, the formula of compression processing is carried out to original audio signal are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and in international standard, μ value 255, x indicates the original sound Frequency signal, F (x) indicate the audio compression signal, and sgn is sign function.
Step 2 unzips it processing to the audio compression signal according to μ-law algorithm, obtains and the audio pressure The corresponding audio decompression signal of contracting signal.
In this step, the formula of processing is unziped it to the audio compression signal are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and in international standard, μ value 255, y indicates the audio pressure Contracting signal, F-1(y) the audio decompression signal is indicated, sgn is sign function.
Step 3 obtains the cosine similarity between audio decompression signal and original audio signal.
Cosine similarity calculation formula is as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
Step 4 obtains former according to the cosine similarity between the audio decompression signal and the original audio signal The grading system of beginning audio signal loss.
Grading system calculation formula are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is the audio decompression signal and the original audio signal Between cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
The method of the above-mentioned assessment μ-law algorithm loss of signal is equally applicable to a-law etc. to audio signal In the algorithm of reason, in general, audio compression techniques can be divided into lossless (lossless) compression and damage (lossy) compression Two major classes, and according to the difference of compression scheme, and time domain data compression, transformation compression, subband compression and a variety of can be divided into Mixing compression that technology mutually merges etc..A variety of different compress techniques, complexity (including the time complexity of algorithm And space complexity), audio quality, efficiency of algorithm (i.e. compression factor) and encoding and decoding delay etc. be all very different.Respectively The application of kind compress technique is also therefore different.
Wherein, time domain data compression (or being waveform coding) technology, is handled directly against the sample value of audio pcm stream, Code stream is compressed by means such as mute detection, nonlinear quantization, difference.The common feature of such compress technique is algorithm Complexity is low, and sound quality is general, and compression ratio is small (CD Quality > 400kbps), and encoding and decoding are delayed most short (relatively other technologies). Such compress technique is generally chiefly used in compress speech, the occasion of low bit- rate application (source signal bandwidth is small).Time domain data compression technology master It to include that G.711 (G.711 the audio coding mode formulated by International Telecommunication Union (ITU-T), also known as ITU-T, are divided into Alaw and ulaw), ADPCM, LPC, CELP, and the block the companding technology such as NICAM, subband that grow up in these technologies ADPCM (SB-ADPCM) technology.
Below by taking the sample rate 8k of one section of 1ms, bit is the audio signals of 16bit as an example, illustrate the assessment of the loss of signal Process.
If original audio signal X=[2203,0,233,24011,1,7,400,2903].
Step 1: the original audio signal of 16bit is converted to 8bit according to following compression processing formula.
Wherein, μ is the companding parameter for indicating compression degree, and in international standard, μ value 255, x indicates that 16bit's is original Audio signal X, F (x) indicate the audio compression signal, and sgn is sign function.
Obtain X1=F (x)=[194,128,151,248,128,129,160,200].
Step 2: the audio compression signal of 8bit is switched to 16bit according to following decompression formula.
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, in international standard, μ value 255, y=X1, sgn is symbol Function.
Obtain audio decompression signal X2=F-1(y)=[2188,0,228,24133,2,8,399,2879].
Third step obtains X and X2Between cosine similarity.
Wherein, A=X, B=X2, n=1.
4th step, according to X and X2Between cosine similarity, obtain the grading system of original audio signal:
S=5* (1-cos θ)
Wherein, S is grading system, and 5 be full marks grade, and S numerical value is bigger, shows the loss of audio signal during processing It is smaller.
The method of assessment audio signal loss proposed by the present invention, by obtaining to original audio signal treated audio The cosine similarity between signal and original audio signal is decompressed, the grading system of original audio signal loss is obtained, by commenting Graduation can quantify the loss of audio signal during processing, can specify the damage of audio signal during processing Mistake degree, and correctly signal processing results are analyzed and judged.
In addition, the embodiment of the present invention also proposes a kind of computer readable storage medium, the computer readable storage medium In include assessment audio signal loss program, the program of the assessment audio signal loss realizes such as when being executed by processor Lower operation:
Compression processing is carried out to original audio signal, obtains audio compression signal corresponding with the original audio signal;
Processing is unziped it to the audio compression signal, obtains audio decompression corresponding with the audio compression signal Signal;
Obtain the cosine similarity between the audio decompression signal and the original audio signal;
According to the cosine similarity, the grading system of the original audio signal loss is obtained.
Preferably, described that compression processing is carried out to original audio signal, obtain sound corresponding with the original audio signal The step of frequency compressed signal includes:
Compression processing, the formula of the compression processing are carried out to the original audio signal according to μ-law algorithm are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and x indicates that the original audio signal, F (x) indicate the audio Compressed signal, sgn are sign function.
Preferably, described that processing is unziped it to the audio compression signal, it obtains and the audio compression signal pair The step of audio decompression signal answered includes:
Processing, the formula of the decompression are unziped it to the audio compression signal according to μ-law algorithm are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and y indicates the audio compression signal, F-1(y) sound is indicated Frequency decompression signal, sgn is sign function.
Preferably, the meter for obtaining the cosine similarity between the audio decompression signal and the original audio signal Calculate formula are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
Preferably, the calculation formula of the grading system are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is the audio decompression signal and the original audio signal Between cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
The method of the specific embodiment of the computer readable storage medium of the present invention and above-mentioned assessment audio signal loss, The specific embodiment of electronic device is roughly the same, and details are not described herein.
It should be noted that, in this document, the terms "include", "comprise" or its any other variant are intended to non-row His property includes, so that the process, device, article or the method that include a series of elements not only include those elements, and And further include other elements that are not explicitly listed, or further include for this process, device, article or method institute it is intrinsic Element.In the absence of more restrictions, the element limited by sentence "including a ...", it is not excluded that including being somebody's turn to do There is also other identical elements in the process, device of element, article or method.
The serial number of the above embodiments of the invention is only for description, does not represent the advantages or disadvantages of the embodiments.Pass through above embodiment party The description of formula, it is required general that those skilled in the art can be understood that above-described embodiment method can add by software The mode of hardware platform is realized, naturally it is also possible to which by hardware, but in many cases, the former is more preferably embodiment.It is based on Such understanding, substantially the part that contributes to existing technology can be with software product in other words for technical solution of the present invention Form embody, which is stored in a storage medium (such as ROM/RAM, magnetic disk, light as described above Disk) in, including some instructions use is so that a terminal device (can be mobile phone, computer, server or the network equipment Deng) execute method described in each embodiment of the present invention.
The above is only a preferred embodiment of the present invention, is not intended to limit the scope of the invention, all to utilize this hair Equivalent structure or equivalent flow shift made by bright specification and accompanying drawing content is applied directly or indirectly in other relevant skills Art field, is included within the scope of the present invention.

Claims (10)

1. a kind of method for assessing audio signal loss, is applied to electronic device, which is characterized in that the described method includes:
Compression processing is carried out to original audio signal, obtains audio compression signal corresponding with the original audio signal;
Processing is unziped it to the audio compression signal, obtains audio decompression letter corresponding with the audio compression signal Number;
Obtain the cosine similarity between the audio decompression signal and the original audio signal;
According to the cosine similarity, the grading system of the original audio signal loss is obtained.
2. the method for assessment audio signal loss according to claim 1, which is characterized in that described to original audio signal Carry out compression processing, obtain audio compression signal corresponding with the original audio signal the step of include:
Compression processing, the formula of the compression processing are carried out to the original audio signal according to μ-law algorithm are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and x indicates that the original audio signal, F (x) indicate the audio compression Signal, sgn are sign function.
3. the method for assessment audio signal loss according to claim 1, which is characterized in that described to the audio compression The step of signal unzips it processing, obtains audio decompression signal corresponding with the audio compression signal include:
Processing, the formula of the decompression are unziped it to the audio compression signal according to μ-law algorithm are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and y indicates the audio compression signal, F-1(y) the audio solution is indicated Signal is pressed, sgn is sign function.
4. the method for assessment audio signal loss according to claim 1, which is characterized in that described to obtain the audio solution Press the calculation formula of the cosine similarity between signal and the original audio signal are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
5. the method for assessment audio signal loss according to claim 1, which is characterized in that described to obtain the original sound The calculation formula of the grading system of the frequency loss of signal are as follows:
S=M* (1-cos θ)
Wherein, S is grading system, and M is full marks grade, and cos θ is between the audio decompression signal and the original audio signal Cosine similarity, the numerical value of S is bigger, shows that the loss of audio signal is smaller.
6. a kind of electronic device, which is characterized in that the electronic device includes: memory and processor, includes in the memory The program of audio signal loss is assessed, the program of the assessment audio signal loss realizes following step when being executed by the processor It is rapid:
Compression processing is carried out to original audio signal, obtains audio compression signal corresponding with the original audio signal;
Processing is unziped it to the audio compression signal, obtains audio decompression letter corresponding with the audio compression signal Number;
Obtain the cosine similarity between the audio decompression signal and the original audio signal;
According to the cosine similarity, the grading system of the original audio signal loss is obtained.
7. electronic device according to claim 6, which is characterized in that it is described that compression processing is carried out to original audio signal, Obtain audio compression signal corresponding with the original audio signal the step of include:
Compression processing, the formula of the compression processing are carried out to the original audio signal according to μ-law algorithm are as follows:
Wherein, μ is the companding parameter for indicating compression degree, and x indicates that original audio signal, F (x) indicate audio compression signal, sgn For sign function.
8. electronic device according to claim 6, which is characterized in that described to be unziped it to the audio compression signal Processing, obtain audio decompression signal corresponding with the audio compression signal the step of include:
Processing, the formula of the decompression are unziped it to the audio compression signal according to μ-law algorithm are as follows:
F-1(y)=sgn (y) (1/ μ) ((1+ μ)|y|-1)-1≤y≤1
Wherein, μ is the companding parameter for indicating compression degree, and y indicates audio compression signal, F-1(y) audio decompression signal is indicated, Sgn is sign function.
9. electronic device according to claim 6, which is characterized in that described to obtain the audio decompression signal and the original The calculation formula of cosine similarity between beginning audio signal are as follows:
Wherein, A is original audio signal, and B is audio decompression signal, and n is the number of corresponding signal.
10. a kind of computer readable storage medium, which is characterized in that include assessment audio in the computer readable storage medium When the program of the program of the loss of signal, the assessment audio signal loss is executed by processor, realize as in claim 1 to 5 The method and step of described in any item assessment audio signal loss.
CN201910537059.7A 2019-06-20 2019-06-20 Assess the method, apparatus and storage medium of audio signal loss Pending CN110211610A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201910537059.7A CN110211610A (en) 2019-06-20 2019-06-20 Assess the method, apparatus and storage medium of audio signal loss
PCT/CN2019/117908 WO2020253054A1 (en) 2019-06-20 2019-11-13 Method and apparatus for evaluating audio signal loss, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910537059.7A CN110211610A (en) 2019-06-20 2019-06-20 Assess the method, apparatus and storage medium of audio signal loss

Publications (1)

Publication Number Publication Date
CN110211610A true CN110211610A (en) 2019-09-06

Family

ID=67793737

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910537059.7A Pending CN110211610A (en) 2019-06-20 2019-06-20 Assess the method, apparatus and storage medium of audio signal loss

Country Status (2)

Country Link
CN (1) CN110211610A (en)
WO (1) WO2020253054A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110942782A (en) * 2019-12-10 2020-03-31 北京搜狗科技发展有限公司 Voice compression method, voice decompression method, voice compression device, voice decompression device and electronic equipment
WO2020253054A1 (en) * 2019-06-20 2020-12-24 平安科技(深圳)有限公司 Method and apparatus for evaluating audio signal loss, and storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050143974A1 (en) * 2002-01-24 2005-06-30 Alexandre Joly Method for qulitative evaluation of a digital audio signal
US20060280313A1 (en) * 2004-02-19 2006-12-14 Christian Schmidmer Method and device for quality evaluation of an audio signal and device and method for obtaining a quality evaluation result
WO2011129655A2 (en) * 2010-04-16 2011-10-20 Jeong-Hun Seo Method, apparatus, and program-containing medium for assessment of audio quality
CN102496369A (en) * 2011-12-23 2012-06-13 中国传媒大学 Objective assessment method for audio quality of compressed domain based on distortion correction
CN102881289A (en) * 2012-09-11 2013-01-16 重庆大学 Hearing perception characteristic-based objective voice quality evaluation method
US20160329061A1 (en) * 2014-01-07 2016-11-10 Harman International Industries, Incorporated Signal quality-based enhancement and compensation of compressed audio signals
WO2016189307A1 (en) * 2015-05-26 2016-12-01 Sonalytic Limited Audio identification method
CN108021635A (en) * 2017-11-27 2018-05-11 腾讯科技(深圳)有限公司 The definite method, apparatus and storage medium of a kind of audio similarity
CN109451331A (en) * 2019-01-15 2019-03-08 西安电子科技大学 Video transmission method based on user cognition demand

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3942831B2 (en) * 2001-02-06 2007-07-11 三菱電機株式会社 Voice communication terminal and voice communication system
US7505897B2 (en) * 2005-01-27 2009-03-17 Microsoft Corporation Generalized Lempel-Ziv compression for multimedia signals
CN102214462B (en) * 2011-06-08 2012-11-14 北京爱说吧科技有限公司 Method and system for estimating pronunciation
CN105139857B (en) * 2015-09-02 2019-03-22 中山大学 For the countercheck of voice deception in a kind of automatic Speaker Identification
CN107910014B (en) * 2017-11-23 2021-11-09 苏州科达科技股份有限公司 Echo cancellation test method, device and test equipment
CN110211610A (en) * 2019-06-20 2019-09-06 平安科技(深圳)有限公司 Assess the method, apparatus and storage medium of audio signal loss

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050143974A1 (en) * 2002-01-24 2005-06-30 Alexandre Joly Method for qulitative evaluation of a digital audio signal
US20060280313A1 (en) * 2004-02-19 2006-12-14 Christian Schmidmer Method and device for quality evaluation of an audio signal and device and method for obtaining a quality evaluation result
WO2011129655A2 (en) * 2010-04-16 2011-10-20 Jeong-Hun Seo Method, apparatus, and program-containing medium for assessment of audio quality
CN102496369A (en) * 2011-12-23 2012-06-13 中国传媒大学 Objective assessment method for audio quality of compressed domain based on distortion correction
CN102881289A (en) * 2012-09-11 2013-01-16 重庆大学 Hearing perception characteristic-based objective voice quality evaluation method
US20160329061A1 (en) * 2014-01-07 2016-11-10 Harman International Industries, Incorporated Signal quality-based enhancement and compensation of compressed audio signals
WO2016189307A1 (en) * 2015-05-26 2016-12-01 Sonalytic Limited Audio identification method
CN108021635A (en) * 2017-11-27 2018-05-11 腾讯科技(深圳)有限公司 The definite method, apparatus and storage medium of a kind of audio similarity
CN109451331A (en) * 2019-01-15 2019-03-08 西安电子科技大学 Video transmission method based on user cognition demand

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
晏寄夫: "《MCU及接口技术实验教程》", 30 September 2012 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2020253054A1 (en) * 2019-06-20 2020-12-24 平安科技(深圳)有限公司 Method and apparatus for evaluating audio signal loss, and storage medium
CN110942782A (en) * 2019-12-10 2020-03-31 北京搜狗科技发展有限公司 Voice compression method, voice decompression method, voice compression device, voice decompression device and electronic equipment

Also Published As

Publication number Publication date
WO2020253054A1 (en) 2020-12-24

Similar Documents

Publication Publication Date Title
CN101305423B (en) Adaptive time/frequency-based audio encoding and decoding apparatuses and methods
CN112767954B (en) Audio encoding and decoding method, device, medium and electronic equipment
CN101421780B (en) Method and device for encoding and decoding time-varying signal
KR101634134B1 (en) System, method, and computer program product for decompression of block compressed images
CN108595443A (en) Simultaneous interpreting method, device, intelligent vehicle mounted terminal and storage medium
CN101447792B (en) Method for encoding/decoding digital signal with transposition codes
CN101894547A (en) Speech synthesis method and system
HK1060632A1 (en) Method and device for producing a fingerprint and method and device for identifying an audio signal
CN103177726A (en) Classification of audio signals
CN110211610A (en) Assess the method, apparatus and storage medium of audio signal loss
CN104036788B (en) The acoustic fidelity identification method of audio file and device
KR20120031950A (en) Compression coding and decoding method, coder, decoder, and coding device
US9886962B2 (en) Extracting audio fingerprints in the compressed domain
CN110097895B (en) Pure music detection method, pure music detection device and storage medium
TW201813321A (en) Method and device for arithmetic encoding or arithmetic decoding
Huang et al. Lossless audio compression in the new IEEE standard for advanced audio coding
CN113903345A (en) Audio processing method and device and electronic device
CN115116458B (en) Voice data conversion method, device, computer equipment and storage medium
CN102655006A (en) Voice transmission device and voice transmission method
JP2023552451A (en) Encoding methods, devices, electronic equipment and storage media
DE60200519D1 (en) Method and device for distributed speech recognition
CN111816197B (en) Audio encoding method, device, electronic equipment and storage medium
CA2368453A1 (en) Using gain-adaptive quantization and non-uniform symbol lengths for audio coding
CN116668691A (en) Picture compression transmission method and device and terminal equipment
CN101454829B (en) Method and apparatus to search fixed codebook and method and appratus to encode/decode a speech signal using the method and apparatus to search fixed codebook

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20190906

RJ01 Rejection of invention patent application after publication