1. A computer-implemented method for filtering noise in an image using an electronic device comprising a processor, the method comprising execution of the steps comprising: obtaining a current image and a background image from a storage device using the processor; calculating a discrepant block between the current image and the background image upon the condition that a background list of the current image is not null using the processor; filtering each specified pixel of the discrepant block using the processor, a difference value between each specified pixel in the discrepant block and a corresponding pixel in the background image being less than a first preset value; filtering each small block of the discrepant block using the processor, an area of each small block being less than a second preset value; calculating a total area of each big block of the discrepant block using the processor, an area of each big block being greater than or equal to the second preset value; and adding the current image being filtered to the background list upon the condition that the total area is less than a third preset value using the processor.