A method for controlling a robotic cleaner, the method comprises: acquiring an environment image of an area; determining a sub-area to be swept in the area based on the environment image; and controlling the robotic cleaner to reach the sub-area and perform a sweeping task in the sub-area, characterized in that determining the sub-area to be swept in the area based on the environment image comprises: comparing the environment image with one or more pre-stored reference images, wherein the pre-stored reference images correspond to different spatial areas of the area and the pre-stored reference images are images of the spatial areas in a clean state; selecting a target reference image from the one or more reference images that matches the environment image, wherein a spatial area corresponding to the target reference image and a spatial area corresponding to the environment image are similar and a difference between pixels of an image block in the environment image and pixels of an image block corresponding to a same coordinate and in the clean state in the target reference image exceeds a preset difference value; determining a spatial area corresponding to the target reference image based on a first mapping correspondence between the reference images and the spatial areas; and taking the spatial area corresponding to the target reference image as the sub-area to be swept in the area. acquiring an environment image of an area; determining a sub-area to be swept in the area based on the environment image; and controlling the robotic cleaner to reach the sub-area and perform a sweeping task in the sub-area, characterized in that determining the sub-area to be swept in the area based on the environment image comprises: comparing the environment image with one or more pre-stored reference images, wherein the pre-stored reference images correspond to different spatial areas of the area and the pre-stored reference images are images of the spatial areas in a clean state; selecting a target reference image from the one or more reference images that matches the environment image, wherein a spatial area corresponding to the target reference image and a spatial area corresponding to the environment image are similar and a difference between pixels of an image block in the environment image and pixels of an image block corresponding to a same coordinate and in the clean state in the target reference image exceeds a preset difference value; determining a spatial area corresponding to the target reference image based on a first mapping correspondence between the reference images and the spatial areas; and taking the spatial area corresponding to the target reference image as the sub-area to be swept in the area. comparing the environment image with one or more pre-stored reference images, wherein the pre-stored reference images correspond to different spatial areas of the area and the pre-stored reference images are images of the spatial areas in a clean state; selecting a target reference image from the one or more reference images that matches the environment image, wherein a spatial area corresponding to the target reference image and a spatial area corresponding to the environment image are similar and a difference between pixels of an image block in the environment image and pixels of an image block corresponding to a same coordinate and in the clean state in the target reference image exceeds a preset difference value; determining a spatial area corresponding to the target reference image based on a first mapping correspondence between the reference images and the spatial areas; and <EOS>