A robot vacuum cleaner comprising: a camera; a memory configured to store an artificial intelligence model trained to identify an image from an input image, shape information corresponding to each of a plurality of objects, and information on an object to be avoided; and a processor configured to control the electronic apparatus by being connected to the camera and the memory, wherein the processor is further configured to: input an image obtained by the camera to the artificial intelligence model to identify an object included in the image, obtain shape information corresponding to the identified object among the shape information stored in the memory, and characterized in that based on the identified object corresponding to the object to be avoided based on the information, identify whether the identified object is an object causing contamination based on the shape information, based on the identified object corresponding to the object to be avoided or the identified object corresponding to an object causing contamination, set a traveling path of the robot vacuum cleaner based on the shape information and size information related to the object, and based on the identified object not corresponding to the object to be avoided or the identified object not corresponding to the object causing contamination, set the traveling path to climb the identified object. a camera; a memory configured to store an artificial intelligence model trained to identify an image from an input image, shape information corresponding to each of a plurality of objects, and information on an object to be avoided; and a processor configured to control the electronic apparatus by being connected to the camera and the memory, wherein the processor is further configured to: input an image obtained by the camera to the artificial intelligence model to identify an object included in the image, obtain shape information corresponding to the identified object among the shape information stored in the memory, and characterized in that based on the identified object corresponding to the object to be avoided based on the information, identify whether the identified object is an object causing contamination based on the shape information, based on the identified object corresponding to the object to be avoided or the identified object corresponding to an object causing contamination, set a traveling path of the robot vacuum cleaner based on the shape information and size information related to the object, and based on the identified object not corresponding to the object to be avoided or the identified object not corresponding to the object causing contamination, set the traveling path to climb the identified object. input an image obtained by the camera to the artificial intelligence model to identify an object included in the image, obtain shape information corresponding to the identified object among the shape information stored in the memory, and characterized in that based on the identified object corresponding to the object to be avoided based on the information, identify whether the identified object is an object causing contamination based on the shape information, based on the identified object corresponding to the object to be avoided or the identified object corresponding to an object causing contamination, set a traveling path of the robot vacuum cleaner based on the shape information and size information related to the object, and based on the identified object not corresponding to the object to be avoided or the identified object not corresponding to the object causing contamination, set the traveling path to climb the identified object.