Noise detection methods, electronic devices and storage media

By using window mode and audio data normalization, and employing moving averages to detect noise, this method solves the false alarm problem of existing noise detection algorithms in music and sports programs, achieving fast and accurate noise detection.

CN117877526BActive Publication Date: 2026-05-26HANGZHOU ARCVIDEO TECHNOLOGY CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
HANGZHOU ARCVIDEO TECHNOLOGY CO LTD
Filing Date
2023-12-22
Publication Date
2026-05-26

Smart Images

  • Figure CN117877526B_ABST
    Figure CN117877526B_ABST
Patent Text Reader

Abstract

This invention discloses a noise detection method, electronic device, and storage medium. The method includes the following steps: S10, maintaining a detection window for each channel of the input sound, and simultaneously mixing all channels of the input sound into a single channel to maintain another detection window, resulting in a detection window number of N+1, where N refers to the number of sound channels; S20, sampling and bit-leveling the input sound to normalize it, unifying all channels and the mix to the same sampling rate and bit level; S30, as new data points arrive, the moving window slides forward, and the moving average is updated in real time whenever the window slides to a new position; S40, when the new observation values ​​of more than one channel and the mix sound all exceed the minimum moving average, it is considered a popping sound occurrence point.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of audio processing technology, specifically relating to a noise detection method, electronic device, and storage medium. Background Technology

[0002] In the field of broadcasting and television, it is necessary to detect, monitor, and manage sound signals to prevent noise interference or damage to the listener's auditory experience caused by excessive volume. Existing noise detection algorithms calculate instantaneous sound intensity, and if the sound decibel level exceeds a specified threshold, it is considered noise. This results in a large number of false alarms in music and sports programs. Summary of the Invention

[0003] In view of the above-mentioned problems, the present invention provides a noise detection method, an electronic device, and a storage medium.

[0004] To solve the above-mentioned technical problems, the present invention adopts the following technical solution:

[0005] The first aspect of this invention provides a noise detection method, comprising the following steps:

[0006] S10, each channel of the input sound maintains a detection window, and at the same time, all channels of the input sound are mixed into a mono and a detection window is maintained, resulting in a detection window number of N+1, where N refers to the number of sound channels;

[0007] S20 samples and performs bit-level processing on the input sound, then normalizes it to unify all channels and mixes to the same sampling rate and bit-level.

[0008] S30: As new data points arrive, the moving window slides forward, and the moving average is updated in real time whenever the window slides to a new position.

[0009] S40, when new observations of more than one channel and the mixed sound all exceed the minimum moving average, is considered the point where a pop occurs.

[0010] In one possible implementation, the window duration ranges from 500ms to 1000ms.

[0011] In one possible implementation, the sampling rate in S20 is 16000 or 8000, and the bit depth is 16.

[0012] In one possible implementation, the moving average in S30 is calculated as follows: the moving average is obtained by averaging all data points within the window, assuming the sound intensity of the data points within the window is X. ! ,X2,...,X n The moving average M is then calculated as follows:

[0013] In one possible implementation, the minimum moving average in S40 is greater than -2dB.

[0014] A second aspect of the present invention provides an electronic device including a memory, a processor, and program code stored in the memory and running on the processor, wherein at least one piece of program code is loaded and executed by the one or more processors to perform the operations performed by the noise detection method as described in any of the preceding claims.

[0015] A third aspect of the present invention provides a storage medium storing at least one piece of program code, which is loaded and executed by a processor to perform the operations performed by the noise detection method as described in any of the preceding claims.

[0016] The present invention offers the following advantages: by introducing windowing and sound data normalization, noise detection is achieved. Through reasonable screening and comparison thresholds, noise segments can be detected quickly. Attached Figure Description

[0017] Figure 1 This is a flowchart illustrating the steps of the noise detection method according to an embodiment of the present invention;

[0018] Figure 2 This is a schematic block diagram of an electronic device according to an embodiment of the present invention. Detailed Implementation

[0019] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0020] See Figure 1 The diagram shows a flowchart of a noise detection method according to an embodiment of the present invention, including the following steps:

[0021] S10: Each channel of the input sound maintains a detection window. Simultaneously, all channels of the input sound are mixed into a mono signal, maintaining another detection window. The total number of detection windows is N+1, where N represents the number of sound channels. The core of the moving average method is maintaining one or more moving windows. The size of the window depends on the characteristics of the input sound and the rate of signal change. Smaller windows are more sensitive to rapidly changing signals, while larger windows are more suitable for stable signals. In specific applications, a window duration range of 500ms-1000ms is recommended.

[0022] S20 performs sampling and bit-leveling on the input audio, normalizing it to unify all channels and the mix to the same sampling rate and bit depth. In specific applications, the sampling rate is 16000 or 8000, and the bit depth is 16.

[0023] S30: As new data points arrive, the moving window slides forward, and the moving average is updated in real time whenever the window slides to a new position.

[0024] S40: A pop is considered to have occurred when new observations for one or more channels and the mixed sound all exceed the minimum moving average. In a specific application example, the minimum moving average is greater than -2dB.

[0025] In another embodiment of the noise detection method of the present invention, the moving average value in S30 is calculated as follows: the moving average value is obtained by calculating the average value of all data points within the window, assuming the sound intensity of the data points within the window is X. ! ,X2,...,X n The moving average M is then calculated as follows:

[0026] The noise detection method described above, through steps such as introducing windowing mode and sound data normalization, achieves noise detection. By appropriately filtering and comparing thresholds, noise segments can be detected quickly.

[0027] Figure 2This is a schematic diagram of the structure of an electronic device 20 provided in an embodiment of this application. It includes a memory 201, a processor 202, and program code stored in the memory and running on the processor. At least one piece of program code is loaded and executed by one or more processors to implement the operations performed by the noise detection method described above. The processor 202 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 202 may be implemented in at least one hardware form selected from Digital Signal Processing (DSP), Field-Programmable Gate Array (FPGA), and Programmable Logic Array (PLA). In some embodiments, the processor 202 may integrate a Graphics Processing Unit (GPU), which is responsible for rendering and drawing the content to be displayed on the screen. In some embodiments, the processor 202 may also include an Artificial Intelligence (AI) processor for handling computational operations related to machine learning. The memory 201 may include one or more computer-readable storage media, which may be non-transitory. The memory 201 may also include high-speed random access memory and non-volatile memory, such as one or more disk storage devices or flash memory devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 201 is used to store at least one instruction, which is executed by the processor 202 to implement the noise detection method provided in the various embodiments of this application.

[0028] In an exemplary embodiment, a computer-readable storage medium is also provided, such as a memory including at least one line of program code, which can be executed by a processor in a terminal to perform the noise detection method in the above embodiments. For example, the computer-readable storage medium may be a read-only memory (ROM), a random-access memory (RAM), a compact disc read-only memory (CD-ROM), magnetic tape, floppy disk, and optical data storage device, etc.

[0029] Those skilled in the art will understand that all or part of the steps of the above embodiments can be implemented by hardware or by a program instructing related hardware. The program can be stored in a computer-readable storage medium, such as a read-only memory, a disk, or an optical disk.

[0030] It should be understood that the exemplary embodiments described herein are illustrative and not restrictive. Although one or more embodiments of the invention have been described in conjunction with the accompanying drawings, those skilled in the art will understand that various changes in form and detail may be made without departing from the spirit and scope of the invention as defined by the appended claims.

Claims

1. A noise detection method, characterized in that, Includes the following steps: S10, each channel of the input sound maintains a detection window, and at the same time, all channels of the input sound are mixed into a mono and a detection window is maintained, resulting in a detection window number of N+1, where N refers to the number of sound channels; S20 samples and performs bit-level processing on the input sound, then normalizes it to unify all channels and mixes to the same sampling rate and bit-level. S30: As new data points arrive, the moving window slides forward, and the moving average is updated in real time whenever the window slides to a new position. The moving average is calculated as follows: the moving average is obtained by averaging all data points within the window. Let the sound intensities of the data points within the window be X1, X2, ..., X... n The moving average M is then calculated as follows: ; S40, when new observations of more than one channel and the mixed sound all exceed the minimum moving average, is considered the point where a pop occurs.

2. The noise detection method as described in claim 1, characterized in that, The window duration ranges from 500ms to 1000ms.

3. The noise detection method as described in claim 1, characterized in that, The sampling rate in S20 is 16000 or 8000, and the bit depth is 16.

4. The noise detection method as described in claim 1, characterized in that, The minimum moving average in S40 is greater than -2dB.

5. An electronic device, characterized in that, It includes a memory, a processor, and program code stored in the memory and running on the processor, wherein at least one piece of program code is loaded and executed by one or more processors to perform the operations performed by the noise detection method as described in any one of claims 1 to 4.

6. A storage medium, characterized in that, The storage medium stores at least one piece of program code, which is loaded and executed by a processor to perform the operations of the noise detection method as described in any one of claims 1 to 4.