1. A method for image scanning by an electronic device, comprising: obtaining an image pyramid comprising a plurality of scale levels and at least a first pyramid level for a frame; providing a scanning window; and scanning at least two of the plurality of scale levels of the frame at a plurality of scanning window locations, wherein a number of scanning window locations is equal for each scale level of the at least two scale levels of the first pyramid level.