WO2020007201A1 - Picture search method and device, readable storage medium, and terminal - Google Patents

Picture search method and device, readable storage medium, and terminal Download PDF

Info

Publication number
WO2020007201A1
WO2020007201A1 PCT/CN2019/092128 CN2019092128W WO2020007201A1 WO 2020007201 A1 WO2020007201 A1 WO 2020007201A1 CN 2019092128 W CN2019092128 W CN 2019092128W WO 2020007201 A1 WO2020007201 A1 WO 2020007201A1
Authority
WO
WIPO (PCT)
Prior art keywords
picture
attribute information
information
type name
contour
Prior art date
Application number
PCT/CN2019/092128
Other languages
French (fr)
Chinese (zh)
Inventor
李媛
Original Assignee
奇酷互联网络科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 奇酷互联网络科技(深圳)有限公司 filed Critical 奇酷互联网络科技(深圳)有限公司
Publication of WO2020007201A1 publication Critical patent/WO2020007201A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data

Definitions

  • the present invention relates to the field of electronic technology, and in particular, to a picture search method, device, readable storage medium, and terminal.
  • pictures are usually searched according to the picture name, and pictures in the gallery are generally named according to the default naming rule. For example, they can be numbered sequentially or named according to the shooting time. classification. It is also possible for users to manually add picture names or modify picture names. However, due to the large number of pictures and long storage time, users tend to forget the picture name, storage date or stored in that folder. When searching, you need to preview the pictures in the gallery one by one. The search speed is very slow.
  • An image search method includes:
  • image recognition is performed on the picture to determine a type name corresponding to an object in the picture;
  • attribute information of all pictures in the gallery is queried to determine target attribute information matching the keyword;
  • the step of adding a type name corresponding to the object to attribute information of exif information of the picture includes:
  • the step of determining the priority of the object according to a preset priority rule includes:
  • the method further includes:
  • the picture is stored in the target picture folder.
  • the attribute information includes first attribute information and second attribute information
  • the step of adding a type name corresponding to the object to the attribute information of exif information of the picture includes :
  • the method further includes:
  • the tag selected by the user is added to the second attribute information of the exif information.
  • the step of displaying the tag information table on the current interface includes:
  • a plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
  • the step of performing image recognition on a picture to determine a type name corresponding to an object in the picture includes:
  • An embodiment of the present invention further provides a picture search apparatus, including:
  • An image recognition module configured to perform image recognition on a picture when a picture taken by a camera is detected to determine a type name corresponding to an object in the picture;
  • a first adding module configured to add a type name corresponding to the object to attribute information of exif information of the picture
  • a first query module configured to query attribute information of all pictures in a gallery when a keyword entered by a user in a picture search interface is obtained, to determine target attribute information matching the keyword;
  • the first display module is configured to display a picture corresponding to the target attribute information.
  • the first adding module includes:
  • a judging module configured to judge whether the number of types of objects in the picture is greater than 1 according to the type name
  • a determining module configured to determine the priority of the object according to a preset priority rule when the number of types of objects in the picture is greater than 1, and determine the type of object with the highest priority as the main object;
  • An adding sub-module is configured to add a type name corresponding to the main object to attribute information of exif information of the picture.
  • the determining module is specifically configured to:
  • the above image search device further includes:
  • a second query module configured to query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery when an instruction to store the picture is obtained;
  • a storage module configured to store the picture in the target picture folder.
  • the attribute information includes first attribute information and second attribute information
  • the first adding module is specifically configured to add a type name corresponding to the object to exif information of the picture In the first attribute information.
  • the picture search device further includes:
  • a third query module configured to query a tag information table corresponding to the type name of the object
  • a second display module that displays the tag information table on the current interface, where the tag information table includes multiple tags
  • a second adding module is configured to add a tag selected by the user to the second attribute information of the exif information when a user's selection instruction for at least one tag in the tag information table is obtained.
  • the second display module is specifically configured to:
  • a plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
  • the image recognition module is specifically configured to:
  • An embodiment of the present invention further provides a readable storage medium on which a program is stored, and when the program is executed by a processor, the steps of any one of the foregoing methods are implemented.
  • An embodiment of the present invention further provides a terminal, including a memory, a processor, and a program stored on the memory and executable on the processor.
  • a terminal including a memory, a processor, and a program stored on the memory and executable on the processor.
  • the processor executes the program, the steps of any of the foregoing methods are implemented.
  • an image recognition method is used to identify an object in a picture, determine a type name corresponding to the object, and add the determined type name to attribute information of exif information as auxiliary identification content.
  • a user finds a picture he can quickly search for the corresponding picture according to the attribute information. And the exif information will not be easily modified by the user, and has good stability. At any time, the user can perform image search based on the exif information.
  • FIG. 1 is a flowchart of a picture search method according to a first embodiment of the present invention
  • FIG. 2 is a schematic diagram of an interface of exif information of a picture
  • FIG. 3 is a flowchart of a picture search method according to a second embodiment of the present invention.
  • FIG. 4 is a structural block diagram of a picture search apparatus according to a third embodiment of the present invention.
  • FIG. 1 is a picture search method according to a first embodiment of the present invention.
  • the method is applied to a terminal.
  • the terminal is, for example, a mobile phone, a tablet computer, a wearable device, and the like.
  • the terminal has a camera function and generally has a camera. Can take pictures and photography. When the camera takes a picture, the corresponding exif information is generated.
  • the exif information can be attached to files such as JPEG, TIFF, RIFF, etc., to add content about the camera shooting information and index map or version information of image processing software.
  • the exif information contains the attribute information of the picture, as shown in Figure 2. If you view the attributes of a picture, the attribute information includes descriptive information such as title, subject, logo, remarks, etc.
  • the content of the attribute information is empty.
  • the user can view the attribute information of the picture and manually add content to the picture's title, subject, logo, and notes.
  • content is automatically added to the attributes of the picture, so as to facilitate subsequent quick search of the picture.
  • the image search method includes steps S11 to S14.
  • step S11 when a picture taken by the camera is detected, image recognition is performed on the picture to determine a type name corresponding to an object in the picture.
  • the terminal When the terminal detects a picture taken by the camera, it performs image recognition on the content of the picture. Identify the objects in the picture and the type names of the objects through image recognition. Among them, the objects referred to include multiple types, such as people, animals, landscapes, buildings, or food. Image recognition is an important field of artificial intelligence. It uses computer programs to process, analyze, and understand images in order to identify targets and objects in various modes. In the development of image recognition, there are three main recognition methods: statistical pattern recognition, structural pattern recognition, and fuzzy pattern recognition. In this embodiment, the image recognition method in the prior art can be used to determine the object in the picture and the corresponding type name.
  • this implementation can extract the shape features of the objects in the picture based on the contour method to identify the image, and determine the objects in the picture and the type names corresponding to the objects.
  • the specific steps include:
  • contours there are various algorithms for dividing and extracting contours, such as a boundary feature method, a Fourier shape description method, and an algorithm for identifying a shape contour of an object through a Fourier descriptor. At least one piece of contour information is obtained by contour-dividing the picture through the current contour-dividing and extraction algorithm, and the contour information is the feature information identifying the contour of the object.
  • the contour model database includes multiple object contours, and each object contour is provided with a type name. For example, the type name corresponding to the outline of a person is "Person”, the type name corresponding to the outline of an animal is “Animal”, and the type name corresponding to the outline of a food is "Food”.
  • the contour database may be stored in a server connected to the terminal through a network, and the process of performing image recognition on pictures may be performed in the server. Specifically, when the terminal detects a picture taken by the camera, the picture is sent to the server, and the server divides the picture into contours to obtain at least one contour information, and queries the contours of the matching objects in the contour model database, and Get the name information of the queried object outline. The server sends the obtained name information to the terminal.
  • Step S12 Add the type name corresponding to the object to the attribute information of the exif information of the picture.
  • the type name is added to the attribute information of the exif information.
  • the attribute information includes a plurality of information, such as title, subject, logo, and remark information.
  • the type name corresponding to the object can be added to any attribute information of the exif information of the picture. For example, the terminal adds the determined type name of the object to the content corresponding to the title information.
  • the number of objects in the picture may be one or more.
  • After performing image recognition on a picture containing only one object there is only one type name of the object.
  • For a picture containing multiple objects when multiple objects in the picture are all of the same type, only one type name is obtained for image recognition.
  • the image recognition There are multiple types of names.
  • the terminal determines the number of types of objects in the picture according to the determined number of type names. For example, if a picture contains 3 persons and an animal (cat), the type names of the objects determined from the picture are "person" and "cat", that is, there are two types of objects in the picture.
  • the type name of the type of object is directly added to the attribute information of the exif information.
  • the type names corresponding to the multiple types of objects may be added to the attribute information of the exif information of the picture.
  • the priority of each type of object can also be determined according to a preset priority rule, the type of object with the highest priority is determined as the main object, and the type name corresponding to the main object is added to the attribute information of the exif information.
  • the manner in which the preset priority rule is determined as the main object includes, but is not limited to, one of the following two types:
  • the priority list can be preset and stored in the terminal according to the needs of the user.
  • the preset priority list includes the type names and corresponding priority numbers of multiple types of objects.
  • the type names are objects of people, animals, buildings, food, and scenery, and the corresponding priority numbers are 1, 2 respectively. ... 5, the smaller the priority number, the higher the priority.
  • the person is used as the main object of the picture according to the priority order in the priority list.
  • the terminal may determine that the type of object with the largest area in the picture is the main object.
  • the area area of each type of object can be obtained by extracting contour features and calculating the total area of the area occupied by the outline of each type of object.
  • the type of object with the largest total area area is used as the main object.
  • step S13 when the keywords entered by the user in the picture search interface are obtained, attribute information of all pictures in the gallery is queried to determine target attribute information matching the keywords.
  • Step S14 Display a picture corresponding to the target attribute information.
  • the picture search interface is, for example, a search window on a terminal gallery interface, and a user enters keywords of pictures on the search interface.
  • the terminal queries attribute information of all pictures in the gallery according to the keyword to query target attribute information that contains the keyword phase in the attribute information. And open the picture corresponding to the target attribute information on the current interface.
  • an image recognition method is used to identify an object in a picture, determine a type name corresponding to the object, and add the determined type name to attribute information of exif information as auxiliary identification content.
  • a user finds a picture he can quickly search for the corresponding picture according to the attribute information. And the exif information will not be easily modified by the user, and has good stability. At any time, the user can perform image search based on the exif information.
  • FIG. 3 is a picture search method according to a second embodiment of the present invention, including steps S21 to S29.
  • step S21 when a picture taken by the camera is detected, the picture is divided into outlines to obtain at least one outline information.
  • the terminal When the terminal obtains a picture taken by the camera, it performs image recognition on the picture. Specifically, a contour extraction method may be adopted to divide the contours of the objects in the picture to obtain the contour information of at least one object.
  • Step S22 Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
  • the contour model is stored in the terminal in advance, and the contour model includes a plurality of object contours, and each object contour is correspondingly provided with a type name.
  • the terminal matches the divided contour information with multiple object contours in the contour model in order to determine an object contour adapted to the current contour information, and obtains the type name of the matched object contour. Understandably, by contour matching, the object contours of a type of object are obtained. For example, the contours of the objects matched by characters of different movements (sideways, bending, squatting) or different heights and shapes are all character contours. , That is, the corresponding type name is "person".
  • step S23 it is determined whether the number of types of objects in the picture is greater than 1 according to the type name, and if yes, step S24 is performed.
  • the contour information obtained by contour segmentation of a picture containing only one object is one or more.
  • a contour information there is only one object contour matched from the contour model database, and its corresponding type name is only one.
  • a picture containing multiple objects may match the contours of one or more objects and obtain one or more type names. For example, if a picture contains 3 persons and an animal (cat), the type names of the objects determined from the picture are "person" and "animal", that is, there are two types of objects in the picture.
  • Step S24 Calculate the total area area of each type of object in the picture, and determine the type of object with the largest total area area as the main object.
  • Step S25 Add the type name of the main object to the first attribute information of the exif information.
  • the total area of the area occupied by each type of object is calculated.
  • the total area of each type of object is compared, and the type of object with the largest total area is determined as the main object. For example, in a picture containing three people and one animal, the area occupied by the person is larger than the area occupied by the animal, and the person is the main object.
  • the type name corresponding to the determined main object is added to the first attribute information of the exif information.
  • the type name is directly added to the first attribute information of the exif information .
  • Step S26 Query a tag information table corresponding to the type name of the main object, and display the tag information table on the current interface.
  • the tag information table includes multiple tags.
  • a plurality of type names and tag information tables corresponding to each type name are pre-stored in the terminal.
  • Each label information table is preset with multiple labels, and the user can add favorite labels to each label information table according to actual needs.
  • the labels in the label information table are used to add more detailed descriptions of various types of objects.
  • the tag information table corresponding to a person type includes old people, children, men, women, etc., or tags indicating kinship (dad, mom, etc.) and age information
  • the tag information table corresponding to a landscape type includes blue sky, white clouds, flowers , Grass, tree and other tags
  • the tag information table corresponding to the type of cuisine includes chicken, duck, fish, meat and other tags.
  • the step of displaying the tag information table on the current interface includes: scrolling and displaying a plurality of tags in the tag information table with a preset track on the current interface.
  • multiple labels in the label information table are displayed on the current interface in a floating screen manner.
  • the preset trajectory can be designed as an arbitrary movement path, and the speed of label scrolling can be set in advance. For example, multiple labels in the label information table are sequentially moved from the left to the right on the current interface at a speed of 20 cm / min.
  • the tag information table may also be displayed on the current interface in the form of a list, and the user may select one or more tags in the list.
  • the user can automatically display the tag information table when starting the picture preview.
  • Controls on the current interface can also be triggered on the interface for previewing pictures to trigger the operation of displaying the tag information table.
  • Step S27 When a user's selection instruction for at least one tag in the tag information table is obtained, add the tag selected by the user to the second attribute information of the exif information.
  • the user can select a label by clicking or touching the label on the terminal.
  • the terminal obtains one or more tags selected by the user, the tag is added to the second attribute information of the exif information.
  • the second attribute information is one of exif attribute information, which is different from the first attribute information.
  • the first attribute information is title information in the exif information
  • the second attribute information is topic information in the exif information.
  • a label selected by the user is added to the content corresponding to the topic information.
  • step S28 when the keywords entered by the user in the picture search interface are obtained, attribute information of all pictures in the gallery is queried to determine target attribute information matching the keywords.
  • Step S29 Display a picture corresponding to the target attribute information.
  • the terminal When a user finds a picture, he can enter keywords in the picture search interface, and the terminal queries the attribute information of all pictures in the gallery according to the keyword to query the attribute information that contains the target attribute information of the keyword. And open the picture corresponding to the target attribute information on the current interface.
  • the method further includes steps after step S25:
  • Step S31 when an instruction for storing the picture is obtained, query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery;
  • step S32 the picture is stored in the target picture folder.
  • a plurality of picture folders are pre-stored in the gallery of the terminal, and the picture folders are used to store pictures.
  • the multiple picture files are in one-to-one correspondence with the type names of multiple object outlines in the contour model, and each picture folder may be named with a corresponding type name.
  • the terminal searches the corresponding target folder in the gallery according to the type name of the main object in the picture, and stores the picture in the target folder.
  • pictures can be classified and stored automatically.
  • a user searches for a picture, a corresponding picture folder is found in the gallery according to the type name of the main object of the picture, and then the picture is found from the found picture folder.
  • the identifiers of multiple preset picture folders may pop up. The user selects an identifier and saves the picture in the picture folder corresponding to the identifier.
  • FIG. 4 is a picture search apparatus according to a fourth embodiment of the present invention, including:
  • An image recognition module 100 configured to perform image recognition on a picture when a picture taken by a camera is detected to determine a type name corresponding to an object in the picture;
  • a first adding module 200 configured to add a type name corresponding to the object to attribute information of exif information of the picture
  • the first query module 300 is configured to query attribute information of all pictures in a gallery when a keyword entered by a user in a picture search interface is obtained, to determine target attribute information matching the keyword;
  • the first display module 400 is configured to display a picture corresponding to the target attribute information.
  • the first adding module 200 includes:
  • a judging module configured to judge whether the number of types of objects in the picture is greater than 1 according to the type name
  • a determining module configured to determine the priority of the object according to a preset priority rule when the number of types of objects in the picture is greater than 1, and determine the type of object with the highest priority as the main object;
  • An adding sub-module is configured to add a type name corresponding to the main object to attribute information of exif information of the picture.
  • the determining module is specifically configured to:
  • the above image search device further includes:
  • a second query module 500 configured to query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery when an instruction to store the picture is obtained;
  • the storage module 600 is configured to store the picture in the target picture folder.
  • the first adding module 200 is specifically configured to add a type name corresponding to the object to an exif of the picture The first attribute information of the information;
  • the picture search device further includes:
  • a third query module 700 configured to query a tag information table corresponding to the type name of the object
  • the second display module 800 displays the tag information table on the current interface, where the tag information table includes multiple tags;
  • the second adding module 900 is configured to add a tag selected by the user to the second attribute information of the exif information when a user's selection instruction for at least one tag in the tag information table is obtained.
  • the second display module 800 is specifically configured to:
  • a plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
  • the image recognition module 100 is specifically configured to:
  • the present invention also proposes a readable storage medium on which a computer program is stored, and when the program is executed by a processor, the above-mentioned picture search method is implemented.
  • An embodiment of the present invention further provides a terminal, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor.
  • a terminal which includes a memory, a processor, and a computer program stored on the memory and executable on the processor.
  • the processor executes the program, the steps of the foregoing method are implemented.
  • a sequenced list of executable instructions that can be considered to implement a logical function can be embodied in any computer-readable medium, For instruction execution systems, devices, or devices (such as computer-based systems, systems including processors, or other systems that can fetch instructions from and execute instructions) Or equipment.
  • a "computer-readable medium” may be any device that can contain, store, communicate, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device.
  • computer-readable media include the following: electrical connections (electronic devices) with one or more wirings, portable computer cartridges (magnetic devices), random access memory (RAM), Read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disk read-only memory (CDROM).
  • the computer-readable medium may even be paper or other suitable medium on which the program can be printed, because, for example, by optically scanning the paper or other medium, followed by editing, interpretation, or other suitable Processing to obtain the program electronically and then store it in computer memory.
  • each part of the present invention may be implemented by hardware, software, firmware, or a combination thereof.
  • multiple steps or methods may be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system.
  • a suitable instruction execution system For example, if implemented in hardware, as in another embodiment, it may be implemented using any one or a combination of the following techniques known in the art: Discrete logic circuits, application specific integrated circuits with suitable combinational logic gate circuits, programmable gate arrays (PGA), field programmable gate arrays (FPGA), etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Processing Or Creating Images (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

A picture search method and device, a readable storage medium, and a terminal. The method comprises: when a picture taken by a camera is detected, performing picture recognition on the picture to determine a type name corresponding to an object in the picture (S11); adding the type name corresponding to the object to attribute information of exif information of the picture (S12); when keywords input by a user in a picture search interface are obtained, querying attribute information of all pictures in a picture gallery to determine target attribute information matching the keywords (S13); and displaying the picture corresponding to the target attribute information (S14). In the method, the object in the picture is recognized by a picture recognition method, and the type name of the determined object is added to the attribute information of the exif information of the picture as auxiliary recognition content. When the user searches for the picture, the corresponding picture can be quickly searched according to the attribute information.

Description

图片搜索方法、装置、可读存储介质及终端Picture search method, device, readable storage medium and terminal 【技术领域】[Technical Field]
本发明涉及电子技术领域,特别是涉及一种图片搜索方法、装置、可读存储介质及终端。The present invention relates to the field of electronic technology, and in particular, to a picture search method, device, readable storage medium, and terminal.
【背景技术】【Background technique】
随着科技的发展,数码相机和具有拍照功能的智能终端被广泛应用,另外通过互联网下载、视频截取以及使用图片绘制软件,人们在生活和工作中生成的图片越来越多。而图片的查找则成了困扰人们的问题之一。With the development of technology, digital cameras and smart terminals with photographing functions are widely used. In addition, people download more and more pictures in life and work through Internet downloads, video capture, and the use of picture drawing software. Finding pictures has become one of the problems that bothers people.
现有技术中一般根据图片名称进行图片的查找,而图库中的图片一般通过按默认的命名规则进行命名,例如可以按顺序的编号,或以拍摄时间进行命名,并根据时间轴和文件名称进行分类。也可以是用户手动添加图片命名或修改图片命名。但是,由于图片数量多、存储时间长,用户容易忘记图片名称、存储日期或存储在那个文件夹,查找时需要一张一张的预览查看图库中的图片,查找速度非常慢。In the prior art, pictures are usually searched according to the picture name, and pictures in the gallery are generally named according to the default naming rule. For example, they can be numbered sequentially or named according to the shooting time. classification. It is also possible for users to manually add picture names or modify picture names. However, due to the large number of pictures and long storage time, users tend to forget the picture name, storage date or stored in that folder. When searching, you need to preview the pictures in the gallery one by one. The search speed is very slow.
【发明内容】[Summary of the Invention]
鉴于上述状况,有必要针对现有技术中图片查找速度慢的问题,提供一种图片搜索方法、装置、可读存储介质及终端。In view of the foregoing, it is necessary to provide a picture search method, device, readable storage medium, and terminal in response to the problem of slow picture search speed in the prior art.
一种图片搜索方法,包括:An image search method includes:
当检测到相机拍摄的一图片时,对所述图片进行图像识别,以确定所述图片中物体对应的类型名称;When a picture taken by the camera is detected, image recognition is performed on the picture to determine a type name corresponding to an object in the picture;
将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中;Adding a type name corresponding to the object to attribute information of exif information of the picture;
当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息;When a keyword entered by a user in the picture search interface is obtained, attribute information of all pictures in the gallery is queried to determine target attribute information matching the keyword;
显示所述目标属性信息对应的图片。Display a picture corresponding to the target attribute information.
进一步的,上述图片搜索方法,其中,所述将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中的步骤包括:Further, in the above picture search method, the step of adding a type name corresponding to the object to attribute information of exif information of the picture includes:
根据所述类型名称判断所述图片中的物体的类型数是否大于1;Determining whether the number of types of objects in the picture is greater than 1 according to the type name;
若是,根据预设的优先级规则确定所述物体的优先级,并将优先级 最高的一类型物体确定为主物体;If yes, determine the priority of the object according to a preset priority rule, and determine the type of object with the highest priority as the main object;
将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中。Adding the type name corresponding to the main object to the attribute information of the exif information of the picture.
进一步的,上述图片搜索方法,其中,所述根据预设的优先级规则确定所述物体的优先级的步骤包括:Further, in the above picture search method, the step of determining the priority of the object according to a preset priority rule includes:
分别计算所述图片中每个类型物体的总区域面积,并根据所述总区域面积确定各个类型的物体的优先级,所述总区域面积越大的一类物体其优先级越高。Calculate the total area area of each type of object in the picture, and determine the priority of each type of object according to the total area area. The type of object with a larger total area area has higher priority.
进一步的,上述图片搜索方法,其中,所述将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中的步骤之后还包括:Further, in the above picture search method, after the step of adding a type name corresponding to the main object to attribute information of exif information of the picture, the method further includes:
当获取到存储所述图片的指令时,查询图库中预设的多个图片文件夹中,与所述主物体的类型名称对应的目标图片文件夹;When an instruction to store the picture is obtained, among a plurality of picture folders preset in the query gallery, a target picture folder corresponding to the type name of the main object;
将所述图片存储至所述目标图片文件夹中。The picture is stored in the target picture folder.
进一步的,上述图片搜索方法,其中,所述属性信息包括第一属性信息和第二属性信息,所述将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中的步骤包括:Further, in the above picture search method, wherein the attribute information includes first attribute information and second attribute information, and the step of adding a type name corresponding to the object to the attribute information of exif information of the picture includes :
将所述物体对应的类型名称添加至所述图片的exif信息的第一属性信息中。Adding the type name corresponding to the object to the first attribute information of the exif information of the picture.
进一步的,上述图片搜索方法,其中,所述将所述物体对应的类型名称添加至所述图片的exif信息的第一属性信息中的步骤之后还包括:Further, in the above picture search method, after the step of adding a type name corresponding to the object to the first attribute information of exif information of the picture, the method further includes:
查询与所述物体的类型名称所对应的标签信息表,并在当前界面显示所述标签信息表,所述标签信息表包括多个标签;Querying the tag information table corresponding to the type name of the object, and displaying the tag information table on the current interface, where the tag information table includes multiple tags;
当获取到用户针对所述标签信息表中的至少一个标签的选中指令时,将所述用户选中的标签添加至所述exif信息的第二属性信息中。When a user's selection instruction for at least one tag in the tag information table is obtained, the tag selected by the user is added to the second attribute information of the exif information.
进一步的,上述图片搜索方法,其中,所述在当前界面显示所述标签信息表的步骤包括:Further, in the above picture search method, the step of displaying the tag information table on the current interface includes:
在所述当前界面以预设的轨迹滚动显示所述标签信息表中的多个标签。A plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
进一步的,上述图片搜索方法,其中,所述对一图片进行图像识别,以确定所述图片中的物体对应的类型名称的步骤包括:Further, in the above picture search method, the step of performing image recognition on a picture to determine a type name corresponding to an object in the picture includes:
对所述图片进行轮廓划分,得到至少一轮廓信息;Performing contour division on the picture to obtain at least one contour information;
从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
本发明实施例还提供了一种图片搜索装置,包括:An embodiment of the present invention further provides a picture search apparatus, including:
图像识别模块,用于当检测到相机拍摄的一图片时,对所述图片进 行图像识别,以确定所述图片中物体对应的类型名称;An image recognition module, configured to perform image recognition on a picture when a picture taken by a camera is detected to determine a type name corresponding to an object in the picture;
第一添加模块,用于将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中;A first adding module, configured to add a type name corresponding to the object to attribute information of exif information of the picture;
第一查询模块,用于当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息;A first query module, configured to query attribute information of all pictures in a gallery when a keyword entered by a user in a picture search interface is obtained, to determine target attribute information matching the keyword;
第一显示模块,用于显示所述目标属性信息对应的图片。The first display module is configured to display a picture corresponding to the target attribute information.
进一步的,上述图片搜索装置,其中,所述第一添加模块包括:Further, in the above image search device, the first adding module includes:
判断模块,用于根据所述类型名称判断所述图片中的物体的类型数是否大于1;A judging module, configured to judge whether the number of types of objects in the picture is greater than 1 according to the type name;
确定模块,用于当所述图片中的物体的类型数大于1时,根据预设的优先级规则确定所述物体的优先级,并将优先级最高的一类型物体确定为主物体;A determining module, configured to determine the priority of the object according to a preset priority rule when the number of types of objects in the picture is greater than 1, and determine the type of object with the highest priority as the main object;
添加子模块,用于将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中。An adding sub-module is configured to add a type name corresponding to the main object to attribute information of exif information of the picture.
进一步的,上述图片搜索装置,其中,所述确定模块具体用于:Further, in the above picture search device, the determining module is specifically configured to:
分别计算所述图片中每个类型物体的总区域面积,并根据所述总区域面积确定各个类型的物体的优先级,所述总区域面积越大的一类物体其优先级越高。Calculate the total area area of each type of object in the picture, and determine the priority of each type of object according to the total area area. The type of object with a larger total area area has higher priority.
进一步的,上述图片搜索装置,还包括:Further, the above image search device further includes:
第二查询模块,用于当获取到存储所述图片的指令时,查询图库中预设的多个图片文件夹中,与所述主物体的类型名称对应的目标图片文件夹;A second query module, configured to query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery when an instruction to store the picture is obtained;
存储模块,用于将所述图片存储至所述目标图片文件夹中。A storage module, configured to store the picture in the target picture folder.
进一步的,上述图片搜索装置,其中,所述属性信息包括第一属性信息和第二属性信息,所述第一添加模块具体用于将所述物体对应的类型名称添加至所述图片的exif信息的第一属性信息中。Further, in the above picture search device, the attribute information includes first attribute information and second attribute information, and the first adding module is specifically configured to add a type name corresponding to the object to exif information of the picture In the first attribute information.
进一步的,上述图片搜索装置,其中,所述图片搜索装置还包括:Further, in the above picture search device, the picture search device further includes:
第三查询模块,用于查询与所述物体的类型名称所对应的标签信息表;A third query module, configured to query a tag information table corresponding to the type name of the object;
第二显示模块,在当前界面显示所述标签信息表,所述标签信息表包括多个标签;A second display module that displays the tag information table on the current interface, where the tag information table includes multiple tags;
第二添加模块,用于当获取到用户针对所述标签信息表中的至少一个标签的选中指令时,将所述用户选中的标签添加至所述exif信息的第二属性信息中。A second adding module is configured to add a tag selected by the user to the second attribute information of the exif information when a user's selection instruction for at least one tag in the tag information table is obtained.
进一步的,上述图片搜索装置,其中,所述第二显示模块具体用于:Further, in the above picture search device, the second display module is specifically configured to:
在所述当前界面以预设的轨迹滚动显示所述标签信息表中的多个标签。A plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
进一步的,上述图片搜索装置,其中,图像识别模块具体用于:Further, in the above picture search device, the image recognition module is specifically configured to:
对所述图片进行轮廓划分,得到至少一轮廓信息;Performing contour division on the picture to obtain at least one contour information;
从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
本发明实施例还提供了一种可读存储介质,其上存储有程序,所述程序被处理器执行时实现上述任意一方法的步骤。An embodiment of the present invention further provides a readable storage medium on which a program is stored, and when the program is executed by a processor, the steps of any one of the foregoing methods are implemented.
本发明实施例还提供了一种终端,包括存储器、处理器以及存储在存储器上并可在处理器上运行的程序,所述处理器执行所述程序时实现上述任意一方法的步骤。An embodiment of the present invention further provides a terminal, including a memory, a processor, and a program stored on the memory and executable on the processor. When the processor executes the program, the steps of any of the foregoing methods are implemented.
本发明实施例中,采用图像识别的方法,识别图片中的物体,并确定该物体对应的类型名称,并将确定的类型名称添加至的exif信息的属性信息中,以作为辅助识别内容。用户查找图片时,可根据该属性信息快速搜索到对应的图片。并且该exif信息不会轻易被用户修改,具有良好的稳定性,任何时候用户均可根据该exif信息进行图片搜索。In the embodiment of the present invention, an image recognition method is used to identify an object in a picture, determine a type name corresponding to the object, and add the determined type name to attribute information of exif information as auxiliary identification content. When a user finds a picture, he can quickly search for the corresponding picture according to the attribute information. And the exif information will not be easily modified by the user, and has good stability. At any time, the user can perform image search based on the exif information.
【附图说明】[Brief Description of the Drawings]
图1为本发明第一实施例提供的图片搜索方法的流程图;FIG. 1 is a flowchart of a picture search method according to a first embodiment of the present invention; FIG.
图2为一图片的exif信息的界面示意图;FIG. 2 is a schematic diagram of an interface of exif information of a picture; FIG.
图3为本发明第二实施例提供的图片搜索方法的流程图;3 is a flowchart of a picture search method according to a second embodiment of the present invention;
图4为本发明第三实施例提供的图片搜索装置的结构框图。FIG. 4 is a structural block diagram of a picture search apparatus according to a third embodiment of the present invention.
【具体实施方式】【detailed description】
下面详细描述本发明的实施例,所述实施例的示例在附图中示出,其中自始至终相同或类似的标号表示相同或类似的元件或具有相同或类似功能的元件。下面通过参考附图描述的实施例是示例性的,仅用于解释本发明,而不能理解为对本发明的限制。Hereinafter, embodiments of the present invention will be described in detail. Examples of the embodiments are shown in the drawings, wherein the same or similar reference numerals indicate the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the drawings are exemplary, and are only used to explain the present invention, and should not be construed as limiting the present invention.
参照下面的描述和附图,将清楚本发明的实施例的这些和其他方面。在这些描述和附图中,具体公开了本发明的实施例中的一些特定实施方式,来表示实施本发明的实施例的原理的一些方式,但是应当理解,本发明的实施例的范围不受此限制。相反,本发明的实施例包括落入所附加权利要求书的精神和内涵范围内的所有变化、添加和等同物。These and other aspects of embodiments of the invention will be apparent with reference to the following description and drawings. In these descriptions and drawings, some specific implementations of the embodiments of the present invention are specifically disclosed to represent some ways of implementing the principles of the embodiments of the present invention, but it should be understood that the scope of the embodiments of the present invention is not limited by This limitation. On the contrary, the embodiments of the present invention include all changes, additions, and equivalents falling within the spirit and scope of the appended claims.
请参阅图1,为本发明第一实施例中的图片搜索方法,该方法应用于终端中,该终端例如为手机、平板电脑、可穿戴设备等,该终端具备拍照功能,一般安装有相机,可进行拍照摄影等。相机拍摄一图片时,会生成对应的exif信息,exif信息可以附加于JPEG、TIFF、RIFF等文件之中,为其增加有关相机拍摄信息的内容和索引图或图像处理软件的版本信息。该exif信息包含了图片的属性信息,如图2所示,如查看一张图片的属性,其属性信息包括标题、主题、标识、备注等说明信息,现有技术中该属性信息的内容为空,用户可以查看图片的属性信息并对图片的标题、主题、标识、备注手动添加内容。本发明实施例中,相机拍摄图片时自动对图片的属性添加内容,以便于后续快速查找图片。该图片搜索方法包括步骤S11~S14。Please refer to FIG. 1, which is a picture search method according to a first embodiment of the present invention. The method is applied to a terminal. The terminal is, for example, a mobile phone, a tablet computer, a wearable device, and the like. The terminal has a camera function and generally has a camera. Can take pictures and photography. When the camera takes a picture, the corresponding exif information is generated. The exif information can be attached to files such as JPEG, TIFF, RIFF, etc., to add content about the camera shooting information and index map or version information of image processing software. The exif information contains the attribute information of the picture, as shown in Figure 2. If you view the attributes of a picture, the attribute information includes descriptive information such as title, subject, logo, remarks, etc. In the prior art, the content of the attribute information is empty. , The user can view the attribute information of the picture and manually add content to the picture's title, subject, logo, and notes. In the embodiment of the present invention, when the camera takes a picture, content is automatically added to the attributes of the picture, so as to facilitate subsequent quick search of the picture. The image search method includes steps S11 to S14.
步骤S11,当检测到相机拍摄的一图片时,对所述图片进行图像识别,以确定所述图片中物体对应的类型名称。In step S11, when a picture taken by the camera is detected, image recognition is performed on the picture to determine a type name corresponding to an object in the picture.
当终端检测到相机拍摄的一张图片时,对该图片的内容进行图像识别。通过图像识别确定图片中的物体和物体的类型名称。其中,所指的物体涵盖多类型,例如可以为人物、动物、风景、建筑或食物等。图像识别是人工智能的一个重要领域,其利用计算机程序对图像进行处理、分析和理解,以识别各种不同模式的目标和对像的技术。在图像识别的发展中,主要有三种识别方法:统计模式识别、结构模式识别、模糊模式识别。本实施例中可通过现有技术中图像识别方法来确定图片中的物体以及对应的类型名称。When the terminal detects a picture taken by the camera, it performs image recognition on the content of the picture. Identify the objects in the picture and the type names of the objects through image recognition. Among them, the objects referred to include multiple types, such as people, animals, landscapes, buildings, or food. Image recognition is an important field of artificial intelligence. It uses computer programs to process, analyze, and understand images in order to identify targets and objects in various modes. In the development of image recognition, there are three main recognition methods: statistical pattern recognition, structural pattern recognition, and fuzzy pattern recognition. In this embodiment, the image recognition method in the prior art can be used to determine the object in the picture and the corresponding type name.
举例来说,本实施可基于轮廓的方法对图片中物体的形状特征进行提取,以对图像进行识别,并确定图片中的物体及物体对应的类型名称,其具体步骤包括:For example, this implementation can extract the shape features of the objects in the picture based on the contour method to identify the image, and determine the objects in the picture and the type names corresponding to the objects. The specific steps include:
对所述图片进行轮廓划分,得到至少一轮廓信息;Performing contour division on the picture to obtain at least one contour information;
从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
其中,现有技术中有各种轮廓的划分和提取的算法,例如边界特征法、傅里叶形状描述法,以及还有一种通过傅里叶描述子识别物体的形状轮廓的算法等。通过现将的轮廓划分和提取算法对图片进行轮廓划分得到至少一轮廓信息,该轮廓信息即为标识物体的轮廓的特征信息。Among them, in the prior art, there are various algorithms for dividing and extracting contours, such as a boundary feature method, a Fourier shape description method, and an algorithm for identifying a shape contour of an object through a Fourier descriptor. At least one piece of contour information is obtained by contour-dividing the picture through the current contour-dividing and extraction algorithm, and the contour information is the feature information identifying the contour of the object.
当获取到一轮廓信息后,与轮廓模型数据库中的物体轮廓进行匹配,以查询到与该轮廓信息匹配的物体轮廓。该轮廓模型数据库预先存储在终端中,轮廓模型数据库中包括多个物体轮廓,每个物体轮廓对应设置一类型名称。例如人物轮廓对应的类型名称是“人物”、动物轮廓 对应的类型名称是“动物”、食物轮廓对应的类型名称是“食物”等。When a contour information is obtained, it is matched with the contour of the object in the contour model database to find the contour of the object that matches the contour information. The contour model database is stored in the terminal in advance. The contour model database includes multiple object contours, and each object contour is provided with a type name. For example, the type name corresponding to the outline of a person is "Person", the type name corresponding to the outline of an animal is "Animal", and the type name corresponding to the outline of a food is "Food".
可以理解的,作为本发明的另一种实施方式,该轮廓数据库可存储在与该终端通过网络连接的服务器中,对图片进行图像识别的过程可在服务器中进行。具体的,当终端检测到相机拍摄的一张图片时,将该图片发送至服务器,该服务器对该图片进行轮廓划分得到至少一轮廓信息,并查询轮廓模型数据库中与之匹配的物体轮廓,以及获取查询到的物体轮廓的名称信息。服务器再将获取到的名称信息发送至终端。It can be understood that, as another embodiment of the present invention, the contour database may be stored in a server connected to the terminal through a network, and the process of performing image recognition on pictures may be performed in the server. Specifically, when the terminal detects a picture taken by the camera, the picture is sent to the server, and the server divides the picture into contours to obtain at least one contour information, and queries the contours of the matching objects in the contour model database, and Get the name information of the queried object outline. The server sends the obtained name information to the terminal.
步骤S12,将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中。Step S12: Add the type name corresponding to the object to the attribute information of the exif information of the picture.
当终端确定了图片中物体的类型名称后,将该类型名称添加至exif信息的属性信息中。该属性信息包括多个,例如包括标题、主题、标识、备注信息中。物体对应的类型名称可添加至图片的exif信息的任意一个属性信息中。例如,终端将确定的物体的类型名称添加至标题信息对应的内容中。After the terminal determines the type name of the object in the picture, the type name is added to the attribute information of the exif information. The attribute information includes a plurality of information, such as title, subject, logo, and remark information. The type name corresponding to the object can be added to any attribute information of the exif information of the picture. For example, the terminal adds the determined type name of the object to the content corresponding to the title information.
上述步骤中,图片中的物体的数量可能为一个或多个,仅含有一个物体的图片进行图像识别后,得到的物体的类型名称只有一个。而对于包含多个物体的图片,当该图片中的多个物体均为同一类型的物体时,图像识别得到类型名称只有一个,当该图片中的物体为不同类型的物体时,图像识别得到的类型名称有多个。终端根据确定的类型名称的数量确定图片中的物体的类型数。例如,一图片中包含3个人物和一个动物(猫),则从该图片中确定的物体的类型名称为“人物”和“猫”,即该图片中存在两个类型的物体。In the above steps, the number of objects in the picture may be one or more. After performing image recognition on a picture containing only one object, there is only one type name of the object. For a picture containing multiple objects, when multiple objects in the picture are all of the same type, only one type name is obtained for image recognition. When the objects in the picture are different types of objects, the image recognition There are multiple types of names. The terminal determines the number of types of objects in the picture according to the determined number of type names. For example, if a picture contains 3 persons and an animal (cat), the type names of the objects determined from the picture are "person" and "cat", that is, there are two types of objects in the picture.
当图片中只有一种类型的物体时,直接将该类型物体的类型名称添加至exif信息的属性信息中。当图片中存在多种类型的物体时,可将该多个类型物体对应的类型名称添均加至图片的exif信息的属性信息中。当然,也可以根据预设的优先级规则确定各个类型物体的优先级,将优先级最高的一类型物体确定为主物体,并将主物体对应的类型名称添加至exif信息的属性信息中。When there is only one type of object in the picture, the type name of the type of object is directly added to the attribute information of the exif information. When there are multiple types of objects in the picture, the type names corresponding to the multiple types of objects may be added to the attribute information of the exif information of the picture. Of course, the priority of each type of object can also be determined according to a preset priority rule, the type of object with the highest priority is determined as the main object, and the type name corresponding to the main object is added to the attribute information of the exif information.
具体的,该预设的优先级规则确定为主物体的方式包括但不限于下述两种中的一种:Specifically, the manner in which the preset priority rule is determined as the main object includes, but is not limited to, one of the following two types:
其一,从预设的优先级列表中,查询各个类型物体的优先级,并确定一优先级最高的一类物体为主物体。该优先级列表可根据用户的需要预设存储在终端中。该预设的优先级列表包多个类型物体的类型名称和对应的优先级数,例如类型名称分别为人物、动物、建筑物、食物和风景的物体,对应的优先级数分别为1、2……5,优先级数越小的优先级 越高。例如,当识别到图片中既有人物也有动物,时则根据该优先级列表中的优先级顺序,将人物作为该图片的主物体。First, from the preset priority list, the priority of each type of object is queried, and a type of object with the highest priority is determined as the main object. The priority list can be preset and stored in the terminal according to the needs of the user. The preset priority list includes the type names and corresponding priority numbers of multiple types of objects. For example, the type names are objects of people, animals, buildings, food, and scenery, and the corresponding priority numbers are 1, 2 respectively. ... 5, the smaller the priority number, the higher the priority. For example, when both a person and an animal are recognized in the picture, the person is used as the main object of the picture according to the priority order in the priority list.
其二,分别计算该图片中每个类型物体的总区域面积;根据总区域面积确定各个类型的物体的优先级,总区域面积越大的一类物体其优先级越高。因此,终端可确定该图片中区域面积最大的一类物体为主物体。Secondly, the total area of each type of object in the picture is calculated separately; the priority of each type of object is determined according to the total area, and the type of object with a larger total area has higher priority. Therefore, the terminal may determine that the type of object with the largest area in the picture is the main object.
其中,各类型物体的区域面积可通过提取轮廓特征,并计算各类型物体轮廓所占区域的总面积得到,将总区域面积最大的一类物体作为主物体。The area area of each type of object can be obtained by extracting contour features and calculating the total area of the area occupied by the outline of each type of object. The type of object with the largest total area area is used as the main object.
步骤S13,当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息。In step S13, when the keywords entered by the user in the picture search interface are obtained, attribute information of all pictures in the gallery is queried to determine target attribute information matching the keywords.
步骤S14,显示所述目标属性信息对应的图片。Step S14: Display a picture corresponding to the target attribute information.
该图片搜索界面例如为终端图库界面上的一搜索窗口,用户在该搜索界面上输入图片的关键字。终端根据该关键字查询图库中所有图片的属性信息,以查询该属性信息中包含有该关键字相的目标属性信息。并在当前界面上打开该目标属性信息对应的图片。The picture search interface is, for example, a search window on a terminal gallery interface, and a user enters keywords of pictures on the search interface. The terminal queries attribute information of all pictures in the gallery according to the keyword to query target attribute information that contains the keyword phase in the attribute information. And open the picture corresponding to the target attribute information on the current interface.
本实施例中,采用图像识别的方法,识别图片中的物体,并确定该物体对应的类型名称,并将确定的类型名称添加至的exif信息的属性信息中,以作为辅助识别内容。用户查找图片时,可根据该属性信息快速搜索到对应的图片。并且该exif信息不会轻易被用户修改,具有良好的稳定性,任何时候用户均可根据该exif信息进行图片搜索。In this embodiment, an image recognition method is used to identify an object in a picture, determine a type name corresponding to the object, and add the determined type name to attribute information of exif information as auxiliary identification content. When a user finds a picture, he can quickly search for the corresponding picture according to the attribute information. And the exif information will not be easily modified by the user, and has good stability. At any time, the user can perform image search based on the exif information.
请参阅图3,为本发明第二实施例中的图片搜索方法,包括步骤S21~S29。Please refer to FIG. 3, which is a picture search method according to a second embodiment of the present invention, including steps S21 to S29.
步骤S21,当检测到相机拍摄的一图片时,对所述图片进行轮廓划分,得到至少一轮廓信息。In step S21, when a picture taken by the camera is detected, the picture is divided into outlines to obtain at least one outline information.
当终端获取到相机拍摄的一图片时,对图片进行图像识别。具体可采用轮廓提取的方法,对图片中物体的轮廓进行划分,得到至少一个物体的轮廓信息。When the terminal obtains a picture taken by the camera, it performs image recognition on the picture. Specifically, a contour extraction method may be adopted to divide the contours of the objects in the picture to obtain the contour information of at least one object.
步骤S22,从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Step S22: Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
该轮廓模型预先存储在终端中,轮廓模型中包括多个物体轮廓,每个物体轮廓对应设置一类型名称。终端将划分得到的轮廓信息与轮廓模型中的多个物体轮廓依次进行匹配,以确定一与当前轮廓信息适配的物体轮廓,并获取匹配到的物体轮廓的类型名称。可以理解的,通过轮廓匹配的方式,得到的是一类型的物体的物体轮廓,如不同动作(侧身、 弯腰、下蹲)或不同身高、不同体型的人物匹配到的物体轮廓均为人物轮廓,即对应的类型名称均为“人物”。The contour model is stored in the terminal in advance, and the contour model includes a plurality of object contours, and each object contour is correspondingly provided with a type name. The terminal matches the divided contour information with multiple object contours in the contour model in order to determine an object contour adapted to the current contour information, and obtains the type name of the matched object contour. Understandably, by contour matching, the object contours of a type of object are obtained. For example, the contours of the objects matched by characters of different movements (sideways, bending, squatting) or different heights and shapes are all character contours. , That is, the corresponding type name is "person".
步骤S23,根据所述类型名称判断所述图片中的物体的类型数是否大于1,若是,执行步骤S24。In step S23, it is determined whether the number of types of objects in the picture is greater than 1 according to the type name, and if yes, step S24 is performed.
仅包含一个物体的图片经过轮廓划分得到的轮廓信息为一个或多个。对于一个轮廓信息来说其从轮廓模型数据库中匹配到的物体轮廓只有一个,其对应的类型名称仅为一种。而包含多个物体的图片,可能匹配到一个多个物体轮廓,得到一个或多个类型名称。例如,一图片中包含3个人物和一个动物(猫),则从该图片中确定的物体的类型名称有“人物”和“动物”,即该图片中存在两类型的物体。The contour information obtained by contour segmentation of a picture containing only one object is one or more. For a contour information, there is only one object contour matched from the contour model database, and its corresponding type name is only one. A picture containing multiple objects may match the contours of one or more objects and obtain one or more type names. For example, if a picture contains 3 persons and an animal (cat), the type names of the objects determined from the picture are "person" and "animal", that is, there are two types of objects in the picture.
步骤S24,分别计算该图片中每个类型物体的总区域面积,并确定所述总区域面积最大的一类型的物体为主物体。Step S24: Calculate the total area area of each type of object in the picture, and determine the type of object with the largest total area area as the main object.
步骤S25,将该主物体的类型名称添加至exif信息的第一属性信息中。Step S25: Add the type name of the main object to the first attribute information of the exif information.
当图片中存在多类型型的物体时,则计算每个类型的物体所占区域的总区域面积。并比较各类型的物体的总区域面积,将总区域面积最大的一类型的物体确定为主物体。例如,包含3个人物和一个动物的图片中,人物所占的区域面积比动物所占的区域面积大,将人物作为主物体。将确定的主物体对应的类型名称添加到exif信息的第一属性信息中。When there are multiple types of objects in the picture, the total area of the area occupied by each type of object is calculated. The total area of each type of object is compared, and the type of object with the largest total area is determined as the main object. For example, in a picture containing three people and one animal, the area occupied by the person is larger than the area occupied by the animal, and the person is the main object. The type name corresponding to the determined main object is added to the first attribute information of the exif information.
若根据类型名称判断所述图片中的所述物体的类型数不大于1,即等于1时,则不进行区域面积的计算,而是直接将该类型名称添加至exif信息的第一属性信息中。If it is determined according to the type name that the number of types of the object in the picture is not greater than 1, that is, equal to 1, the area area is not calculated, and the type name is directly added to the first attribute information of the exif information .
步骤S26,查询与所述主物体的类型名称对应的标签信息表,并在当前界面显示所述标签信息表,所述标签信息表包括多个标签。Step S26: Query a tag information table corresponding to the type name of the main object, and display the tag information table on the current interface. The tag information table includes multiple tags.
终端中预存多个类型名称和每个类型名称对应的标签信息表。每个标签信息表预设有多个标签,而且用户可根据实际需要在每个标签信息表中添加心仪的标签。标签信息表中的标签用于对各类型的物体添加更加详细的描述。例如,人物类型对应的标签信息表中包括老人、小孩、男、女等,或表示亲属关系(爸爸、妈妈等)和年龄信息的标签;风景类型对应的标签信息表中包括蓝天、白云、花、草、树等标签;美食类型对应的标签信息表中包括鸡,鸭,鱼,肉等标签。A plurality of type names and tag information tables corresponding to each type name are pre-stored in the terminal. Each label information table is preset with multiple labels, and the user can add favorite labels to each label information table according to actual needs. The labels in the label information table are used to add more detailed descriptions of various types of objects. For example, the tag information table corresponding to a person type includes old people, children, men, women, etc., or tags indicating kinship (dad, mom, etc.) and age information; the tag information table corresponding to a landscape type includes blue sky, white clouds, flowers , Grass, tree and other tags; the tag information table corresponding to the type of cuisine includes chicken, duck, fish, meat and other tags.
进一步的,在当前界面显示所述标签信息表的步骤包括:在所述当前界面以预设的轨迹滚动显示所述标签信息表中的多个标签。Further, the step of displaying the tag information table on the current interface includes: scrolling and displaying a plurality of tags in the tag information table with a preset track on the current interface.
即标签信息表中的多个标签以飘屏的方式显示在当前界面上。该预设的轨迹可设计为任意的移动路径,标签滚动的速度可预先设置。例如 该标签信息表中的多个标签依次在当前界面上,从左至右移动,移动速度为20cm/min。That is, multiple labels in the label information table are displayed on the current interface in a floating screen manner. The preset trajectory can be designed as an arbitrary movement path, and the speed of label scrolling can be set in advance. For example, multiple labels in the label information table are sequentially moved from the left to the right on the current interface at a speed of 20 cm / min.
进一步的,另一实施例中,该标签信息表也可以以列表的形式显示在当前界面中,用户可以在该列表中选择一个或多个标签。Further, in another embodiment, the tag information table may also be displayed on the current interface in the form of a list, and the user may select one or more tags in the list.
可以理解的,用户可以在启动图片预览时自动显示标签信息表。也可以在预览图片的界面上触发当前界面上的控件来触发显示标签信息表的操作。Understandably, the user can automatically display the tag information table when starting the picture preview. Controls on the current interface can also be triggered on the interface for previewing pictures to trigger the operation of displaying the tag information table.
步骤S27,当获取到用户针对所述标签信息表中的至少一个标签的选中指令时,将所述用户选中的标签添加至所述exif信息的第二属性信息中。Step S27: When a user's selection instruction for at least one tag in the tag information table is obtained, add the tag selected by the user to the second attribute information of the exif information.
用户可通过点击或触摸终端上的标签的方式进行标签的选中。当终端获取到用户选中的一个或多个标签时,将该标签添加至exif信息的第二属性信息中。The user can select a label by clicking or touching the label on the terminal. When the terminal obtains one or more tags selected by the user, the tag is added to the second attribute information of the exif information.
该第二属性信息为exif属性信息中的一种,其不同于第一属性信息。例如第一属性信息为exif信息中的标题信息,第二属性信息为exif信息中的主题信息。具体实施时,将用户选中的标签添加至主题信息对应的内容上。通过第二属性的设计,对图片的描述更为详细,便于图片的快速搜索。The second attribute information is one of exif attribute information, which is different from the first attribute information. For example, the first attribute information is title information in the exif information, and the second attribute information is topic information in the exif information. In specific implementation, a label selected by the user is added to the content corresponding to the topic information. Through the design of the second attribute, the description of the picture is more detailed, which facilitates the quick search of the picture.
步骤S28,当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息。In step S28, when the keywords entered by the user in the picture search interface are obtained, attribute information of all pictures in the gallery is queried to determine target attribute information matching the keywords.
步骤S29,显示所述目标属性信息对应的图片。Step S29: Display a picture corresponding to the target attribute information.
用户查找图片时,可在图片搜索界面输入关键字,终端根据该关键字查询图库中所有图片的属性信息,以查询该属性信息中包含有该关键字相的目标属性信息。并在当前界面上打开该目标属性信息对应的图片。When a user finds a picture, he can enter keywords in the picture search interface, and the terminal queries the attribute information of all pictures in the gallery according to the keyword to query the attribute information that contains the target attribute information of the keyword. And open the picture corresponding to the target attribute information on the current interface.
进一步的,作为本发明实施例的一种可实施的方式,在第二实施的基础上,步骤S25之后还包括步骤:Further, as an implementable manner of the embodiment of the present invention, on the basis of the second implementation, the method further includes steps after step S25:
步骤S31,当获取到存储所述图片的指令时,查询图库中预设的多个图片文件夹中,与所述主物体的类型名称对应的目标图片文件夹;Step S31: when an instruction for storing the picture is obtained, query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery;
步骤S32,将所述图片存储至所述目标图片文件夹中。In step S32, the picture is stored in the target picture folder.
本实施例中,终端的图库中预存有多个图片文件夹,该图片文件夹用于存放图片。该多个图片文件加与轮廓模型中的多个物体轮廓的类型名称一一对应,每个图片文件夹可以以对应的类型名称进行命名。当用户拍摄一张图片后进行保存时,终端根据识别到的该图片中主物体的类 型名称查询图库中对应的目标文件夹,并将该图片存储在该目标文件夹中。本实施例可自动对图片进行归类存储,用户查找图片时根据图片的主物体的类型名称在图库中找到对应的图片文件夹,再从找到的图片文件夹中找到该图片。In this embodiment, a plurality of picture folders are pre-stored in the gallery of the terminal, and the picture folders are used to store pictures. The multiple picture files are in one-to-one correspondence with the type names of multiple object outlines in the contour model, and each picture folder may be named with a corresponding type name. When the user takes a picture and saves it, the terminal searches the corresponding target folder in the gallery according to the type name of the main object in the picture, and stores the picture in the target folder. In this embodiment, pictures can be classified and stored automatically. When a user searches for a picture, a corresponding picture folder is found in the gallery according to the type name of the main object of the picture, and then the picture is found from the found picture folder.
可以理解的,在本发明的其他实施例中,用户保持图片时,可弹出各个预设的多个图片文件夹的标识,用户选择一标识,将图片保存在该标识对应的图片文件夹中。It can be understood that, in other embodiments of the present invention, when the user keeps the picture, the identifiers of multiple preset picture folders may pop up. The user selects an identifier and saves the picture in the picture folder corresponding to the identifier.
请参阅图4,为本发明第四实施例中的图片搜索装置,包括:Please refer to FIG. 4, which is a picture search apparatus according to a fourth embodiment of the present invention, including:
图像识别模块100,用于当检测到相机拍摄的一图片时,对所述图片进行图像识别,以确定所述图片中物体对应的类型名称;An image recognition module 100, configured to perform image recognition on a picture when a picture taken by a camera is detected to determine a type name corresponding to an object in the picture;
第一添加模块200,用于将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中;A first adding module 200, configured to add a type name corresponding to the object to attribute information of exif information of the picture;
第一查询模块300,用于当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息;The first query module 300 is configured to query attribute information of all pictures in a gallery when a keyword entered by a user in a picture search interface is obtained, to determine target attribute information matching the keyword;
第一显示模块400,用于显示所述目标属性信息对应的图片。The first display module 400 is configured to display a picture corresponding to the target attribute information.
进一步的,上述图片搜索装置,其中,所述第一添加模块200包括:Further, in the above image search device, the first adding module 200 includes:
判断模块,用于根据所述类型名称判断所述图片中的物体的类型数是否大于1;A judging module, configured to judge whether the number of types of objects in the picture is greater than 1 according to the type name;
确定模块,用于当所述图片中的物体的类型数大于1时,根据预设的优先级规则确定所述物体的优先级,并将优先级最高的一类型物体确定为主物体;A determining module, configured to determine the priority of the object according to a preset priority rule when the number of types of objects in the picture is greater than 1, and determine the type of object with the highest priority as the main object;
添加子模块,用于将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中。An adding sub-module is configured to add a type name corresponding to the main object to attribute information of exif information of the picture.
进一步的,上述图片搜索装置,其中,所述确定模块具体用于:Further, in the above picture search device, the determining module is specifically configured to:
分别计算所述图片中每个类型物体的总区域面积,并根据所述总区域面积确定各个类型的物体的优先级,所述总区域面积越大的一类物体其优先级越高。Calculate the total area area of each type of object in the picture, and determine the priority of each type of object according to the total area area. The type of object with a larger total area area has higher priority.
进一步的,上述图片搜索装置,还包括:Further, the above image search device further includes:
第二查询模块500,用于当获取到存储所述图片的指令时,查询图库中预设的多个图片文件夹中,与所述主物体的类型名称对应的目标图片文件夹;A second query module 500, configured to query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery when an instruction to store the picture is obtained;
存储模块600,用于将所述图片存储至所述目标图片文件夹中。The storage module 600 is configured to store the picture in the target picture folder.
进一步的,上述图片搜索装置,其中,所述属性信息包括第一属性信息和第二属性信息,所述第一添加模块200具体用于将所述物体对应 的类型名称添加至所述图片的exif信息的第一属性信息中;Further, in the above picture search device, wherein the attribute information includes first attribute information and second attribute information, the first adding module 200 is specifically configured to add a type name corresponding to the object to an exif of the picture The first attribute information of the information;
所述图片搜索装置还包括:The picture search device further includes:
第三查询模块700,用于查询与所述物体的类型名称所对应的标签信息表;A third query module 700, configured to query a tag information table corresponding to the type name of the object;
第二显示模块800,在当前界面显示所述标签信息表,所述标签信息表包括多个标签;The second display module 800 displays the tag information table on the current interface, where the tag information table includes multiple tags;
第二添加模块900,用于当获取到用户针对所述标签信息表中的至少一个标签的选中指令时,将所述用户选中的标签添加至所述exif信息的第二属性信息中。The second adding module 900 is configured to add a tag selected by the user to the second attribute information of the exif information when a user's selection instruction for at least one tag in the tag information table is obtained.
进一步的,上述图片搜索装置,其中,所述第二显示模块800具体用于:Further, in the above picture search device, the second display module 800 is specifically configured to:
在所述当前界面以预设的轨迹滚动显示所述标签信息表中的多个标签。A plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
进一步的,上述图片搜索装置,其中,图像识别模块100具体用于:Further, in the above picture search device, the image recognition module 100 is specifically configured to:
对所述图片进行轮廓划分,得到至少一轮廓信息;Performing contour division on the picture to obtain at least one contour information;
从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
本发明实施例所提供的图片搜索装置,其实现原理及产生的技术效果和前述方法实施例相同,为简要描述,装置实施例部分未提及之处,可参考前述方法实施例中相应内容。The implementation principle and technical effects of the picture search device provided by the embodiment of the present invention are the same as those of the foregoing method embodiments. For a brief description, the parts not mentioned in the device embodiments may refer to the corresponding content in the foregoing method embodiments.
本发明还提出一种可读存储介质,其上存储有计算机程序,该程序被处理器执行时实现上述的图片搜索方法。The present invention also proposes a readable storage medium on which a computer program is stored, and when the program is executed by a processor, the above-mentioned picture search method is implemented.
本本发明实施例还提供了一种终端,包括存储器、处理器以及存储在存储器上并可在处理器上运行的计算机程序,所述处理器执行所述程序时实现上述方法的步骤。An embodiment of the present invention further provides a terminal, which includes a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, the steps of the foregoing method are implemented.
在流程图中表示或在此以其他方式描述的逻辑和/或步骤,例如,可以被认为是用于实现逻辑功能的可执行指令的定序列表,可以具体实现在任何计算机可读介质中,以供指令执行系统、装置或设备(如基于计算机的系统、包括处理器的系统或其他可以从指令执行系统、装置或设备取指令并执行指令的系统)使用,或结合这些指令执行系统、装置或设备而使用。就本说明书而言,“计算机可读介质”可以是任何可以包含、存储、通信、传播或传输程序以供指令执行系统、装置或设备或结合这些指令执行系统、装置或设备而使用的装置。The logic and / or steps represented in the flowchart or otherwise described herein, for example, a sequenced list of executable instructions that can be considered to implement a logical function, can be embodied in any computer-readable medium, For instruction execution systems, devices, or devices (such as computer-based systems, systems including processors, or other systems that can fetch instructions from and execute instructions) Or equipment. For the purposes of this specification, a "computer-readable medium" may be any device that can contain, store, communicate, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device.
计算机可读介质的更具体的示例(非穷尽性列表)包括以下:具有一个或多个布线的电连接部(电子装置),便携式计算机盘盒(磁装置), 随机存取存储器(RAM),只读存储器(ROM),可擦除可编辑只读存储器(EPROM或闪速存储器),光纤装置,以及便携式光盘只读存储器(CDROM)。另外,计算机可读介质甚至可以是可在其上打印所述程序的纸或其他合适的介质,因为可以例如通过对纸或其他介质进行光学扫描,接着进行编辑、解译或必要时以其他合适方式进行处理来以电子方式获得所述程序,然后将其存储在计算机存储器中。More specific examples (non-exhaustive list) of computer-readable media include the following: electrical connections (electronic devices) with one or more wirings, portable computer cartridges (magnetic devices), random access memory (RAM), Read-only memory (ROM), erasable and editable read-only memory (EPROM or flash memory), fiber optic devices, and portable optical disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program can be printed, because, for example, by optically scanning the paper or other medium, followed by editing, interpretation, or other suitable Processing to obtain the program electronically and then store it in computer memory.
应当理解,本发明的各部分可以用硬件、软件、固件或它们的组合来实现。在上述实施方式中,多个步骤或方法可以用存储在存储器中且由合适的指令执行系统执行的软件或固件来实现。例如,如果用硬件来实现,和在另一实施方式中一样,可用本领域公知的下列技术中的任一项或他们的组合来实现:具有用于对数据信号实现逻辑功能的逻辑门电路的离散逻辑电路,具有合适的组合逻辑门电路的专用集成电路,可编程门阵列(PGA),现场可编程门阵列(FPGA)等。It should be understood that each part of the present invention may be implemented by hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods may be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it may be implemented using any one or a combination of the following techniques known in the art: Discrete logic circuits, application specific integrated circuits with suitable combinational logic gate circuits, programmable gate arrays (PGA), field programmable gate arrays (FPGA), etc.
在本说明书的描述中,参考术语“一个实施例”、“一些实施例”、“示例”、“具体示例”、或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本发明的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不一定指的是相同的实施例或示例。而且,描述的具体特征、结构、材料或者特点可以在任何的一个或多个实施例或示例中以合适的方式结合。In the description of this specification, the description with reference to the terms “one embodiment”, “some embodiments”, “examples”, “specific examples”, or “some examples” and the like means specific features described in conjunction with the embodiments or examples , Structures, materials, or features are included in at least one embodiment or example of the invention. In this specification, the schematic expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
以上所述实施例仅表达了本发明的几种实施方式,其描述较为具体和详细,但并不能因此而理解为对本发明专利范围的限制。应当指出的是,对于本领域的普通技术人员来说,在不脱离本发明构思的前提下,还可以做出若干变形和改进,这些都属于本发明的保护范围。因此,本发明专利的保护范围应以所附权利要求为准。The above-mentioned embodiments only express several implementation manners of the present invention, and their descriptions are more specific and detailed, but they cannot be understood as limiting the scope of the patent of the present invention. It should be noted that, for those of ordinary skill in the art, without departing from the concept of the present invention, several modifications and improvements can be made, which all belong to the protection scope of the present invention. Therefore, the protection scope of the invention patent shall be subject to the appended claims.

Claims (18)

  1. 一种图片搜索方法,其中,包括:An image search method, including:
    当检测到相机拍摄的一图片时,对所述图片进行图像识别,以确定所述图片中物体对应的类型名称;When a picture taken by the camera is detected, image recognition is performed on the picture to determine a type name corresponding to an object in the picture;
    将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中;Adding a type name corresponding to the object to attribute information of exif information of the picture;
    当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息;When a keyword entered by a user in the picture search interface is obtained, attribute information of all pictures in the gallery is queried to determine target attribute information matching the keyword;
    显示所述目标属性信息对应的图片。Display a picture corresponding to the target attribute information.
  2. 如权利要求1所述的图片搜索方法,其中,所述将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中的步骤包括:The picture search method according to claim 1, wherein the step of adding a type name corresponding to the object to attribute information of exif information of the picture comprises:
    根据所述类型名称判断所述图片中的物体的类型数是否大于1;Determining whether the number of types of objects in the picture is greater than 1 according to the type name;
    若是,根据预设的优先级规则确定所述物体的优先级,并将优先级最高的一类型物体确定为主物体;If yes, determine the priority of the object according to a preset priority rule, and determine the type of object with the highest priority as the main object;
    将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中。Adding the type name corresponding to the main object to the attribute information of the exif information of the picture.
  3. 如权利要求2所述的图片搜索方法,其中,所述根据预设的优先级规则确定所述物体的优先级的步骤包括:The picture search method according to claim 2, wherein the step of determining the priority of the object according to a preset priority rule comprises:
    分别计算所述图片中每个类型物体的总区域面积,并根据所述总区域面积确定各个类型的物体的优先级,所述总区域面积越大的一类物体其优先级越高。Calculate the total area area of each type of object in the picture, and determine the priority of each type of object according to the total area area. The type of object with a larger total area area has higher priority.
  4. 如权利要求2所述的图片搜索方法,其中,所述将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中的步骤之后还包括:The picture search method according to claim 2, wherein after the step of adding a type name corresponding to the main object to attribute information of exif information of the picture further comprises:
    当获取到存储所述图片的指令时,查询图库中预设的多个图片文件夹中,与所述主物体的类型名称对应的目标图片文件夹;When an instruction to store the picture is obtained, among a plurality of picture folders preset in the query gallery, a target picture folder corresponding to the type name of the main object;
    将所述图片存储至所述目标图片文件夹中。The picture is stored in the target picture folder.
  5. 如权利要求1所述的图片搜索方法,其中,所述属性信息包括第一属性信息和第二属性信息,所述将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中的步骤包括:The picture search method according to claim 1, wherein the attribute information includes first attribute information and second attribute information, and the type name corresponding to the object is added to attribute information of exif information of the picture The steps include:
    将所述物体对应的类型名称添加至所述图片的exif信息的第一属性信息中。Adding the type name corresponding to the object to the first attribute information of the exif information of the picture.
  6. 如权利要求5所述的图片搜索方法,其中,所述将所述物体对应的类型名称添加至所述图片的exif信息的第一属性信息中的步骤之后还包括:The picture search method according to claim 5, wherein after the step of adding a type name corresponding to the object to the first attribute information of exif information of the picture further comprises:
    查询与所述物体的类型名称所对应的标签信息表,并在当前界面显示所述标签信息表,所述标签信息表包括多个标签;Querying the tag information table corresponding to the type name of the object, and displaying the tag information table on the current interface, where the tag information table includes multiple tags;
    当获取到用户针对所述标签信息表中的至少一个标签的选中指令时,将所述用户选中的标签添加至所述exif信息的第二属性信息中。When a user's selection instruction for at least one tag in the tag information table is obtained, the tag selected by the user is added to the second attribute information of the exif information.
  7. 如权利要求6所述的图片搜索方法,其中,所述在当前界面显示所述标签信息表的步骤包括:The image search method according to claim 6, wherein the step of displaying the tag information table on the current interface comprises:
    在所述当前界面以预设的轨迹滚动显示所述标签信息表中的多个标签。A plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
  8. 如权利要求1所述的图片搜索方法,其中,所述对一图片进行图像识别,以确定所述图片中的物体对应的类型名称的步骤包括:The picture search method according to claim 1, wherein the step of performing image recognition on a picture to determine a type name corresponding to an object in the picture comprises:
    对所述图片进行轮廓划分,得到至少一轮廓信息;Performing contour division on the picture to obtain at least one contour information;
    从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
  9. 一种图片搜索装置,其中,包括:An image search device, including:
    图像识别模块,用于当检测到相机拍摄的一图片时,对所述图片进行图像识别,以确定所述图片中物体对应的类型名称;An image recognition module, configured to: when a picture taken by a camera is detected, perform image recognition on the picture to determine a type name corresponding to an object in the picture;
    第一添加模块,用于将所述物体对应的类型名称添加至所述图片的exif信息的属性信息中;A first adding module, configured to add a type name corresponding to the object to attribute information of exif information of the picture;
    第一查询模块,用于当获取用户在图片搜索界面中输入的关键字时,查询图库中所有的图片的属性信息,以确定与所述关键字匹配的目标属性信息;A first query module, configured to query attribute information of all pictures in a gallery when a keyword entered by a user in a picture search interface is obtained, to determine target attribute information matching the keyword;
    第一显示模块,用于显示所述目标属性信息对应的图片。The first display module is configured to display a picture corresponding to the target attribute information.
  10. 如权利要求9所述的图片搜索装置,其中,所述第一添加模块包括:The picture search apparatus according to claim 9, wherein the first adding module comprises:
    判断模块,用于根据所述类型名称判断所述图片中的物体的类型数是否大于1;A judging module, configured to judge whether the number of types of objects in the picture is greater than 1 according to the type name;
    确定模块,用于当所述图片中的物体的类型数大于1时,根据预设的优先级规则确定所述物体的优先级,并将优先级最高的一类型物体确定为主物体;A determining module, configured to determine the priority of the object according to a preset priority rule when the number of types of objects in the picture is greater than 1, and determine the type of object with the highest priority as the main object;
    添加子模块,用于将所述主物体对应的类型名称添加至所述图片的exif信息的属性信息中。An adding sub-module is configured to add a type name corresponding to the main object to attribute information of exif information of the picture.
  11. 如权利要求10所述的图片搜索装置,其中,所述确定模块具体用于:The picture search apparatus according to claim 10, wherein the determining module is specifically configured to:
    分别计算所述图片中每个类型物体的总区域面积,并根据所述总区域面积确定各个类型的物体的优先级,所述总区域面积越大的一类物体其优先级越高。Calculate the total area area of each type of object in the picture, and determine the priority of each type of object according to the total area area. The type of object with a larger total area area has higher priority.
  12. 如权利要求10所述的图片搜索装置,其中,还包括:The picture search device according to claim 10, further comprising:
    第二查询模块,用于当获取到存储所述图片的指令时,查询图库中预设的多个图片文件夹中,与所述主物体的类型名称对应的目标图片文件夹;A second query module, configured to query a target picture folder corresponding to the type name of the main object among a plurality of picture folders preset in the gallery when an instruction to store the picture is obtained;
    存储模块,用于将所述图片存储至所述目标图片文件夹中。A storage module, configured to store the picture in the target picture folder.
  13. 如权利要求9所述的图片搜索装置,其中,所述属性信息包括第一属性信息和第二属性信息,所述第一添加模块具体用于将所述物体对应的类型名称添加至所述图片的exif信息的第一属性信息中。The picture search device according to claim 9, wherein the attribute information includes first attribute information and second attribute information, and the first adding module is specifically configured to add a type name corresponding to the object to the picture The first attribute information of the exif information.
  14. 如权利要求9所述的图片搜索装置,其中,所述图片搜索装置还包括:The picture search apparatus according to claim 9, wherein the picture search apparatus further comprises:
    第三查询模块,用于查询与所述物体的类型名称所对应的标签信息表;A third query module, configured to query a tag information table corresponding to the type name of the object;
    第二显示模块,在当前界面显示所述标签信息表,所述标签信息表包括多个标签;A second display module that displays the tag information table on the current interface, where the tag information table includes multiple tags;
    第二添加模块,用于当获取到用户针对所述标签信息表中的至少一个标签 的选中指令时,将所述用户选中的标签添加至所述exif信息的第二属性信息中。A second adding module is configured to add a tag selected by the user to the second attribute information of the exif information when a user's selection instruction for at least one tag in the tag information table is obtained.
  15. 如权利要求14所述的图片搜索装置,其中,所述第二显示模块具体用于:The picture search device according to claim 14, wherein the second display module is specifically configured to:
    在所述当前界面以预设的轨迹滚动显示所述标签信息表中的多个标签。A plurality of tags in the tag information table are scrolled and displayed on the current interface with a preset track.
  16. 如权利要求9所述的图片搜索装置,其中,图像识别模块具体用于:The picture search device according to claim 9, wherein the image recognition module is specifically configured to:
    对所述图片进行轮廓划分,得到至少一轮廓信息;Performing contour division on the picture to obtain at least one contour information;
    从轮廓模型数据库中查询与所述轮廓信息匹配的物体轮廓,并获取所述物体轮廓对应的类型名称。Query the contour of the object matching the contour information from the contour model database, and obtain the type name corresponding to the contour of the object.
  17. 一种可读存储介质,其上存储有程序,其中,所述程序被处理器执行时实现如权利要求1-8任一所述的方法。A readable storage medium having a program stored thereon, wherein when the program is executed by a processor, the method according to any one of claims 1 to 8 is implemented.
  18. 一种终端,包括存储器、处理器以及存储在存储器上并可在处理器上运行的程序,其中,所述处理器执行所述程序时实现如权利要求1-8任意一项所述的方法。A terminal includes a memory, a processor, and a program stored on the memory and executable on the processor, wherein when the processor executes the program, the method according to any one of claims 1 to 8 is implemented.
PCT/CN2019/092128 2018-07-04 2019-06-20 Picture search method and device, readable storage medium, and terminal WO2020007201A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201810726385.8 2018-07-04
CN201810726385.8A CN109033237A (en) 2018-07-04 2018-07-04 Image searching method, device, readable storage medium storing program for executing and terminal

Publications (1)

Publication Number Publication Date
WO2020007201A1 true WO2020007201A1 (en) 2020-01-09

Family

ID=65521668

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2019/092128 WO2020007201A1 (en) 2018-07-04 2019-06-20 Picture search method and device, readable storage medium, and terminal

Country Status (2)

Country Link
CN (1) CN109033237A (en)
WO (1) WO2020007201A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113327285A (en) * 2021-07-30 2021-08-31 北京世纪好未来教育科技有限公司 Method and device for identifying picture shooting direction and electronic equipment thereof
CN115083572A (en) * 2022-07-25 2022-09-20 广州思德医疗科技有限公司 Picture storage and extraction method, system, device and medium

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109033237A (en) * 2018-07-04 2018-12-18 奇酷互联网络科技(深圳)有限公司 Image searching method, device, readable storage medium storing program for executing and terminal
CN109871460A (en) * 2019-01-23 2019-06-11 深圳市酷开网络科技有限公司 A kind of picture searching method, intelligent terminal and storage medium
CN109815354A (en) * 2019-01-25 2019-05-28 维沃移动通信有限公司 Picture management method, mobile terminal
CN111079485B (en) * 2019-05-17 2024-03-22 广东小天才科技有限公司 Dictation content acquisition method and learning equipment
CN111611416B (en) * 2019-05-22 2023-11-28 北京旷视科技有限公司 Picture retrieval method and device, electronic equipment and storage medium
CN110704658A (en) * 2019-10-15 2020-01-17 精硕科技(北京)股份有限公司 Method and device for searching image, computer storage medium and terminal
CN111027622B (en) * 2019-12-09 2023-12-08 Oppo广东移动通信有限公司 Picture label generation method, device, computer equipment and storage medium
CN111221782B (en) * 2020-01-17 2024-04-09 惠州Tcl移动通信有限公司 File searching method and device, storage medium and mobile terminal

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105243084A (en) * 2015-09-07 2016-01-13 广东欧珀移动通信有限公司 Photographed image file storage method and system and photographed image file search method and system
CN106445995A (en) * 2016-07-18 2017-02-22 腾讯科技(深圳)有限公司 Picture classification method and apparatus
CN107015998A (en) * 2016-01-28 2017-08-04 阿里巴巴集团控股有限公司 A kind of image processing method, device and intelligent terminal
CN109033237A (en) * 2018-07-04 2018-12-18 奇酷互联网络科技(深圳)有限公司 Image searching method, device, readable storage medium storing program for executing and terminal

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106055554A (en) * 2016-04-25 2016-10-26 珠海格力电器股份有限公司 Method, system and terminal for electronic phone album classification

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105243084A (en) * 2015-09-07 2016-01-13 广东欧珀移动通信有限公司 Photographed image file storage method and system and photographed image file search method and system
CN107015998A (en) * 2016-01-28 2017-08-04 阿里巴巴集团控股有限公司 A kind of image processing method, device and intelligent terminal
CN106445995A (en) * 2016-07-18 2017-02-22 腾讯科技(深圳)有限公司 Picture classification method and apparatus
CN109033237A (en) * 2018-07-04 2018-12-18 奇酷互联网络科技(深圳)有限公司 Image searching method, device, readable storage medium storing program for executing and terminal

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113327285A (en) * 2021-07-30 2021-08-31 北京世纪好未来教育科技有限公司 Method and device for identifying picture shooting direction and electronic equipment thereof
CN113327285B (en) * 2021-07-30 2022-07-01 北京世纪好未来教育科技有限公司 Method and device for identifying picture shooting direction and electronic equipment thereof
CN115083572A (en) * 2022-07-25 2022-09-20 广州思德医疗科技有限公司 Picture storage and extraction method, system, device and medium

Also Published As

Publication number Publication date
CN109033237A (en) 2018-12-18

Similar Documents

Publication Publication Date Title
WO2020007201A1 (en) Picture search method and device, readable storage medium, and terminal
US9171013B2 (en) System and method for providing objectified image renderings using recognition information from images
US10810252B2 (en) Searching using specific attributes found in images
US8649572B2 (en) System and method for enabling the use of captured images through recognition
US7809192B2 (en) System and method for recognizing objects from images and identifying relevancy amongst images and information
US7809722B2 (en) System and method for enabling search and retrieval from image files based on recognized information
US9367756B2 (en) Selection of representative images
EP2402867B1 (en) A computer-implemented method, a computer program product and a computer system for image processing
CN107870959A (en) Inquired about in response to video search and associated video scene is provided
TWI781554B (en) Method of determining item name of object, device, computer equipment and storage medium
CN106445995A (en) Picture classification method and apparatus
CN108702449B (en) Image searching method and system
CN105117399B (en) Image searching method and device
WO2017067485A1 (en) Picture management method and device, and terminal
JP2007094679A (en) Image analyzing device, image analyzing program and image analyzing program storage medium
EP1889207A2 (en) System and method for enabling the use of captured images through recognition
US20190095466A1 (en) Mixed type image based search results
CN108124478A (en) Picture searching method and apparatus
CN107491521A (en) A kind of image search system and method
WO2021196551A1 (en) Image retrieval method and apparatus, computer device, and storage medium
US20230196769A1 (en) Posting support apparatus, and posting support method
CN112148192A (en) Image display method and device and electronic equipment
JP2002007413A (en) Image retrieving device
KR101138873B1 (en) Method and apparatus for reducing the number of photo in photo album
CN116775924A (en) Image display control method, device and equipment

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 19830549

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 19830549

Country of ref document: EP

Kind code of ref document: A1