A computer-implemented method for motion estimation between a reference frame and a current frame, the reference frame corresponding to but differing from the current frame; the method comprising: determining an error between a block to be matched and each of reference blocks to obtain a plurality of errors, wherein the block to be matched is an image block in the current frame, and the reference blocks are image blocks in the reference frame; determining at least one candidate block from the reference blocks according to the plurality of errors; determining a random number range according to a displacement between the block to be matched and each of the reference blocks; obtaining random motion vectors by using a motion vector between the block to be matched and each of the at least one candidate block as a basic motion vector and random numbers within the random number range as increments; and determining a target motion vector corresponding to the block to be matched according to the random motion vectors; characterized in that obtaining the random motion vectors by using the motion vector between the block to be matched and each of the at least one candidate block as the basic motion vector and the random numbers within the random number range as the increments comprises: traversing the random number range in unit step size to obtain a plurality of sets of increments; and using the motion vector between the block to be matched and each of the at least one candidate block as the basic motion vector, and obtaining the random motion vectors according to the basic motion vector and the plurality of sets of increments. determining an error between a block to be matched and each of reference blocks to obtain a plurality of errors, wherein the block to be matched is an image block in the current frame, and the reference blocks are image blocks in the reference frame; determining at least one candidate block from the reference blocks according to the plurality of errors; determining a random number range according to a displacement between the block to be matched and each of the reference blocks; obtaining random motion vectors by using a motion vector between the block to be matched and each of the at least one candidate block as a basic motion vector and random numbers within the random number range as increments; and determining a target motion vector corresponding to the block to be matched according to the random motion vectors; characterized in that obtaining the random motion vectors by using the motion vector between the block to be matched and each of the at least one candidate block as the basic motion vector and the random numbers within the random number range as the increments comprises: traversing the random number range in unit step size to obtain a plurality of sets of increments; and using the motion vector between the block to be matched and each of the at least one candidate block as the basic motion vector, and obtaining the random motion vectors according to the basic motion vector and the plurality of sets of increments. traversing the random number range in unit step size to obtain a plurality of sets of increments; and using the motion vector between the block to be matched and each of the at least one candidate block as the basic motion vector, and obtaining the random motion vectors according to the basic motion vector and the plurality of sets of increments.