Article verification method and system based on surface texture image

Through the item verification system based on surface texture images, the problem of existing anti-counterfeiting technology that damages the appearance of goods and increases circulation costs is solved, achieving accurate verification of items and improving efficiency.

CN118537586APending Publication Date: 2024-08-23ANT BLOCKCHAIN TECHNOLOGY (SHANGHAI) CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410621185.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-17
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

Existing anti-counterfeiting technologies such as QR codes and passive induction tags will damage the appearance of the goods and increase circulation costs when used on goods, making it difficult to effectively verify the authenticity of goods.

Method used

An item verification system based on surface texture images is adopted. The image acquisition module and item registration module collect and extract the surface texture images and texture description information of pre-registered items in the registration stage. In the verification stage, the items to be verified are compared to determine whether they are Pre-registered items.

Benefits of technology

It achieves accurate verification of items without special processing or labeling, avoids damage to the appearance of goods and increases in circulation costs, while improving verification efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118537586A
    Figure CN118537586A
Patent Text Reader

Abstract

One or more embodiments of the invention provide an article verification method and system based on a surface texture image. The system comprises an image acquisition module which is used for indicating a registration party image acquisition device to respectively acquire pre-registered surface texture images for N pre-registered articles in a registration stage, wherein N is a positive integer; the image acquisition module is used for indicating a verifier image acquisition device to acquire a to-be-verified surface texture image for the to-be-verified article in a verification stage; the article registration module is used for indicating the server to acquire and maintain pre-registered texture description information extracted from N pre-registered surface texture images in a registration stage; the article verification module is used for indicating verification party equipment or a server to obtain to-be-verified texture description information extracted from the to-be-verified surface texture image in a verification stage, and verifying the to-be-verified texture description information according to a comparison result between the to-be-verified texture description information and N pieces of pre-registered texture description information; and determining whether the article to be verified is one of the N pre-registered articles.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] One or more embodiments of the present specification relate to the field of image processing technology, and more particularly, to an object verification method and system based on surface texture images. Background Art

[0002] Objects in the real world are usually unique and authentic, but some violators may seek profits by carrying out illegal acts that destroy the authenticity of objects. In order to avoid possible damage to interests caused by the above-mentioned acts, relevant parties will use anti-counterfeiting technology to ensure the authenticity of objects. For example, when selling goods, in response to other merchants manufacturing and selling counterfeit goods without the formal authorization of the brand owner or illegal acts such as cross-selling between different merchants, the brand owner, manufacturer or merchant and other relevant parties will post anti-counterfeiting accessories such as QR codes or passive sensing tags (such as RFID, NFC) for the goods to be sold, so that the relevant parties can verify the authenticity of the purchased goods through the corresponding anti-counterfeiting accessories (such as consumers can verify whether a certain product purchased is a genuine product of a certain brand, and a brand owner can verify whether the goods sold in its stores are cross-selling from other stores, etc.). However, the above-mentioned anti-counterfeiting accessories will not only damage the appearance of the goods and thus affect sales, but also increase the circulation cost of the goods. Summary of the invention

[0003] In view of this, one or more embodiments of this specification provide the following technical solutions:

[0004] According to a first aspect of one or more embodiments of this specification, a system for verifying an object based on a surface texture image is provided, the system comprising:

[0005] An image acquisition module, used to instruct the image acquisition device of the registration party to respectively acquire corresponding pre-registered surface texture images for N pre-registered objects during the registration phase, where N is a positive integer; and used to instruct the image acquisition device of the verification party to acquire the surface texture image to be verified for the object to be verified during the verification phase;

[0006] An item registration module, used to instruct the server to obtain and maintain pre-registered texture description information extracted from the N pre-registered surface texture images collected by the image acquisition module during the registration phase;

[0007] The object verification module is used to instruct the verification party device or the server to obtain the texture description information to be verified extracted from the surface texture image to be verified during the verification phase, and determine whether the object to be verified is one of the N pre-registered objects based on the comparison result between the texture description information to be verified and the N pre-registered texture description information.

[0008] According to a second aspect of one or more embodiments of this specification, a method for object verification based on a surface texture image is proposed. The method is applied to an object verification system including an image acquisition module, an object registration module, and an object verification module. The method includes:

[0009] The image acquisition module is used to instruct the image acquisition device of the registration party to respectively acquire corresponding pre-registered surface texture images for N pre-registered objects during the registration phase, where N is a positive integer; and to instruct the image acquisition device of the verification party to acquire the surface texture image to be verified for the object to be verified during the verification phase;

[0010] The object registration module instructs the server to obtain and maintain the pre-registered texture description information extracted from the N pre-registered surface texture images collected by the image acquisition module during the registration phase;

[0011] During the verification phase, the object verification module instructs the verification party device or the server to obtain the texture description information to be verified extracted from the surface texture image to be verified, and determines whether the object to be verified is one of the N pre-registered objects based on the comparison result between the texture description information to be verified and the N pre-registered texture description information.

[0012] According to a third aspect of the embodiments of this specification, there is also provided an electronic device, including a processor;

[0013] a memory for storing processor-executable instructions;

[0014] The processor implements the method described in the second aspect above by running the executable instructions.

[0015] According to a fourth aspect of the embodiments of this specification, a computer program product is provided, comprising a computer program, wherein when the computer program is executed by a processor, the steps of the method described in the second aspect are implemented.

[0016] According to a fifth aspect of the embodiments of this specification, a computer-readable storage medium is also provided, on which a computer program is stored, and when the program is executed by a processor, the steps in the method described in the second aspect are implemented.

[0017] The technical solutions provided by the embodiments of this specification may have the following beneficial effects:

[0018] As can be seen from the above embodiments, through the cooperation between the image acquisition module and the item registration module in the item verification system, N pre-registered items can be registered based on the pre-registered surface texture image and the pre-registered texture description information; and through the cooperation between the item registration module and the item verification module, it can be verified whether the item to be verified is the same item as one of the N items that have been registered based on the surface texture image to be verified and the texture description information to be verified, that is, whether the item to be verified is one of the N pre-registered items. Among them, the texture description information extracted from the surface texture image of any item can reflect the micro-texture features of the surface of the item, so the N pre-registered texture description information maintained by the item registration module in the registration stage can respectively reflect the micro-texture features of the surfaces of the N pre-registered items, and the texture description information to be verified extracted in the item verification stage can reflect the micro-texture features of the surface of the item to be verified. It can be seen that based on the micro-texture features of the item to be verified and the N pre-registered items, the verification of the item to be verified is achieved.

[0019] It can be understood that this solution only needs to collect images and accurately verify the items based on the micro-texture features of the items themselves. It does not require special processing of the items themselves, nor does it require anti-counterfeiting accessories such as QR codes or passive sensing tags to be posted on the items, thereby avoiding affecting or even damaging the appearance of the items, and also helping to reduce the circulation costs of the items.

[0020] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present specification. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] Figure 1 It is a schematic diagram of the hardware architecture of an object verification system provided by an exemplary embodiment.

[0022] Figure 2 It is a structural diagram of a registration party device provided by an exemplary embodiment.

[0023] Figure 3 It is a schematic structural diagram of an image acquisition device for a verification party provided by an exemplary embodiment.

[0024] Figure 4 It is a schematic diagram of the structure of a shooting component in an image acquisition device of a verification party provided by an exemplary embodiment.

[0025] Figure 5 It is a flowchart of a method for object verification based on surface texture images provided by an exemplary embodiment.

[0026] Figure 6 It is a structural schematic diagram of a device provided by an exemplary embodiment.

[0027] Figure 7 It is a block diagram of an object authentication device based on surface texture images provided by an exemplary embodiment.

[0028] Figure 8 It is a block diagram of a system for acquiring surface texture images of an object provided by an exemplary embodiment.

[0029] Fig. 9 It is a schematic structural diagram of a system for acquiring surface texture images of an object provided by an exemplary embodiment.

[0030] Fig.10 It is a schematic diagram of the positional relationship between an image acquisition device and a conveying device in an object surface texture image acquisition system provided by an exemplary embodiment.

[0031] Fig.11 It is a schematic diagram of the positional relationship among an image acquisition device, a target object and a conveying device in an object surface texture image acquisition system provided by an exemplary embodiment.

[0032] Fig.12 It is a flowchart of a control method of an object surface texture image acquisition system provided by an exemplary embodiment.

[0033] Fig.13 This is a schematic diagram of a scenario for identifying the authenticity of an object based on the texture features of the object, provided by an exemplary embodiment.

[0034] Fig.14a It is a schematic diagram of a texture feature extracted when the pixel precision is too large, provided by an exemplary embodiment.

[0035] Fig.14b It is a schematic diagram of a texture feature extracted when the pixel accuracy is too small, provided by an exemplary embodiment.

[0036] Fig.14c It is a schematic diagram of a texture feature extracted with appropriate pixel accuracy provided by an exemplary embodiment.

[0037] Fig.15 It is a flowchart of a method for determining pixel accuracy provided by an exemplary embodiment.

[0038] Fig.16 It is a schematic diagram of a curve showing a variation of the sum of square errors of a comprehensive similarity with pixel precision provided by an exemplary embodiment.

[0039] Fig.17 This is a schematic diagram of a scenario for verifying the source of an item provided by an exemplary embodiment.

[0040] Fig.18It is a structural diagram of a feature extraction model provided by an exemplary embodiment.

[0041] Fig.19 It is a structural diagram of another feature extraction model provided by an exemplary embodiment.

[0042] Fig. 20 It is a flowchart of a method for registering surface texture features provided by an exemplary embodiment.

[0043] Fig.21 It is a schematic diagram of a registration phase of a surface texture feature provided by an exemplary embodiment.

[0044] Fig. 22 It is a schematic diagram of the registration phase of another surface texture feature provided by an exemplary embodiment.

[0045] Fig.23 It is a schematic diagram of dividing a pre-registered surface texture image into pre-registered sub-images provided by an exemplary embodiment.

[0046] Fig.24 It is a flowchart of a surface texture image comparison method provided by an exemplary embodiment.

[0047] Fig.25 It is a schematic diagram of a surface texture image comparison process provided by an exemplary embodiment.

[0048] Fig.26 It is a schematic diagram of the matching process of the coarse matching sub-stage provided by an exemplary embodiment.

[0049] Fig. 27 It is a flowchart of a method for extracting surface texture features provided by an exemplary embodiment.

[0050] Fig.28 is a flow chart of a coarse screening method provided by an exemplary embodiment.

[0051] Fig.29 It is a schematic diagram of a process for collecting feature vectors for a surface texture image provided by an exemplary embodiment.

[0052] Fig.30 It is a schematic diagram of a process of determining a distance constraint condition for a subgraph provided by an exemplary embodiment.

[0053] Fig.31 It is a schematic diagram of a process for determining an angle constraint condition for a sub-image provided by an exemplary embodiment.

[0054] Fig.32 It is a schematic diagram of a process of determining common constraints for subgraphs provided by an exemplary embodiment.

[0055] Fig.33 It is a schematic diagram of a process for collecting feature vectors for a surface texture image provided by an exemplary embodiment.

[0056] Fig.34 It is a schematic diagram of a process for determining distance constraints for key points provided by an exemplary embodiment.

[0057] Fig.35 It is a schematic diagram of a process for determining angle constraints for key points provided by an exemplary embodiment.

[0058] Fig.36 It is a schematic diagram of a process for determining common constraint conditions for key points provided by an exemplary embodiment. DETAILED DESCRIPTION

[0059] Objects in the real world are usually unique and authentic, but some violators may seek profits by carrying out illegal acts that destroy the authenticity of objects. In order to avoid possible damage to interests caused by the above-mentioned acts, relevant parties will use anti-counterfeiting technology to ensure the authenticity of objects. For example, when selling goods, in response to other merchants manufacturing and selling counterfeit goods without the formal authorization of the brand owner or illegal acts such as cross-selling between different merchants, the brand owner, manufacturer or merchant and other relevant parties will post anti-counterfeiting accessories such as QR codes or passive sensing tags (such as RFID, NFC) for the goods to be sold, so that the relevant parties can verify the authenticity of the purchased goods through the corresponding anti-counterfeiting accessories (such as consumers can verify whether a certain product purchased is a genuine product of a certain brand, and a brand owner can verify whether the goods sold in its stores are cross-selling from other stores, etc.). However, the above-mentioned anti-counterfeiting accessories will not only damage the appearance of the goods and thus affect sales, but also increase the circulation cost of the goods.

[0060] In order to solve the above problems existing in the related art, the embodiment of this specification proposes an object verification solution based on surface texture image, so as to verify the object based on the surface texture image of the object (including the microscopic texture features of the surface of the object). The solution is described below with reference to the accompanying drawings.

[0061] The embodiment of this specification proposes an object verification system based on surface texture images, the system comprising:

[0062] An image acquisition module, used to instruct the image acquisition device of the registration party to respectively acquire corresponding pre-registered surface texture images for N pre-registered objects during the registration phase, where N is a positive integer; and used to instruct the image acquisition device of the verification party to acquire the surface texture image to be verified for the object to be verified during the verification phase;

[0063] An item registration module, used to instruct the server to obtain and maintain pre-registered texture description information extracted from the N pre-registered surface texture images collected by the image acquisition module during the registration phase;

[0064] The object verification module is used to instruct the verification party device or the server to obtain the texture description information to be verified extracted from the surface texture image to be verified during the verification phase, and determine whether the object to be verified is one of the N pre-registered objects based on the comparison result between the texture description information to be verified and the N pre-registered texture description information.

[0065] Among them, when N=1, this solution can achieve 1:1 verification of the object to be verified and the one pre-registered object; and when N>1, this solution can achieve 1:N verification of the object to be verified and the N pre-registered objects: it can not only determine whether the object to be verified is a pre-registered object, but also accurately determine which pre-registered object it is.

[0066] In addition, the N pre-registered items involved in the comparison can be set according to actual needs to achieve the corresponding verification results. For example, if the pre-registered items corresponding to the N pre-registered surface texture images involved in the comparison are compliant products produced by a certain manufacturer, then through verification, it can be determined whether the item to be verified is one of these products, that is, verify whether the item to be verified is a compliant product produced by the manufacturer, thereby completing the authenticity verification of the item. For another example, if the pre-registered items corresponding to the N pre-registered surface texture images involved in the comparison are a batch of goods sold by a certain brand and authorized by a certain store (the brand may also authorize other stores to sell the corresponding goods), then through verification, it can be determined whether the item to be verified is one of the batch of goods, that is, verify whether the item to be verified is transferred from other stores, thereby completing the verification of whether the item is a parallel transaction. Of course, it can also be applied to other scenarios, which will not be repeated.

[0067] From the functions of the above-mentioned devices, it can be seen that the item verification scheme implemented by the item verification system includes two stages, namely, the registration stage (for pre-registered items) and the verification stage (for items to be verified). Among them, the image acquisition module and the item registration module cooperate with each other to complete the registration stage, and the item registration module and the item verification module cooperate to complete the verification stage.

[0068] It should be noted that the various functional modules in the item verification system (such as the image acquisition module, the item registration module and the item verification module, as well as the height determination module, the adjustment control module, etc. described below) can be implemented by corresponding hardware devices. For example, the image acquisition function-related code can be run in the image acquisition device to be implemented as the above-mentioned image acquisition module; the item registration function-related code can be run in the server to be implemented as the above-mentioned registration module, which will not be repeated here.

[0069] Figure 1 FIG. 1 is a schematic diagram of the hardware architecture of an item verification system provided by an exemplary embodiment. Figure 1 As shown, the system may include a network 10, a server 11, and several electronic devices, such as a registration device 12, a verification device 13, etc. The registration device 12 may include a PC (Personal Computer) 121, a line scan camera 122, and a motor module 123, etc. The line scan camera 122 is used to collect the corresponding pre-registered surface texture image for the pre-registered object 14; the verification device 13 may include a mobile phone 131 and a handheld camera 132, etc. The handheld camera 132 is used to collect the corresponding surface texture image to be verified for the object to be verified 15.

[0070] The server 11 may be a physical server including an independent host, or the server 11 may be a virtual server carried by a host cluster. During operation, the server 11 may run a server-side program of a certain application to implement the relevant functions of the application. For example, when the server 11 runs a program for an item verification service, it may be implemented as a service platform for providing item verification services. For example, it may be used to maintain the item description information of the pre-registered item and its corresponding pre-registered texture description information, and to compare the texture description information to be verified with the pre-registered texture description information.

[0071] PC121 and mobile phone 131 are only some types of electronic devices that users can use. In fact, users can obviously also use electronic devices such as tablet devices, laptops, PDAs (Personal Digital Assistants), wearable devices (such as smart glasses, smart watches, etc.), etc., and one or more embodiments of this specification do not limit this. During operation, the electronic device can run a program on the client side of a certain application to implement the relevant functions of the application. For example, when the electronic device runs a program for an item verification service, it can be implemented as a client of the item verification service. For example, a registration party client can be run in PC121, and the relevant user (hereinafter referred to as the registration party user) can complete the registration of the item to be registered through the client (for the sake of simplicity, the embodiments of this specification refer to the items before and after the registration is completed as pre-registered items, but it should be understood that the items after the registration are completed can be regarded as items to be registered, and the items after the registration are completed become registered items); the verification party client can be run in the mobile phone 131, and the relevant user (hereinafter referred to as the verification party user) can verify the item to be verified through the client. Among them, the application program of the client of the item verification service can be started and run on the electronic device. The client-side program may be a native application installed on the electronic device, or the client-side program may be a small program, a quick application, or other similar forms. Of course, when using web technologies such as HTML5 or similar web pages, the relevant functions can be implemented through the pages displayed by the browser, and the browser here may be an independent browser application or a browser module embedded in some applications.

[0072] Understandably, Figure 1 The registration party device 12 shown includes a PC 121, a line scan camera 122 and a motor module 123, and the verification party device 13 includes a mobile phone 131 and a handheld camera 132. At this time, the registration party device 12 and the verification party device 13 can be regarded as small systems composed of corresponding devices, respectively. The following embodiments use this configuration as an example to illustrate the item verification scheme. However, it should be noted that in addition to the above-mentioned configuration, for any device in the registration party device 12 and the verification party device 13, the device can also be an independent single device with image acquisition function and related processing logic. For example, the verification party device 13 can be a handheld electronic device equipped with a high-precision camera, and the aforementioned verification party client can be run in the device, so that the verification party user can operate the client to collect the corresponding surface texture image to be verified for the item to be verified, and complete the verification of the item through interaction with the client, which will not be repeated.

[0073] For the network 10 for interaction between electronic devices such as PC 121, mobile phone 131 and server 11, a wired or wireless network can be selected based on the communication mode supported by the corresponding electronic device to achieve communication, and this specification does not limit this. For example, PC 121 can support both wired and wireless communication, so a wired or wireless network can be used to achieve communication as needed, while mobile phone 131 usually only supports wireless communication, so a wireless network can be used to achieve communication. In addition, it should be noted that Figure 1 The lightning symbol indicating the interaction between any two of PC 121, line scan camera 122 and motor module 123 is not connected to the network 10, but this is only for the convenience of reflecting the structural relationship between the three and the registration device 12 as a whole, and does not limit the interaction between the three to not be achieved through the network 10. In fact, PC 121, line scan camera 122 and motor module 123 can all have network connection functions and achieve interaction through the aforementioned network 10, which will not be repeated here.

[0074] The article described in this specification can be any article with a micro texture on the surface (whether the inner surface or the outer surface), such as leather with lychee pattern, porcelain with ice cracks, tiles with cloud-like patterns, oil paintings with fine cracks, etc. The surface texture image described in this specification is collected for the corresponding article, which naturally includes the above-mentioned micro texture on the surface of the article, that is, the pixel value of the image can represent the above-mentioned micro texture. For example, the surface texture image to be verified collected from the article to be verified has the micro texture of the surface of the article to be verified; the pre-registered surface texture image collected from any pre-registered article has the micro texture of the surface of the pre-registered article.

[0075] Exemplarily, in the aforementioned article verification system, the article registration module may be composed of Figure 1 The server 11 shown in the figure is implemented, and the image acquisition module acquires the pre-registered surface texture image during the registration phase. Figure 1 The registration device 12 shown in the figure can collect the surface texture image to be verified during the verification phase by Figure 1 The verification device 13 shown in the figure is implemented, and the item verification module can be Figure 1 The verification device 13 shown is used as an example to illustrate the process of implementing the item verification solution by the system.

[0076] The registration stage is described below with reference to the accompanying drawings:

[0077] For at least one item to be registered (in fact, the item can be regarded as an item to be registered before registration is completed, but to avoid cumbersome description, the embodiments of this specification collectively refer to them as pre-registered items), the registration party device can collect the pre-registered surface texture images of each item respectively, so as to facilitate the subsequent extraction of the corresponding pre-registered texture description information.

[0078] In one embodiment, the object verification system may also include a height determination module and an adjustment control module. The height determination module may be used to determine a target height according to the thickness of any pre-registered object for image acquisition; the target height is the sum of the thickness of the pre-registered object and the initial height, and the initial height is the distance between the registration party image acquisition device and the surface of the conveying device when the registration party image acquisition device meets the shooting conditions required for the pre-registered object and the surface of the conveying device is clearly focused; the adjustment control module may be used to control the posture control device to adjust the registration party image acquisition device to the target height. Based on this, the aforementioned image acquisition module may be specifically used to instruct the registration party image acquisition device to capture the corresponding registration surface texture image at the target height for any pre-registered object placed on the conveying device.

[0079] For example, the registrant device (which can be implemented as an image acquisition module) can include a registrant control device (which can be implemented as the height determination module), a registrant image acquisition device, and a posture control device (which can be implemented as the adjustment control module). Based on this, the registrant device collects the corresponding pre-registered surface texture image for any pre-registered object, which can be completed by the cooperation of the above-mentioned devices. Among them, the registration party control device is used to determine the target height according to the thickness of any pre-registered object whose image is to be captured, and the target height is the sum of the thickness of the pre-registered object and the initial height, and the initial height is the interval distance between the registration party image capture device and the surface of the conveying device when the registration party image capture device meets the shooting conditions required by the pre-registered object and the surface of the conveying device is clearly focused; then a height adjustment instruction can be generated and sent to the posture control device; the posture control device can adjust the registration party image capture device to the target height according to the received height adjustment instruction; and then the registration party image capture device can capture the corresponding registration surface texture image for any pre-registered object placed on the conveying device at the target height (that is, image capture is performed on any pre-registered object placed on the conveying device at the target height to obtain the pre-registered surface texture image).

[0080] like Figure 1As shown, the registrant device 12 includes a PC 121 (as a registrant control device), a line scan camera 122 (as a registrant image acquisition device) and a motor module 123 (as a posture control device). The above-mentioned devices can constitute the registrant device 12 through a specific mechanical structure and / or electrical connection. Figure 2 That is a schematic diagram of the structure of an exemplary registration party device 12.

[0081] like Figure 2 As shown, PC121 is used as the host computer of the OPC (Object Linking and Embedding for Process Control) server. In fact, in addition to the PC, the host computer may also include but is not limited to one or more of the following: a workstation, an industrial control integrated machine, a server, an embedded system, a single-chip microcomputer, an intelligent mobile terminal, etc. The pre-registered object 14 moves horizontally with the rotation of the conveying device. The line scanning light source installed on the equipment bracket can illuminate the pre-registered object 14, and the lighting can form a dark field illumination for the object so as to capture a clear pre-registered surface texture image. The motor module 123 may include a posture control PLC (Programmable Logic Controller) 1231, a lifting motor 1232 and a translation motor 1233. Among them, the posture control PLC1231 is connected to the PC121 for communication, and can receive control instructions from the PC121; the posture control PLC1231 is also connected to the lifting motor 1232 and the translation motor 1233, and can then drive the motor to rotate according to the control instructions to drive the line scan camera 122 to move, thereby adjusting the posture of the line scan camera 122 (such as adjusting it to a position where the pre-registered object 14 is in clear focus). In addition, the registration party device 12 can also include a linear velocity encoder 124 and a laser trigger 125, wherein the laser trigger 125 is used to detect whether there are objects to be captured on the transmission device, and the linear velocity encoder 124 is used to detect the moving speed of the objects on the transmission device in real time (actually the horizontal moving speed of the transmission device). The following takes any pre-registered object (hereinafter referred to as the target object) whose pre-registered surface texture image is to be captured as an example to illustrate the image capture process.

[0082] In one embodiment, the registrant may measure the thickness of the target object in advance and provide it to PC 121. For example, the target object thickness may be automatically measured by an ultrasonic thickness gauge or a laser range sensor installed on a transmission device, or may be obtained by manual measurement. The measured object thickness information may be sent to PC 121.

[0083] PC121 can determine the target height of the line scan camera 122 based on the acquired target object thickness and the initial height of the line scan camera 122 when the shooting conditions required for the target object are met and the surface of the conveyor is clearly focused, and generate a corresponding height adjustment instruction to send to the attitude control PLC1231. The shooting conditions may include conditions for the pixel accuracy of the image to be captured, and may also include but are not limited to: object brightness conditions, object area conditions, etc. The object brightness conditions may be conditions for at least ensuring that the target object can be clearly photographed, and the object area conditions may be conditions for at least ensuring that the area of ​​the target object can be completely captured by the line scan camera 122. The pixel accuracy described in the embodiments of this specification generally refers to the precise measurement of the actual physical size represented by each pixel in the image or the resolution of the real world in the field of image processing, photography and display technology. The conveyor may be a conveyor belt for conveying the target object, so the surface of the conveyor is in contact with the bottom surface of the target object. After the target object is placed on the conveyor, the height difference between the line scan camera 122 and the target object is the difference between the initial height and the thickness of the target object. In order to avoid changes in the shooting conditions of the line scan camera 122 and to avoid the need for the line scan camera 122 to refocus, the sum of the initial height and the thickness of the target object can be used as the target height (i.e., target height h3 = initial height h1 + target object thickness h2), and the height adjustment instruction instructs the posture control PLC1231 to control the lifting motor 1232 to rotate, driving the line scan camera 122 to rise to the target height. At this time, the line scan camera 122 can capture images of the target object (i.e., the pre-registered object 14) placed on the conveyor to obtain the pre-registered surface texture image of the object.

[0084] It is understandable that, because the line scan camera 122 has already clearly focused on the surface of the conveyor at the initial position, the line scan camera 122 can achieve clear focus on the surface of the target object (thickness of the aforementioned h2) without adjusting parameters after rising to the target height. In this way, the control device 12 can ensure clear focus to ensure stable image acquisition quality, and can also adaptively adjust the height of the image acquisition device of the registration party according to the actual thickness of the pre-registered object, which not only helps to avoid the inefficiency and high complexity caused by manual adjustment of the camera height, improves image acquisition efficiency, but also avoids the situation where the image acquisition quality is unstable due to possible deviations in manual adjustment.

[0085] In one embodiment, the image acquisition module may also include a focus control module, which can be used to determine the target pixel accuracy required for image acquisition when the shooting conditions include pixel accuracy, and determine the initial height according to the target pixel accuracy and the device parameters of the registration party image acquisition device; and control the posture control device to adjust the registration party image acquisition device to the initial height, and obtain the adjustment completion message generated by the posture control device to trigger the registration party image acquisition device to focus.

[0086] For example, the registration party control device (implemented as a focus control module in this case) can also determine the target pixel accuracy required for image acquisition when the shooting conditions include pixel accuracy, determine the initial height according to the target pixel accuracy and the device parameters of the registration party image acquisition device, and send the initialization adjustment instruction corresponding to the initial height to the posture control device; accordingly, the posture control device can adjust the registration party image acquisition device to the initial height according to the received initialization adjustment instruction, and feed back the generated adjustment completion message to the registration party control device to trigger the registration party control device to send the focus instruction to the registration party image acquisition device; and then the registration party image acquisition device can focus according to the focus instruction.

[0087] Still Figure 1 and Figure 2 For example, when the shooting conditions include pixel accuracy, PC121 needs to determine the target pixel accuracy at which the image is collected before controlling the line scan camera 122 to capture an image. For example, the target pixel accuracy temporarily specified by the registrant user (such as manually input or selected from the alternative accuracies displayed by PC121) can be determined, or the required target pixel accuracy can be automatically determined according to a pre-established camera control strategy. Thereafter, PC121 can determine the initial height according to the target pixel accuracy and the device parameters of the line scan camera 122. Optionally, PC121 can calculate the initial height based on the device parameters such as the focal length and pixels of the line scan camera 122, and use the initial height as the default height of the line scan camera 122. Furthermore, an initialization adjustment instruction corresponding to the initial height can be generated, and the instruction can be sent to the motor module 123 (such as Figure 2 As shown, it can be sent to the attitude control PLC1231).

[0088] When the attitude control PLC1231 receives the initialization adjustment instruction, it can adjust the height of the line scan camera 122 according to the initial height indicated in the instruction, such as sending a rotation control signal corresponding to the initial height to the lifting motor 1232 connected to the line scan camera 122 to control its rotation and drive the line scan camera 122 to move to the initial height. After determining that the line scan camera 122 has moved to the initial height, the attitude control PLC1231 can generate and send an adjustment completion message to PC121, which is used to indicate to the latter that the line scan camera 122 has been adjusted to the initial height. In addition, after the adjustment of the line scan camera 122 is completed, the attitude control PLC1231 can also control the electromagnetic locking of the current position of the camera to avoid displacement and inaccurate focusing.

[0089] In response to the received adjustment completion message, PC121 may generate a focus instruction for instructing the line scan camera 122 to focus, and send the focus instruction to the line scan camera 122 through the communication channel (wired or wireless channel) between the line scan camera 122. Accordingly, the line scan camera 122 may respond to the received focus instruction and focus according to the instruction, so that the line scan camera 122 can focus on an object at an initial height from itself and take a clear picture of it. Among them, the focus instruction may also include some control parameters for the line scan camera 122, which will not be repeated.

[0090] For the collected pre-registered surface texture image, it is necessary to extract the corresponding pre-registered texture description information from the image so as to register the pre-registered object.

[0091] In one embodiment, the pre-registered texture description information can be extracted by the server. For example, the registrant device (specifically, the aforementioned registrant control device, such as PC121) can send the collected N pre-registered surface texture images to the server. Exemplarily, each image can be sent to the server, or it can be sent to the server once after the N images are collected, or it can be sent in batches according to a preset number, such as when N=1000 or N is unknown, it can be sent every 10 or 100 images, which will not be repeated. Upon receiving the aforementioned pre-registered surface texture image uploaded by the registrant device, the server can extract the corresponding pre-registered texture description information therefrom. Corresponding to the aforementioned sending of the image, the server can also extract the information when receiving the image, or it can also perform batch extraction when multiple images are received, and the embodiments of this specification do not limit this. It is understandable that the image feature extraction process can be implemented using a pre-trained feature extraction model. Given that the resources required to run such models (such as storage resources, computing resources, etc.) are often large, uploading the image to a server with strong computing power can achieve efficient extraction of pre-registered texture description information, and also help to implement a lightweight client on the registrant device side.

[0092] In another embodiment, the registrant device may also extract the pre-registered texture description information by itself. For example, the registrant device may extract the corresponding pre-registered texture description information from the collected N pre-registered surface texture images and send it to the server; correspondingly, the server may receive the pre-registered texture description information sent by the registrant device. Similar to the previous embodiment, when the registrant device uploads the pre-registered texture description information extracted by itself, it may also upload it one by one or in batches, which will not be described in detail.

[0093] Among them, the pre-registered texture description information described in the embodiments of this specification may include multiple forms. Taking the pre-registered texture description information of any pre-registered surface texture image as an example, it may include the pre-registered key point description information (such as quantity, key point coordinates, etc.) of each pre-registered key point identified from the image; and, in the case where the image is divided into multiple pre-registered sub-images according to a preset size, the pre-registered texture description information may also include the pre-registered sub-image position information of each pre-registered sub-image and the pre-registered aggregated feature vectors corresponding to each pre-registered sub-image. The specific functions of the above-mentioned various information can be found in the embodiments of step 508 below, which will not be repeated here. When maintaining the above-mentioned pre-registered texture description information, the server may specifically save the above-mentioned vector and other information in a vector database for subsequent retrieval.

[0094] In addition, in addition to obtaining and maintaining the pre-registered texture description information, the server can also obtain and maintain the item description information of the pre-registered item corresponding to the pre-registered surface texture image. Exemplarily, the item description information of any item may include an item unique identifier (ID), and may also include relevant information such as brand, manufacturer, and production date, which will not be repeated here. In this regard, when maintaining the pre-registered texture description information extracted from any pre-registered surface texture image, the server can maintain the mapping relationship between the item description information of the pre-registered item corresponding to the image and the pre-registered texture description information, such as using the item unique identifier as an information index to maintain the above two types of information so that they can be quickly retrieved during subsequent comparisons.

[0095] It is understandable that the server successfully maintains the pre-registered texture description information of N pre-registered items (or the pre-registered texture description information and its corresponding item description information), that is, the registration of these N pre-registered items is completed. It is understandable that the pre-registered texture description information of each pre-registered item corresponds to the corresponding item one by one, and the pre-registered texture description information of any item can be regarded as the microscopic fingerprint of the item, which can be used to compare and verify whether the item to be verified is a pre-registered item in the future.

[0096] Next, the verification stage is described with reference to the accompanying drawings:

[0097] In one embodiment, the verification party device may include a verification party control device and a verification party image acquisition device, wherein the verification party image acquisition device is used to acquire a surface texture image to be verified for the object to be verified, and send the acquired surface texture image to be verified to the verification party control device. Figure 1 As shown, the verification party device includes a verification party control device and a verification party image acquisition device, wherein the verification party image acquisition device is used to acquire the corresponding surface texture image to be verified for the verification party item, and send the acquired surface texture image to be verified to the verification party control device; the verification party control device is used to interact with the server 11 and the verification party image acquisition device.

[0098] In one embodiment, the image acquisition device of the verification party may be a portable device, so that the verification party can operate the device to collect the corresponding surface texture image of the object to be verified. The device may be composed of multiple components, such as a shooting component and a light shielding component. The complete side view of the two components can be seen in Figure 3. The shading component may include a shell and a light-emitting part (such as a plurality of LED lamp beads or a light strip, etc.), and a hollow part is formed inside the shell for placing the object to be verified; the light-emitting part may be arranged on the inner wall of the shell so that the light it emits is directed toward the field of view of the camera module (such as the position at the bottom of the hollow part for placing the object to be verified) to achieve a high-quality lighting effect. Through the structure of the above-mentioned shell and light source, a dark field can be constructed for the object to be photographed, so as to improve the quality of the captured image.

[0099] The shooting component includes a camera module and a connecting mechanism, the camera module is used to complete image acquisition, and the connecting mechanism is used to connect with the connecting mechanism at the corresponding position on the shading component to achieve close cooperation between the two. The connecting mechanism can be in any form such as a buckle, a screw / nut, an internal / external thread, etc., and the embodiments of this specification are not limited to this. It can be understood that the connection method in which the two cooperate with each other allows the same shooting component to replace shading components of different sizes, so as to facilitate image acquisition for objects to be verified of different sizes, thereby improving the versatility of the image acquisition device of the verification party.

[0100] in, Figure 4 The top view, top view and side view of the above-mentioned shooting component are shown. As shown in the top view, a light control connector is provided on the shooting component housing, and a cable can be used to connect the light source in the light-emitting component through the connector. As shown in the side view and the side view, a control device interface (such as a USB Type C interface) can be provided on the shooting component so that a cable (such as a USB Type C cable) can be used to connect to the light source through the interface. Figure 1 The mobile phone 131 shown. Of course, the shooting component can also have a built-in wireless communication module to establish a wireless connection with the mobile phone 131, thereby avoiding the inconvenience caused by wired connection. As shown in the side view, a transparent glass cover is provided under the camera module to prevent dust, water droplets, etc. at the shooting scene from contaminating the camera, which not only avoids damage to the camera but also helps to ensure image quality. The main board and heat conduction plate above the camera module are used to control the normal operation of the camera module. It should also be noted that Figure 4 The 60mm and 40mm shown in the top view, top view and side view are only exemplary illustrations of the size of the shooting component, and do not limit the shooting component to this size. In actual use, it can be flexibly set according to specific conditions such as the size of the object, and the embodiments of this manual do not limit this.

[0101] In one embodiment, the item verification system may further include an information extraction and sending module, which may be used to extract corresponding texture description information to be verified from the surface texture image to be verified acquired by the verification party image acquisition device, and send it to the item registration module. Alternatively, the item verification system may further include an image sending module, which may be used to send the surface texture image to be verified acquired by the verification party image acquisition device to the item registration module, and in this case, the item registration module may also be used to extract corresponding texture description information to be verified from the received surface texture image to be verified. For example, the verification party device may include a verification party control device and a verification party image acquisition device, wherein the verification party image acquisition device is used to acquire the surface texture image to be verified for the item to be verified, and send the acquired image to the verification party control device; correspondingly, the verification party control device is used to receive the image. Figure 1 As shown, the verification party control device and the verification party image acquisition device can be a mobile phone 131 and a handheld camera 132 respectively, wherein the user can use the handheld camera 132 to capture the surface texture image of the object to be verified and send it to the mobile phone 131.

[0102] Among them, the image acquisition module can be specifically used to control the verification party image acquisition device to independently acquire the texture image of the surface to be verified without being controlled by other devices (in this case, the module can be implemented by the verification party image acquisition device itself). For example, the verification party image acquisition device itself can independently complete image acquisition without the control of other devices, and in this case, the acquisition process of the texture image of the surface to be verified does not require the intervention of the verification party control device. For example, the verification party user can adjust the shooting parameters in the handheld camera 132 to complete the focus, and manually shoot to obtain the texture image of the surface to be verified; or, if the handheld camera 132 itself has control logic, the verification party user can operate the camera to automatically complete image acquisition.

[0103] Alternatively, the acquisition module can also be specifically used to control the verification party image acquisition device to acquire the texture image of the surface to be verified according to the image acquisition instruction sent by other devices (in this case, the module can be implemented by the aforementioned verification party control device). For example, the verification party image acquisition device can also receive the image acquisition instruction sent by the verification party control device, and then acquire the texture image of the surface to be verified according to the instruction. In this case, the verification party image acquisition device needs to complete the image acquisition under the control of the verification party control device (that is, it needs to acquire the image according to the aforementioned image acquisition instruction). It can be understood that, compared with the verification party image acquisition device whose core function is image acquisition, the verification party control device can realize richer software functions, and therefore can also be used to perform richer and more precise control over the verification party image acquisition device.

[0104] like Figure 1 As shown, the user of the verification party can independently operate the handheld camera 132 to collect the texture image of the surface to be verified, or can establish a connection between the mobile phone 131 and the handheld camera 132 (such as Figure 3 or Figure 3 In the case of a Type C wired connection as shown, the image is captured by controlling the handheld camera 132 through the mobile phone 131.

[0105] In one embodiment, the object verification system may further include an information display module, which may be used to display operation prompt information for the verification party image acquisition device, so as to prompt the verification party user to operate the verification party image acquisition device in accordance with a preset operation mode to acquire the surface texture image to be verified. For example, regardless of whether the verification party image acquisition device (the device is used to implement the information display module at this time) performs image acquisition under the control of the verification party control device, the verification party control device may be used to display operation prompt information for the verification party image acquisition device, so as to prompt the verification party user to operate the verification party image acquisition device in accordance with a preset operation mode to acquire the surface texture image to be verified. Among them, the operation prompt information may include focus position indication information (used to instruct the user to focus the device on which position of the object to be verified), camera parameter indication information (such as aperture, shutter, exposure time, etc., used to instruct the user to accurately adjust the camera parameters to acquire higher quality images), light source parameters (such as brightness, illumination angle, etc., used to instruct the user to create a higher quality light scene for the object to be verified), number of shots (multiple images can be taken continuously and the best one is selected as the surface texture image to be verified), etc., which will not be repeated one by one. The user on the verification side can operate the verification side image acquisition device in the preset operation mode indicated by the above operation prompt information to acquire high-quality texture images of the surface to be verified, thus laying a good data foundation for obtaining accurate comparison results later.

[0106] After acquiring the surface texture image to be verified, the verification party's image acquisition device can provide the image to the verification party's control device. For example, the image can be sent based on a wired connection or a wireless connection, or the image can be transferred to a storage medium such as a U disk or an SD card.

[0107] Furthermore, the control device of the verification party may also send the received surface texture image to be verified to the server, so that the server can extract the corresponding texture description information to be verified from the received image. Alternatively, the control device of the verification party may also extract the corresponding texture description information to be verified from the received surface texture image to be verified and send it to the server. Accordingly, the server can directly obtain the description information and quickly start the comparison. Figure 1As shown, after the mobile phone 131 obtains the texture image of the surface to be verified, it can directly extract the corresponding texture description information to be verified locally, or send it to the server 11 so that the server can extract the corresponding texture description information to be verified.

[0108] As mentioned above, the verification device can extract the texture description information to be verified by itself and send it to the server. However, it should be noted that this embodiment is based on the premise that the server performs information comparison (i.e., compares the texture description information to be verified with the N pre-registered texture description information). In other words, if the subsequent information comparison is completed by the verification device itself, the verification device naturally does not need to send the information to the server.

[0109] At this point, the image acquisition and information extraction in the verification phase are completed. Next, the server or the verification device can perform information comparison, that is, compare the N pre-registered texture description information maintained by the server (extracted in the registration phase) and the texture description information to be verified extracted in the verification phase, so as to determine whether the object to be verified is one of the aforementioned N pre-registered objects based on the comparison results.

[0110] In one embodiment, the texture description information described in the embodiment of this specification may be an overall texture feature vector directly extracted from the entire surface texture image to be verified. At this time, the vector distance, vector similarity and other indicators between the overall texture feature vector to be verified and a pre-registered overall texture feature vector may be calculated to determine the degree of similarity between the surface texture image to be verified and each pre-registered surface texture image to be verified; if the similarity corresponding to any pre-registered surface texture image to be verified is greater than the similarity threshold, it can be determined that the image matches the surface texture image to be verified, indicating that the object to be verified and the pre-registered object corresponding to the image are the same object. At this time, there is no need to compare the remaining pre-registered objects.

[0111] In another embodiment, the texture description information may be local texture features extracted from multiple small areas in the image. At this time, each local texture feature in the pre-registered surface texture image to be verified can be cross-compared with each local texture feature in each surface texture image to be verified to determine the final comparison result. However, since the surface texture image to be verified may contain a large amount of micro-textures, the comparison process of this method is usually computationally intensive, which not only requires high computing power for the verification party (such as the buyer of the product), making it difficult for ordinary buyers to apply; but also the verification efficiency is low, making it difficult to achieve batch verification.

[0112] In this regard, the embodiments of this specification propose an image comparison scheme including a coarse screening stage, a fine screening stage and a comparison stage. At least one of the coarse screening stage and the fine screening stage can filter the feature vector based on the geometric consistency constraint condition to reduce the amount of calculation while ensuring the accuracy of verification and improve the verification efficiency. Geometric consistency refers to the property in geometry that the relationship between two or more geometric objects remains unchanged. In short, geometric consistency describes the ability of a set of geometric objects to maintain similarity and relative position after transformation (such as rotation, translation or scaling). In this scheme, the relative position relationship between different subgraphs (and / or different key points) is verified by geometric consistency constraints.

[0113] In one embodiment, the object verification system may further include a sub-image division module, which may be used to divide the pre-registered surface texture image according to a preset size to obtain pre-registered sub-images, and for each pre-registered sub-image: determine the pre-registered sub-image position information of the pre-registered sub-image in the pre-registered surface texture image to which it belongs, identify the pre-registered key points in the pre-registered sub-image, and extract the pre-registered key point description information of each pre-registered key point and the pre-registered aggregate feature vector corresponding to the pre-registered sub-image based on the recognition result; the object registration module is specifically used to associate the pre-registered sub-image position information, pre-registered key point description information and pre-registered aggregate feature vector corresponding to each pre-registered sub-image obtained by dividing the pre-registered surface texture image with each pre-registered sub-image and save them in a vector database; the object verification module is specifically used to: intercept the sub-image to be verified from the surface texture image to be verified through the sliding window of the preset size, and for each sub-image to be verified: determine the sub-image position information of the sub-image to be verified in the surface texture image to be verified, identify the key points to be verified in the sub-image to be verified, and extract the key points to be verified of each key point to be verified based on the recognition result. The method comprises the following steps: first, determining the key point description information of the to-be-verified object and the aggregated feature vector of the to-be-verified subgraph; second, determining the key point description information of the to-be-verified object and the aggregated feature vector of the to-be-verified subgraph; third, determining the key point description information of the to-be-verified object and the aggregated feature vector of the to-be-verified subgraph; fourth, determining the key point description information of the to-be-verified object corresponding to the key point to-be-verified object identified from the to-be-verified surface texture image and the aggregated feature vector of the to-be-verified subgraph; fourth, determining the preregistered key point description information of the preregistered key point identified from each preregistered surface texture image respectively; fifth, determining whether the to-be-verified object is one of the N preregistered objects according to the comparison result between the key point description information of the to-be-verified object and the preregistered key point description information.

[0114] For example, the texture description information may include sub-image position information, key point description information and aggregate feature vectors, that is, the pre-registered texture description information includes pre-registered sub-image position information, pre-registered key point description information and pre-registered aggregate feature vectors, and the texture description information to be verified includes sub-image position information to be verified, key point description information to be verified and aggregate feature vectors to be verified. In this scenario, it is necessary to briefly explain the method of extracting the above texture description information:

[0115] The registration party device or server divides the pre-registered surface texture image according to a preset size to obtain pre-registered sub-images, and for each pre-registered sub-image: the pre-registered sub-image position information of the pre-registered sub-image in the pre-registered surface texture image to which it belongs (such as the coordinates of the pre-registered sub-image in the image relative to the image origin) can be determined, the pre-registered key points in the pre-registered sub-image are identified, and based on the identification result, the pre-registered key point description information of each pre-registered key point (such as the pre-registered key point position information used to characterize the position of the pre-registered key point in the image and the pre-registered key point feature vector used to characterize the micro-texture features of the pre-registered key point and its surrounding local area) and the pre-registered aggregate feature vector corresponding to the pre-registered sub-image (used to characterize the overall micro-texture features of the pre-registered sub-image) are extracted. Among them, for any pre-registered sub-graph, for each pre-registered key point identified in the sub-graph, the key point feature vector to be verified and its credible score of each pre-registered key point can be determined (wherein, the size of the credible score of any pre-registered key point is proportional to the accuracy / credibility of the pre-registered key point recognition result, that is, the larger the credible score of any pre-registered key point identified, the greater the possibility that the key point actually exists in the pre-registered sub-graph), and then at least a part of the pre-registered key points whose credible scores are not less than the score threshold are determined, and the pre-registered key point feature vectors corresponding to the at least part of the key points to be verified are aggregated to obtain the pre-registered aggregated feature vector corresponding to the pre-registered sub-graph. Next, the server can associate the pre-registered sub-graph position information, pre-registered key point description information and pre-registered aggregated feature vector corresponding to each pre-registered sub-graph obtained by dividing each pre-registered surface texture image and save them in the vector database. It can be understood that for any pre-registered surface texture image to be verified, the above-mentioned information corresponding to each pre-registered sub-image obtained by dividing the image (i.e., a set of pre-registered sub-image position information, pre-registered key point description information and pre-registered aggregated feature vector) together constitute the pre-registered texture description information extracted from the image.

[0116] Similarly, during the verification stage, the server or the verification device can intercept the sub-image to be verified from the surface texture image to be verified through the sliding window of the preset size, and then for each sub-image to be verified: determine the sub-image position information of the sub-image to be verified in the surface texture image to be verified (such as the coordinates of the sub-image to be verified in the image relative to the image origin), identify the key points to be verified in the sub-image to be verified, and extract the key point description information to be verified of each key point to be verified based on the recognition result (such as the key point position information to be verified used to characterize the position of the key point to be verified in the image and the key point feature vector to be verified used to characterize the micro-texture features of the key point to be verified and its nearby local area) and the aggregated feature vector to be verified of the sub-image to be verified (used to characterize the overall micro-texture features of the sub-image to be verified).

[0117] Furthermore, for each aggregated feature vector to be verified: a group of pre-registered aggregated feature vectors with the highest vector similarity with the aggregated feature vector to be verified can be retrieved from the vector database, and the aggregated feature vector to be verified and each feature vector in the group of pre-registered aggregated feature vectors respectively constitute an aggregated vector pair. Then, according to the position information of each sub-graph to be verified and each pre-registered sub-graph in the corresponding surface texture image, the target aggregated vector pair of the corresponding sub-graph that meets the geometric consistency constraint condition is screened out from the aggregated vector pair formed by the aggregated feature vector to be verified, and at least a part of the pre-registered surface texture image corresponding to the target aggregated vector pair is recalled. Among them, the surface texture image can include distance constraints (used to constrain the distance between the positions of two sub-graphs), angle constraints (used to constrain the angle formed by the line connecting the positions of three sub-graphs) and common constraints (used to constrain the distance of the coordinates of a sub-graph relative to the origin, and the angle of the line connecting the origin), etc. Finally, the key point description information to be verified corresponding to the key point to be verified identified from the surface texture image to be verified and the pre-registered key point description information corresponding to the pre-registered key points identified from each recalled pre-registered surface texture image are obtained, and based on the comparison result between the key point description information to be verified and the pre-registered key point description information, it is determined whether the object to be verified is one of the N pre-registered objects.

[0118] This embodiment proposes to filter feature vectors using vector similarity and geometric consistency constraints in the coarse screening stage: for the aggregated feature vectors to be verified of each sub-graph extracted from each sub-graph of the surface texture image to be verified, a group of pre-registered aggregated feature vectors with the highest similarity will be screened out from the pre-registered aggregated feature vectors stored in the vector database to form an aggregated vector pair with the aggregated feature vector to be verified, and then the target aggregated vector pair of the corresponding sub-graph that meets the geometric consistency constraint will be screened out from all aggregated vector pairs according to the position information of the sub-graph in the surface texture image, and at least a portion of the corresponding pre-registered surface texture images will be recalled. Furthermore, in the fine screening stage and the comparison stage, for this part of the pre-registered surface texture images recalled in the coarse screening stage, the comparison result between the description information of the key points to be verified and the description information of the pre-registered key points (corresponding to the pre-registered key points in this part of the pre-registered surface texture images) will be used to determine whether there is a pre-registered surface texture image that matches the surface texture image to be verified, so as to complete the comparison.

[0119] The embodiments of this specification realize verification of the object to be verified by comparing the surface texture image to be verified with the pre-registered surface texture image. The above verification stage is based on the following general rule: the surface texture image collected from the object can reflect the microscopic texture of the surface of the object. For any two identical surface texture images and any two sub-images respectively captured from the two images, if the positions of the two sub-images in the corresponding images are the same (or close), then the surface textures of the two sub-images are also the same (or close). This scheme characterizes the overall micro-texture of the sub-graph through the aggregated feature vector corresponding to the sub-graph. It can be understood that: for the aggregated feature vector to be verified collected from each sub-graph to be verified in the object to be verified and the pre-registered aggregated feature vector collected from each pre-registered sub-graph in at least one pre-registered object, if the object to be verified is not a pre-registered object, each pre-registered surface texture image will not match the surface texture image to be verified. Therefore, the sub-graph to be verified in the surface texture image to be verified and the pre-registered sub-graph in each pre-registered surface texture image are unlikely to satisfy the geometric consistency constraint (the condition is used to constrain the relative position of the sub-graph); in addition, if the object to be verified is a pre-registered object (that is, the two are the same object), the pre-registered surface texture image collected from the pre-registered object will match the surface texture image to be verified. Correspondingly, since the pre-registered surface texture image is divided to obtain multiple pre-registered sub-graphs and the surface texture image to be verified is intercepted to obtain multiple sub-graphs to be verified, the positions of the sub-graphs in the corresponding images are not exactly the same, so only the positions of the sub-graphs corresponding to some aggregated vector pairs satisfy the above general rules. It can be seen that among all the aggregated vector pairs before the coarse screening, only a small number of the subgraph positions corresponding to the aggregated vector pairs satisfy the above general rules.

[0120] In this regard, the scheme of this embodiment uses vector similarity and geometric consistency constraints to screen all aggregate vector pairs in the rough screening stage, which can preliminarily screen out a large number of aggregate vector pairs whose corresponding subgraphs do not satisfy the above general rules, thereby reducing the processing pressure in the subsequent fine screening stage and comparison stage, and greatly reducing the overall computational load in the verification stage. Therefore, this scheme not only reduces the computing power requirements for the verification party (such as the buyer of the product) in the verification stage, and reduces the difficulty of applying the scheme; but also improves the verification efficiency because the computational load is reduced, which helps to achieve batch verification of a large number of items.

[0121] In another embodiment, the key point description information may include key point position information and key point feature vectors corresponding to the key points, that is, the pre-registered key point description information includes pre-registered key point position information and pre-registered key point feature vectors, and the key point description information to be verified includes key point position information and key point feature vectors to be verified. Based on this, when verifying the item to be verified, the item verification module may, for each acquired key point feature vector to be verified: retrieve a group of pre-registered key point feature vectors with the highest vector similarity with the key point feature vector to be verified from the acquired pre-registered key point feature vectors, the key point feature vector to be verified and each feature vector in the group of pre-registered key point feature vectors respectively forming a key point vector pair, and the retrieved pre-registered key point vectors correspond to a group of pre-registered surface texture images in the at least a portion of the recalled pre-registered surface texture images; then retrieve the retrieved key point vectors from the acquired key point feature vector to be verified; A target key point vector pair whose corresponding key points satisfy the geometric consistency constraint condition is screened out from the key point vector pair formed by the key point feature vector; then it is determined whether there is an image matching the surface texture image to be verified in the pre-registered surface texture image corresponding to the target key point vector pair, wherein, if there is no pre-registered surface texture image matching the surface texture image to be verified, it is determined that the object to be verified is not one of the N pre-registered objects, and if there is a pre-registered surface texture image matching the surface texture image to be verified, the object to be verified is the pre-registered object corresponding to the pre-registered surface texture image.

[0122] For example, when the verification party device or the server determines whether the object to be verified is one of the N pre-registered objects based on the comparison result between the key point description information to be verified and the pre-registered key point description information, the key point vector pair can be determined first, that is, for each key point feature vector to be verified obtained: a group of pre-registered key point feature vectors with the highest vector similarity with the key point feature vector to be verified are retrieved from the obtained pre-registered key point feature vectors, the key point feature vector to be verified and each feature vector in the group of pre-registered key point feature vectors respectively constitute a key point vector pair, and the retrieved pre-registered key point vectors correspond to at least a part of the recalled pre-registered items. A group of pre-registered surface texture images in the face texture image; then, from the key point vector pairs formed by the acquired key point feature vectors to be verified, a target key point vector pair whose corresponding key points meet the geometric consistency constraint condition is screened out; finally, it is determined whether there is an image matching the surface texture image to be verified in the pre-registered surface texture images corresponding to the target key point vector pair, wherein, if there is no pre-registered surface texture image matching the surface texture image to be verified, it is determined that the object to be verified is not one of the N pre-registered objects, and if there is a pre-registered surface texture image matching the surface texture image to be verified, the object to be verified is the pre-registered object corresponding to the pre-registered surface texture image.

[0123] As mentioned above, in the registration stage, it is necessary to extract the pre-registered aggregate feature vector corresponding to the pre-registered surface texture image, and in the verification stage, it is necessary to extract the aggregate feature vector to be verified corresponding to the surface texture image to be verified. Among them, the aggregate feature vector corresponding to any surface texture image can be extracted based on the feature extraction model. The feature extraction model includes a local feature extraction module and a global feature extraction module, the local feature extraction module is used to identify key points from the input image and extract corresponding key point description information, and the global feature extraction module is used to generate corresponding aggregate feature vectors according to at least a part of the key point description information extracted by the local feature extraction module. Among them, an image feature extraction network for extracting image features can be deployed in the model, such as ResNet (Residual Network), VGG (Visual Geometry Group), Inception (Google Inception Network, also known as GoogLeNet) and other image feature extraction networks, and the model can be pre-trained on a large number of texture data sets (such as STEX, KTH-TIPS2, Brodatz, VisTexture, KylbergTextureDataset, etc.) through contrast learning methods such as MoCo or SimCLR.

[0124] It can be seen from this embodiment that for at least a part of the pre-registered surface texture images recalled in the rough screening stage, in the fine screening stage, the pre-registered key point position information and pre-registered key point feature vectors of the pre-registered key points identified from each of the pre-registered surface texture images will be obtained first, and the key point information to be verified and the key point feature vector to be verified of the key points to be verified identified from the surface texture image to be verified will be obtained; then for each key point feature vector to be verified obtained: a group of pre-registered key point feature vectors with the highest vector similarity with the key point feature vector to be verified are retrieved from the obtained pre-registered key point feature vectors to form a key point vector pair with the key point feature vector to be verified, and the target key point vector pairs whose corresponding key points meet the geometric consistency constraint conditions are screened out from all the key point vector pairs. In the comparison stage: determine whether there is an image matching the surface texture image to be verified in the pre-registered surface texture image corresponding to the target key point vector pair to complete the comparison.

[0125] The embodiments of the specification realize verification of the object to be verified by comparing the surface texture image to be verified with the pre-registered surface texture image. The reliability of the above comparison result is based on the following general rule: the surface texture image collected from the object can reflect the microscopic texture of the surface of the object. For any two identical surface texture images and any two key points respectively identified from the two images, if the positions of the two key points in the corresponding images are the same (or close), then the local textures of the two key points are also the same (or close). This scheme characterizes the local micro-texture of the key point through the key point feature vector corresponding to the key point. It can be understood that: for the aggregate feature vector to be verified of each key point to be verified identified in the surface texture image to be verified and the pre-registered aggregate feature vector of each pre-registered key point identified in each pre-registered surface texture image, if the object to be verified is not a pre-registered object, each pre-registered surface texture image will not match the surface texture image to be verified. Therefore, the key points to be verified in the surface texture image to be verified and the pre-registered key points in each pre-registered surface texture image are unlikely to satisfy the geometric consistency constraint (the condition is used to constrain the relative position of the key points); in addition, if the object to be verified is a pre-registered object (that is, the two are the same object), the pre-registered surface texture image collected from the pre-registered object will match the surface texture image to be verified; accordingly, since at least one key point to be verified is identified in the pre-registered surface texture image and at least one pre-registered key point is identified in the surface texture image to be verified, the positions of the key points in the corresponding images are not exactly the same, so only the positions of the key points corresponding to some key point vector pairs satisfy the above general rules. It can be seen that, in at least a portion of the pre-registered surface texture images recalled in the rough screening stage, there may still be some pre-registered surface texture images whose positions of key points do not satisfy the above general rules.

[0126] In this regard, for the key point vectors in at least a portion of the pre-registered surface texture images recalled in the rough screening stage, this embodiment uses vector similarity and geometric consistency constraints to perform a more detailed screening again in the fine screening stage, and can screen out the key point vector pairs whose corresponding key points do not satisfy the above general rules, thereby further reducing the overall computational complexity of the subsequent comparison process. Similar to the above-mentioned embodiment of the fine screening stage, this solution can further reduce the computing power requirements of the comparison process for the verification party on the basis of the above-mentioned solution, and the comparison efficiency is higher.

[0127] In one embodiment, the item registration module can be specifically used to maintain the mapping relationship between the item description information of the preregistered item corresponding to any preregistered surface texture image and the preregistered texture description information extracted from any preregistered surface texture image; in this case, the system can also include an information output module, which is used to output the item description information of the preregistered item obtained according to the mapping relationship when it is determined that the item to be verified is one of the N preregistered items. As mentioned above, when the server maintains the preregistered texture description information extracted from any preregistered surface texture image, it can maintain the mapping relationship between the information and the item description information of the item corresponding to the image. Based on this, the verification party device can output the item description information of the preregistered item obtained according to the mapping relationship when it is determined that the item to be verified is one of the N preregistered items, so that the verification party user can accurately know which preregistered item the item to be verified is, and realize accurate identification and positioning of the item.

[0128] As can be seen from the above embodiments, through the cooperation between the image acquisition module and the item registration module in the item verification system, N pre-registered items can be registered based on the pre-registered surface texture image and the pre-registered texture description information; and through the cooperation between the item registration module and the item verification module, it can be verified whether the item to be verified is the same item as one of the N items that have been registered based on the surface texture image to be verified and the texture description information to be verified, that is, whether the item to be verified is one of the N pre-registered items. Among them, the texture description information extracted from the surface texture image of any item can reflect the micro-texture features of the surface of the item, so the N pre-registered texture description information maintained by the item registration module in the registration stage can respectively reflect the micro-texture features of the surfaces of the N pre-registered items, and the texture description information to be verified extracted in the item verification stage can reflect the micro-texture features of the surface of the item to be verified. It can be seen that based on the micro-texture features of the item to be verified and the N pre-registered items, the verification of the item to be verified is achieved.

[0129] It can be understood that this solution only needs to collect images and accurately verify the items based on the micro-texture features of the items themselves. It does not require special processing of the items themselves, nor does it require anti-counterfeiting accessories such as QR codes or passive sensing tags to be posted on the items, thereby avoiding affecting or even damaging the appearance of the items, and also helping to reduce the circulation costs of the items.

[0130] Corresponding to the aforementioned object verification system, the embodiment of this specification also proposes an object verification method based on surface texture images applied to the system. As mentioned above, the system includes an image acquisition module, an object registration module and an object verification module. Figure 5 As shown, the method includes steps 502-508.

[0131] Step 502, the image acquisition module instructs the image acquisition device of the registration party to acquire corresponding pre-registered surface texture images for N pre-registered objects respectively during the registration phase, where N is a positive integer; and instructs the image acquisition device of the verification party to acquire surface texture images for the objects to be verified during the verification phase.

[0132] Step 504: the object registration module instructs the server to obtain and maintain the pre-registered texture description information extracted from the N pre-registered surface texture images collected by the image collection module during the registration phase.

[0133] Step 506: During the verification phase, the object verification module instructs the verification party device or the server to obtain the texture description information to be verified extracted from the surface texture image to be verified, and determines whether the object to be verified is one of the N pre-registered objects based on a comparison result between the texture description information to be verified and the N pre-registered texture description information.

[0134] In one embodiment, the article verification system further includes a height determination module and an adjustment control module, and the method further includes:

[0135] The height determination module determines the target height according to the thickness of any pre-registered object to be imaged; wherein the target height is the sum of the thickness of the pre-registered object and the initial height, and the initial height is the spacing distance between the image acquisition device of the registration party and the surface of the conveying device when the image acquisition device of the registration party meets the shooting conditions required by the pre-registered object and the surface of the conveying device is clearly focused;

[0136] The adjustment control module controls the posture control device to adjust the registration party image acquisition device to the target height;

[0137] The image acquisition module is specifically used to instruct the image acquisition device of the registration party to acquire a corresponding registration surface texture image for any pre-registered object placed on the conveying device at the target height.

[0138] In one embodiment, the article verification system further includes an information extraction and sending module or an image sending module, and the method further includes:

[0139] The information extraction and sending module extracts the corresponding texture description information to be verified from the surface texture image to be verified acquired by the image acquisition device of the verification party, and sends it to the item registration module; or,

[0140] The image sending module sends the surface texture image to be verified acquired by the image acquisition device of the verification party to the object registration module, and the object registration module is further used to extract corresponding texture description information to be verified from the received surface texture image to be verified.

[0141] The specific implementation process of the above-mentioned object verification method based on surface texture image can be found in the records of the previous embodiment, which will not be repeated here.

[0142] Figure 6 is a schematic structural diagram of a device provided by an exemplary embodiment. Figure 6 At the hardware level, the device includes a processor 602, an internal bus 604, a network interface 606, a memory 608, and a non-volatile memory 610, and may also include hardware required for other functions. One or more embodiments of this specification may be implemented based on software, such as the processor 602 reading the corresponding computer program from the non-volatile memory 610 into the memory 608 and then running it. Of course, in addition to the software implementation, one or more embodiments of this specification do not exclude other implementations, such as logic devices or a combination of software and hardware, etc., that is, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.

[0143] Please refer to Figure 7 , the object verification device based on surface texture image can be applied to Figure 6 The device shown in the figure is used to implement the technical solution of this specification. The device is applied to an item verification system including a registration party device, a server and a verification party device, and the device includes:

[0144] The pre-registration acquisition module 701 is configured to enable the registration device to respectively acquire corresponding pre-registration surface texture images for N pre-registered objects, where N is a positive integer;

[0145] The information maintenance module 702 is configured to enable the server to obtain and maintain the pre-registered texture description information respectively extracted from the collected N pre-registered surface texture images;

[0146] The to-be-verified acquisition module 703 is configured to enable the verification party device to acquire a to-be-verified surface texture image of the to-be-verified object;

[0147] The information comparison module 704 is configured to enable the server or the verification device to obtain the texture description information to be verified extracted from the surface texture image to be verified, and determine whether the object to be verified is one of the N pre-registered objects based on the comparison result between the texture description information to be verified and the N pre-registered texture description information.

[0148] Optionally, the registrant device includes a registrant control device, a registrant image acquisition device and a gesture control device, and the pre-registration acquisition module 701 is specifically configured as follows:

[0149] The control device of the registration party sends a height adjustment instruction to the posture control device according to the thickness of any pre-registered object for image acquisition, wherein the target height indicated by the height adjustment instruction is the sum of the thickness of the pre-registered object and the initial height, wherein the initial height is the spacing distance between the image acquisition device of the registration party and the surface of the conveying device when the image acquisition device of the registration party meets the shooting conditions required by the pre-registered object and the surface of the conveying device is clearly focused;

[0150] The posture control device adjusts the image acquisition device of the registration party to the target height according to the received height adjustment instruction;

[0151] The image acquisition device of the registration party acquires an image of any pre-registered object placed on the conveying device at the target height to obtain the pre-registered surface texture image.

[0152] Optionally, the verification party device includes a verification party control device and a verification party image acquisition device,

[0153] The to-be-verified acquisition module 703 is specifically configured to: enable the image acquisition device of the verification party to acquire the to-be-verified surface texture image of the to-be-verified object;

[0154] The apparatus further comprises an image sending module configured to enable the verification party image acquisition device to send the acquired texture image of the surface to be verified to the verification party control device.

[0155]

Introduction to the acquisition process of pre-registered surface texture images

[0156] At this point, the introduction of the surface texture image comparison scheme is completed. In fact, the pre-registered surface texture image required by the above embodiments of this specification can be obtained by the object surface texture image acquisition system for the pre-registered object. Figure 8-12 The specific method of collecting the pre-registered surface texture image by the system is described. Figure 8-12 The corresponding images described in the following embodiments should be understood as the pre-registered surface texture images described above; the numbering of some modules in these figures is also limited to the numbering in the attached Figure 8-12 The numbers are used within the scope of the corresponding embodiment without causing any conflict with the numbers of some modules in other drawings outside the scope.

[0157] Figure 8 FIG. 1 is a block diagram of a system for collecting surface texture images of an object provided by an exemplary embodiment. Figure 8 As shown, the object surface texture image acquisition system includes: a control device 11, an image acquisition device 12 and a posture control device 13;

[0158] The control device 11 is used to determine a height adjustment instruction according to the thickness of the target object to be imaged, and send the height adjustment instruction to the posture control device 13; wherein the target height indicated by the height adjustment instruction is the sum of the thickness of the target object and the initial height, and the initial height is the distance between the image acquisition device 12 and the surface of the conveying device when the image acquisition device 12 meets the shooting conditions required for the target object and the surface of the conveying device is clearly focused;

[0159] The posture control device 13 is used to adjust the image acquisition device 12 to the target height according to the received height adjustment instruction;

[0160] The image acquisition device 12 is used to acquire images of the target object placed on the conveying device at a target height to obtain a surface texture image of the target object.

[0161] In this embodiment, the control device 11 can be a host computer serving as an OPC (Object Linking and Embedding for Process Control) server, and the host computer can include but is not limited to one or more of the following: a personal computer, a workstation, an industrial control all-in-one machine, a server, an embedded system, a single-chip microcomputer, a smart mobile terminal, etc.

[0162] Optionally, the thickness of the target object can be measured in advance. For example, the thickness of the target object can be measured by an ultrasonic thickness gauge, a laser ranging sensor, etc., or the thickness of the target object can be obtained by manual measurement. After the thickness is obtained, the thickness information corresponding to the thickness can be sent to the control device 11.

[0163] After determining the thickness of the target object, the control device 11 can determine the target height based on the initial height and thickness of the image acquisition device 12 when the shooting conditions required for the target object are met and the surface of the conveying device is clearly focused, and generate the height adjustment instruction. The shooting conditions may include the conditions of the pixel accuracy of the image to be captured, and may also include but are not limited to: object brightness conditions, object area conditions, etc. The object brightness conditions may be conditions of brightness that at least ensures that the target object can be clearly photographed, and the object area conditions may be conditions that at least ensure that the area of ​​the target object can be completely captured by the image acquisition device 12. Furthermore, after the target object is placed on the conveying device, the height difference between the image acquisition device 12 and the target object is the difference between the initial height and the thickness. In order to avoid changes in the shooting conditions of the image acquisition device 12 and avoid the need for the image acquisition device 12 to refocus, a height adjustment instruction for indicating the sum of the thickness of the target object and the initial height is generated. In addition, the control device 11 may send the height adjustment instruction to the posture control device 13.

[0164] The posture control device 13 may be a device for at least adjusting the height of the image acquisition device 12. Further, Fig.10 is a schematic diagram of the positional relationship between an image acquisition device and a conveying device in an object surface texture image acquisition system provided by an exemplary embodiment. Fig.11 is a schematic diagram of the positional relationship between an image acquisition device, a target object and a conveying device in an object surface texture image acquisition system provided by an exemplary embodiment. The posture control device 13 can first reset the height of the image acquisition device 12 to the following Fig.10 The initial height h1 is shown, and then based on the initial height, the height of the image acquisition device 12 is further adjusted according to the height adjustment instruction, that is, the thickness h2 corresponding to the target object is increased, so that the image acquisition device 12 is finally adjusted to Fig.11 The target height h3 = h1 + h2 is shown. At the same time, the attitude control device 13 can also first determine the real-time height of the image acquisition device 12, and then determine the height difference based on the real-time height and the target height, and finally further adjust the height of the image acquisition device 12 according to the height difference, which can also ultimately achieve the purpose of adjusting the image acquisition device 12 to the target height. Fig. 9 FIG. 1 is a schematic diagram of a structure of a system for collecting surface texture images of an object provided by an exemplary embodiment. Fig. 9As shown, the attitude control device 13 may include an attitude control PLC 231 and a lifting motor 232, and the image acquisition device 12 may use a line scan camera 22. The attitude control PLC 231 is connected to the control device 11 in communication, and the attitude control PLC 231 may obtain a height adjustment instruction from the control device 11. The attitude control PLC 231 is also connected to the lifting motor 232 in a driving manner, and the attitude control PLC 231 may drive the lifting motor 232 to operate according to the height adjustment instruction, so that the line scan camera 22 is adjusted to a target height.

[0165] After the image acquisition device 12 is adjusted to the target height, the image of the target object placed on the conveying device can be acquired at the target height to obtain the surface texture image of the target object.

[0166] For example, Fig. 9 As shown, the attitude control device 13 includes an attitude control PLC 231 and a lifting motor 232. On the basis of the line scan camera 22 as the image acquisition device 12, the host computer 21 can be used as the control device 11. The host computer 21 can obtain the height h2 of the target object to be collected. When the initial height of the line scan camera 22 is h1 and the lifting height is 0, the line scan camera 22 is clearly focused relative to the conveyor plane and meets a specific pixel accuracy, such as 12.9um / px (collection pixel 8192px physical size 105mm, physical size / pixel). After the height of the line scan camera 22 is reset (that is, the initial height is h1, the horizontal displacement is 0), the attitude control PLC 231 drives the motor to raise the height of the image acquisition device 12 to h3=h1+h2. In addition, the line scan camera 22 can also be replaced by a planar array camera that meets the following conditions: when collecting images of objects at the target running speed, the complete image of the object can be collected without distortion, and the target speed is the maximum running speed of the conveyor.

[0167] Through this embodiment, by setting an initial height for the image acquisition device, the image acquisition device can simultaneously meet the shooting conditions required for the target object and clearly focus on the surface of the conveying device at the initial height, thereby fixing the shooting parameters required by the image acquisition device. Furthermore, by controlling the device to obtain the thickness of the target object and generating a height adjustment instruction accordingly, the posture control device adjusts the image acquisition device to the target height based on the height adjustment instruction, thereby ensuring that the spacing distance between the image acquisition device and the surface of the target object is consistent with the spacing distance between the image acquisition device and the surface of the conveying device at the initial height. Then, the image acquisition device can meet the shooting conditions required for the target object and the clear focus on the surface of the conveying device while keeping the aforementioned shooting parameters unchanged. Therefore, after adjusting the target object to the target height, even without refocusing, a clear surface texture image of the target object can still be captured, and the surface texture image can meet the aforementioned shooting parameters. It can be seen that the system of the present specification achieves the purpose of adaptively adjusting the height of the image acquisition device according to the thickness of the object while ensuring the stability of the image acquisition quality. This helps to avoid the problems of low efficiency and high complexity caused by manual adjustment and improve image acquisition efficiency, and can also avoid the situation where the deviation that may exist in manual adjustment causes unstable image acquisition quality.

[0168] In one embodiment: the control device 11 is further used to determine a target area on the surface of the target object where image acquisition needs to be performed and offset information of the target area relative to a preset position on the conveying device, and determine a horizontal movement instruction of the image acquisition device 12 according to the target area and the offset information, and transmit the horizontal movement instruction to the posture control device 13;

[0169] The posture control device 13 is also used to control the image acquisition device 12 to move in the direction and distance indicated by the horizontal movement instruction, so that the field of view of the image acquisition device 12 covers the target area.

[0170] In this embodiment, the target area of ​​the target object can be measured in advance. For example, the target area on the surface of the target object that needs to be imaged can be measured by image recognition, laser radar, etc. to obtain the target area. Generally, the target area is a rectangular area whose side direction is consistent with the width direction or length direction of the conveying device. The width direction is the direction perpendicular to the moving direction of the conveying device surface, and the length direction is the moving direction of the conveying device. In addition, the target area of ​​the target object can also be obtained by manual measurement. In some optional embodiments, the target area can be all areas of the target object facing the image acquisition device 12, or it can be a specific area of ​​all areas of the target object facing the image acquisition device 12. In addition, the target area can be characterized by coordinates to obtain corresponding target area information. For example, the target area information can be obtained by taking a point on the target area as the origin and characterizing the target area by coordinates. Since images are generally rectangular, when the target area does not meet the rectangular area whose side direction is consistent with the width direction and length direction of the conveying device, it can also be determined by determining a circumscribed rectangle corresponding to the target area and using the circumscribed rectangle as the target area information. It is easy to know that the side direction of the circumscribed rectangle is consistent with the width direction or length direction of the conveying device.

[0171] Furthermore, a limiting device may be provided in front of the conveying device, and the limiting device is used to fix the relative position of the target object and the conveying device, and different limiting devices may be provided for different types of objects, so that the objects can be located at a position on the conveying device suitable for image acquisition. For example, the limiting device may be used to ensure that the area occupied by the object on the conveying device does not exceed the area corresponding to the conveying device. After the target object is limited by the limiting device, the offset between the target object and the conveyor plane is relatively fixed, and therefore, the offset information of the target area relative to the preset position on the conveying device can be obtained, and the preset position may be the center position of the moving direction of the conveying device or the edge of the conveying device. The offset information may be the position offset relationship between the target position on the target area and the preset position, and the position relationship of the target position on the target area may be consistent with the position relationship of the preset position on the conveying device, that is, the offset information is a conversion vector that converts the coordinates of the target area from the coordinate system for obtaining the target area information to the coordinate system corresponding to the conveying device. For example, when the target position is the center of the target area, the preset position is also the center of the conveying device; when the target position is the left edge of the target area, the preset position is also the left edge of the conveying device, etc., and examples are not given here one by one. In addition, in general, the field of view of the image acquisition device 12 covers both sides of the width direction of the conveying device. If the field of view of the image acquisition device 12 cannot cover both sides of the width direction of the conveying device, the field of view of the image acquisition device 12 can also cover both sides of the width direction of the target area.

[0172] After determining the target area and the offset information, the occupied area of ​​the target area on the conveying device can be determined based on the target area and the offset information, and then the horizontal movement information can be determined. Optionally, based on the target area information and the offset information of the target area, the occupied area information of the target area on the conveying device can be calculated, and then based on the occupied area information, the horizontal movement information required for the image acquisition device 12 to perform complete image acquisition of the target area is determined, and the horizontal movement instruction corresponding to the horizontal movement information is obtained for transmission to the posture control device 13.

[0173] After determining the horizontal movement instruction, the posture control device 13 may first reset the horizontal position of the image acquisition device 12 to the initial horizontal position, and then adjust the horizontal position of the image acquisition device 12 according to the direction and distance corresponding to the horizontal movement instruction, so that the field of view of the image acquisition device 12 after adjusting to the target horizontal position covers the target area. The initial horizontal position may be the optimal horizontal position for the image acquisition device 12 to acquire images at a preset position or a horizontal position that can achieve a better acquisition effect. In addition, the control device 11 may also determine the real-time offset of the image acquisition device 12 relative to the initial horizontal position, and determine the real-time movement instruction based on the real-time offset and the offset information, and transmit the real-time movement instruction to the posture control device 13, so that the posture control device 13 does not need to reset the horizontal position of the image acquisition device 12 to the initial horizontal position, and directly adjusts the horizontal position of the image acquisition device 12 according to the direction and distance corresponding to the real-time movement instruction. Optionally, as Fig. 9 As shown, when the posture control device 13 includes a posture control PLC231 and a translation motor 233, and the image acquisition device 12 uses a line scan camera 22, the posture control PLC231 is connected to the translation motor 233, and can then drive the translation motor 233 to operate according to the horizontal movement instruction, so that the line scan camera 22 is adjusted to the target horizontal position.

[0174] For example, Fig. 9As shown, the attitude control device 13 includes an attitude control PLC 231 and a translation motor 233, and the image acquisition device 12 uses a line scan camera 22. The control device 11 can use a host computer 21. The host computer 21 can predetermine the target area R of the target object that needs to be collected. The target area R is represented by R_tl, which represents the upper left corner of the target area R, and R_br represents the lower right corner of the target area R. After the target object is limited by the limiting device, the offset information of the target object relative to the conveying device is Offset (Offset_x, Offset_y). Based on this, the area of ​​the target object that needs to be collected can be known, and the corresponding position of the occupied area in the conveying area is R_tl+Offset, R_br+Offset. Among them, Offset_x is the offset of the target object in the width direction relative to the plane of the conveying device, and Offset_y is the offset of the target object in the length direction relative to the plane of the conveying device. After resetting the horizontal position of the line scan camera 22 (i.e., resetting to the initial horizontal position, recorded as horizontal position 0), the attitude control PLC 231 horizontally displaces the line scan camera 22 to the target horizontal position, i.e., R_tl_x+Offset_x, by controlling the translation motor 233 to operate. The attitude adjustment of the horizontal position of the line scan camera 22 is completed. Further, after the height and horizontal position of the line scan camera 22 are adjusted, the current position of the line scan camera 22 can be electromagnetically locked to avoid displacement.

[0175] Through the method of this embodiment, the horizontal position of the image acquisition device 12 can be adjusted according to the target area of ​​the target object and the offset information of the target area relative to the preset position on the conveying device, so that even if the target area is not currently at the optimal horizontal acquisition position of the image acquisition device 12, the horizontal position of the image acquisition device 12 can be adjusted according to the offset information, so that the image acquisition device 12 can acquire the texture image of the target area at the optimal image acquisition position. In one embodiment, it also includes: a speed detection device 14;

[0176] The speed detection device 14 is used to detect the speed information of the conveying device conveying the target object, and transmit the speed information to the control device 11;

[0177] The control device 11 is also used to determine the image acquisition frequency according to the speed information, and send the image acquisition frequency to the image acquisition device 12;

[0178] The image acquisition device 12 is also used to acquire surface texture images according to the image acquisition frequency.

[0179] In this embodiment, the speed detection device 14 can be one or more of the following: a linear speed encoder, a photoelectric encoder, a laser displacement encoder, etc. The speed detection device 14 can determine the speed information of the conveying device when conveying the target object. The speed detection device 14 is connected to the control device 11 in communication, so the control device 11 can obtain the speed information from the speed detection device 14. The control device 11 can also determine the pixel accuracy of the image acquisition device 12, and then the image acquisition frequency can be determined based on the speed information and pixel accuracy, that is, the actual physical size corresponding to the image acquired by the image acquisition device 12 each time is the distance obtained by the product of the speed indicated by the speed information and the image acquisition period corresponding to the image acquisition frequency. After obtaining the image acquisition frequency, the image acquisition frequency can be sent to the image acquisition device 12, so that the image acquisition device 12 can acquire the texture image of the object according to the image acquisition frequency. Therefore, according to the image acquisition frequency, the image acquisition device 12 can accurately acquire the surface texture image of the target object, avoiding the situation of missing or duplication of the surface texture image, thereby affecting the later texture authentication.

[0180] For example, Fig. 9 As shown, when the control device 11 is the host computer 21, the speed detection device 14 is the linear velocity encoder 24, the conveying device is the conveyor belt, and the image acquisition device 12 is the line scan camera 22, the line scan camera line frequency (i.e., the image acquisition frequency of the line scan camera) M can be calculated based on the pulse data Q within 1s of the linear velocity encoder 24, and the line frequency of the line scan camera 22 is transmitted to the line scan camera controller through the host computer 21. Assuming that the circumference of the linear velocity encoder 24 is D, the total number of pulses of the linear velocity encoder 24 after one revolution is T, and the camera acquisition accuracy is P, then M = DPQ / T. It can be known from the formula that DP / T is a constant, which is recorded as K. Then, the real-time pulse data is multiplied by the coefficient K to obtain the line frequency QK of the line scan camera 22.

[0181] In one embodiment, it further includes: an object detection device 15;

[0182] The object detection device 15 is used to generate a trigger signal when the target object on the conveying device reaches a preset position, and send the generated trigger signal to the control device 11;

[0183] The control device 11 is further configured to send a delayed shooting instruction to the image acquisition device 12 upon receiving a trigger signal; wherein the delayed shooting instruction includes a shooting delay and a shooting duration, wherein the shooting delay is calculated based on the interval distance between the image acquisition area of ​​the image acquisition device 12 and the preset position and the moving speed of the conveying device, and the shooting duration is calculated based on the moving direction length and the moving speed of the target object;

[0184] The image acquisition device 12 is used to perform time-delay shooting according to the shooting delay and shooting duration indicated by the time-delay shooting instruction.

[0185] In this embodiment, the object detection device 15 may be a device for detecting whether there are items being transported on the conveying device. Optionally, the object detection device 15 may include, but is not limited to, one or more of the following: a laser trigger, an image recognition device, and the like. The detection area of ​​the object detection device 15 is a preset position on the conveying device. Therefore, when the object detection device 15 detects that there is an object at the preset position, a trigger signal may be generated, that is, the trigger signal indicates that there is an object at the preset position. Then, based on the communication channel between the object detection device 15 and the control device 11, the trigger signal is sent to the control device 11.

[0186] After acquiring the trigger signal, the control device 11 can calculate the shooting delay T1 based on the interval distance d1 between the image acquisition area of ​​the image acquisition device 12 and the preset position and the moving speed v of the conveyor, that is, T1=d1 / v. And the shooting duration T2 can also be calculated according to the moving direction length d2 of the target object and the moving speed v, that is, T2=d2 / v. And based on the shooting delay and shooting duration, a delayed shooting instruction for controlling the image acquisition device 12 is obtained, and finally the delayed shooting instruction is sent to the image acquisition device 12.

[0187] After receiving the delayed shooting instruction, the image acquisition device 12 starts shooting images after the shooting delay, and stops shooting after the shooting time is reached.

[0188] For example, Fig. 9 As shown, when the object detection device 15 adopts a laser trigger 25 and the image acquisition device 12 adopts a line scan camera 22, if the distance between the laser trigger 25 and the line scan acquisition area is d, and the average speed of the conveying device within 1 second is v (v=DQ / T), then the line scan camera 22 needs to delay t=(d+R_tl_y) / v seconds to start acquisition, and the acquisition time is c=(R_br_y-R_tl_y) / v seconds. The image acquired within c seconds is generated into a file and returned to the control device 11 for uploading.

[0189] Through the method of this embodiment, the image acquisition device 12 can be accurately controlled to acquire images. By controlling the image acquisition device 12 through the determined shooting delay and shooting duration, the purpose of only acquiring images related to the target object can be achieved, avoiding the acquisition of too many useless images.

[0190] In one embodiment:

[0191] The control device 11 is further used to: when the shooting conditions include pixel accuracy, determine the target pixel accuracy required for image acquisition, determine the initial height according to the target pixel accuracy and the device parameters of the image acquisition device 12, and send an initialization adjustment instruction corresponding to the initial height to the posture control device 13;

[0192] The posture control device 13 is used to adjust the image acquisition device 12 to an initial height according to the acquired initialization adjustment instruction, and feed back the generated adjustment completion information to the control device 11 to trigger the control device 11 to send a focus instruction to the image acquisition device 12;

[0193] The image acquisition device 12 is also used to focus according to the focus instruction.

[0194] In this embodiment, when the shooting conditions include pixel accuracy, the required target pixel accuracy can be manually input to the control device 11 in advance. After the control device 11 obtains the target pixel accuracy, the initial height can be determined according to the target pixel accuracy and the device parameters of the image acquisition device 12. Optionally, the control device 11 can calculate the initial height based on the device parameters such as the focal length and pixels of the image acquisition device 12, and use the initial height as the default height of the image acquisition device 12. After determining the initial height, an initialization adjustment instruction corresponding to the initial height can be generated, and the initialization adjustment instruction can be sent to the posture control device 13 through the communication channel between the posture control device 13.

[0195] After acquiring the initialization adjustment instruction, the posture control device 13 can adjust the height of the image acquisition device 12 according to the initial height indicated in the initialization adjustment instruction. After the image acquisition device 12 has been adjusted to the initial height, the posture control device 13 generates adjustment completion information indicating that the image acquisition device 12 has been adjusted to the initial height. The adjustment completion information is fed back to the control device 11. After the adjustment of the image acquisition device 12 is completed, the current position can be electromagnetically locked to avoid displacement.

[0196] After obtaining the adjustment completion information, the control device 11 can generate a focus instruction for instructing the image acquisition device 12 to focus, and send the focus instruction to the image acquisition device 12 through the communication channel between the image acquisition device 12 and the image acquisition device 12. After obtaining the focus instruction, the image acquisition device 12 can focus according to the object instruction, so that the image acquisition device 12 can focus on the object at an initial height from itself and take a clear picture of it.

[0197] In one embodiment, it also includes: an illumination device; the illumination device is used to illuminate the target object with a side light source. In this embodiment, the illumination device can be a light strip arranged in a rectangular frame, and the light strip is also surrounded by a rectangular shape. Further, the relative position between the illumination device and the image acquisition device 12 is protected and fixed. Optionally, the image acquisition device 12 can be fixed under the platform, and the rectangular frame is also fixed around the platform, and the illumination device is also located under the platform. Each light strip is facing the preset position facing the image acquisition device 12, and the preset position is illuminated in a side lighting manner. Therefore, when the target object is photographed, the target object can be illuminated by a side light source. Moreover, after the illumination device illuminates the target object, the image obtained by the target object can clearly distinguish the texture of the target object. Optionally, the angle between the side light source and the plane of the conveying device can be between 25° and 40°, and preferably, the angle between the side light source and the plane of the conveying device can be 30°. Thereby, it can be avoided that the target object is directly exposed to overexposure, and the surface texture of the target object cannot be clearly photographed.

[0198] Furthermore, the object surface texture image acquisition system can be a system operating in a dark field environment. Here, the line scanning light source method belongs to dark field lighting. The following beneficial effects can be achieved through dark field lighting: Enhance contrast: Since the target object is illuminated from the side, any light reflected or refracted from the surface of the target object will make the sample appear very bright on the dark background. Highlight details: Dark field lighting can reveal the tiny details of the target object. Reduce interference from direct light: Since no light directly from the light source enters the objective lens, the image of the target object is not overexposed, reducing light diffusion and glare.

[0199] In one embodiment, it further includes: a storage device 16; after the control device 11 acquires the surface texture image from the image acquisition device 12, the surface texture image is stored in the storage device 16. The storage device 16 may be a separate device independent of the control device 11, or may be a device integrated in the control device 11. Therefore, after the control device 11 acquires the surface texture image, the surface texture image may be stored in the storage device 16 through the communication channel between the control device 11 and the storage device 16, so that the surface texture image can be directly acquired from the storage device 16 at a later time, and processed to obtain a complete surface texture image corresponding to the target object.

[0200] The related art uses an area array camera module to collect texture images, which has the following disadvantages: 1. The collection range is limited and the cost is high. Currently, the mainstream large-area area array camera modules are almost all CMOS modules. However, even the largest module has a limited collection range and may not be able to collect all images of the expected area. In addition, the size of the CMOS camera module is exponentially related to the price. 2. The collection quality is low. Since the current mainstream large-area area array camera module is CMOS, the natural characteristic of CMOS is that it will produce a jello effect when shooting high-speed moving objects, which will seriously affect the micro-texture imaging.

[0201] In order to overcome the above technical problems, in one embodiment, the image acquisition device 12 is a line scan camera. Further, the resolution and number of the line scan cameras used in the image acquisition device 12 are not restricted here. Generally, one or more line scan cameras can be used to collect images in the width direction of the conveyor in parallel. The number and resolution of the line scan cameras depend on the maximum width of the micro texture of the object to be collected.

[0202] Fig.12 This is a flow chart of a control method of an object surface texture image acquisition system provided by an exemplary embodiment. The object surface texture image acquisition system includes: a control device, an image acquisition device and a posture control device. The method is applied to the control device, including:

[0203] Step 1202, determining a height adjustment instruction according to the thickness of the target object to be imaged, wherein the target height indicated by the height adjustment instruction is the sum of the thickness of the target object and the initial height, and the initial height is the distance between the image acquisition device and the surface of the conveying device when the image acquisition device meets the shooting conditions required for the target object and the surface of the conveying device is clearly focused;

[0204] Step 1204, controlling the posture control device to adjust the image acquisition device to a target height;

[0205] Step 1206 , controlling the image acquisition device to acquire an image of the target object placed on the conveying device at the target height to obtain a surface texture image of the target object.

[0206] The specific implementation of the control method in this embodiment can be referred to Figure 8 The implementation method of the corresponding parts in the illustrated system embodiment will not be described in detail here.

[0207] In one embodiment, the method further comprises the following steps:

[0208] Determine the target area on the surface of the target object where image acquisition needs to be implemented and the offset information of the target area relative to the preset position on the conveying device, determine the horizontal movement instruction of the image acquisition device based on the target area and the offset information, and transmit the horizontal movement instruction to the posture control device; control the posture control device to move the image acquisition device in the direction and distance indicated by the horizontal movement instruction so that the field of view of the image acquisition device covers the target area.

[0209] The specific implementation of the control method in this embodiment can be referred to Figure 8 The implementation method of the corresponding parts in the illustrated system embodiment will not be described in detail here.

[0210] In one embodiment, the object surface texture image acquisition system further includes a speed detection device, and the method further includes:

[0211] Acquire speed information of the conveying device conveying the target object detected by the speed detection device;

[0212] The image acquisition frequency is determined according to the speed information, and the image acquisition device is controlled to acquire the surface texture image according to the image acquisition frequency.

[0213] The specific implementation of the control method in this embodiment can be referred to Figure 8 The implementation method of the corresponding parts in the illustrated system embodiment will not be described in detail here.

[0214] In one embodiment, the object surface texture image acquisition system also includes an object detection device, and the method also includes: upon receiving a trigger signal generated by the object detection device when the target object on the conveying device reaches a preset position, sending a time-delay shooting instruction to the image acquisition device; wherein the time-delay shooting instruction includes a shooting delay and a shooting duration, the shooting delay is calculated based on the interval distance between the image acquisition area of ​​the image acquisition device and the preset position and the moving speed of the conveying device, and the shooting duration is calculated based on the length of the moving direction and the moving speed of the target object; controlling the image acquisition device to perform time-delay shooting according to the shooting delay and shooting duration indicated by the time-delay shooting instruction.

[0215] The specific implementation of the control method in this embodiment can be referred to Figure 8 The implementation method of the corresponding parts in the illustrated system embodiment will not be described in detail here.

[0216] In one embodiment, the method also includes: when the shooting conditions include pixel accuracy, determining the target pixel accuracy required for image acquisition, determining the initial height according to the target pixel accuracy and the device parameters of the image acquisition device, and sending an initialization adjustment instruction corresponding to the initial height to the posture control device; controlling the posture control device to adjust the image acquisition device to the initial height according to the initialization adjustment instruction, and obtaining the adjustment completion information generated by the posture control device to trigger the control of the image acquisition device to focus.

[0217] The specific implementation of the control method in this embodiment can be referred to Figure 8 The implementation method of the corresponding parts in the illustrated system embodiment will not be described in detail here.

[0218] In one embodiment, the object surface texture image acquisition system further includes a storage device, and the method further includes: after acquiring the surface texture image from the image acquisition device, storing the surface texture image in the storage device.

[0219] The specific implementation of the control method in this embodiment can be referred to Figure 8 The implementation method of the corresponding parts in the illustrated system embodiment will not be described in detail here.

[0220]

Introduction to the process of determining target pixel accuracy

[0221] Before collecting the aforementioned pre-registered surface texture image and the surface texture image to be verified, in order to ensure the accuracy of subsequent processing, it is necessary to first determine the target pixel accuracy so that the surface texture image can be collected according to the accuracy. Figure 13-16 The specific method of determining the target pixel accuracy is described below. Figure 13-16 The corresponding images described in the following embodiments should be understood as the pre-registered surface texture images described above; the numbering of some modules in these figures is also limited to the numbering in the attached Figure 13-16 The numbers are used within the scope of the corresponding embodiment without causing any conflict with the numbers of some modules in other drawings outside the scope.

[0222] Fig.13 FIG. 1 is a schematic diagram of a scenario for identifying the authenticity of an object based on the texture features of the object provided by an exemplary embodiment. Fig.13As shown, there are an object A to be verified and a trusted object B in the scene, wherein the authenticity of the object A to be verified is in doubt, and the trusted object B can be understood as a real object corresponding to the object to be verified. For example, the object A to be verified looks like a cowhide bag, and the user doubts its authenticity, suspecting that the object to be verified is a bag made of non-cowhide material. Then the trusted object B is a real cowhide bag. In order to verify the authenticity of the object A to be verified, it is necessary to collect the surface texture image a of the object A to be verified and the surface texture image b of the trusted object B respectively. Then, the surface texture features of the object A to be verified are extracted from the surface texture image a, and the surface texture features of the trusted object B are extracted from the surface texture image b. Compare the surface texture features of the object A to be verified with the surface texture features of the trusted object B to see if they match. If they match, it means that the object A to be verified is real; if they do not match, it means that the object A to be verified is fake.

[0223] Among them, in the process of collecting surface texture images of objects, pixel accuracy plays a vital role, which is directly related to the accuracy and precision of texture feature extraction. Taking tiles P and Q as examples, Fig.14a FIG. 1 is a schematic diagram of a texture feature extracted when the pixel precision is too large, provided by an exemplary embodiment. Fig.14a As shown in the figure, when the pixel precision is too high, the surface texture images of tile P and tile Q are collected respectively according to the high pixel precision. The surface texture features extracted from the two surface texture images reflect the macro texture information of the tile, but cannot reflect the micro texture information of the object. Fig.14a The macro texture information shown will result in an erroneous recognition result that tile P and tile Q are the same tile.

[0224] Fig.14b FIG. 1 is a schematic diagram of a texture feature extracted when the pixel precision is too small, provided by an exemplary embodiment. Fig.14b In the example, box 201 represents a single pixel with too low pixel precision. Obviously, collecting texture feature information of tile P and tile Q through this single pixel may easily lead to too little effective texture feature information contained in a single pixel, thereby identifying the wrong conclusion that tile P and tile Q are the same tile.

[0225] Fig.14c FIG. 1 is a schematic diagram of a texture feature extracted with appropriate pixel accuracy provided by an exemplary embodiment. Fig.14c In the example, box 201 represents a single pixel with too low pixel precision, and box 202 represents a single pixel with appropriate pixel precision. Compared with box 201, box 202 contains more effective texture features, based on which tile P and tile Q can be distinguished as different tiles.

[0226] In summary, in the scenario of identifying the authenticity of an object based on its texture features, it is crucial to select a pixel accuracy suitable for the object. However, in the related art, the pixel accuracy used to collect the surface texture image of the object is often set based on experience, and the pixel accuracy suitable for each object cannot be accurately selected, resulting in a low accuracy rate in identifying the authenticity of the object. In view of this, this specification proposes a method for determining pixel accuracy, which is used to determine the pixel accuracy suitable for collecting the surface texture image of each object.

[0227] Fig.15 FIG. 1 is a flow chart of a method for determining pixel accuracy provided by an exemplary embodiment. Fig.15 As shown, the process may include the following steps:

[0228] Step 1502: For M target objects made of the same material, obtain surface texture images of each target object captured at N candidate pixel accuracies, where M and N are positive integers greater than 1.

[0229] The surface texture image of an object can be used to display the microscopic or macroscopic geometric structure characteristics of the object surface (or the surface texture image contains the microscopic or macroscopic texture features of the object). Since the texture features of objects made from different materials are completely different, it is necessary to use a pixel accuracy that is suitable for the material of the object to collect the surface texture image of the object in order to extract accurate object texture features from the surface texture image. Therefore, in the process of determining the pixel accuracy, the scheme of this specification needs to specifically determine the pixel accuracy suitable for collecting the surface texture image of the object made of the material of the object according to the material of the object.

[0230] The target object in this embodiment can be any object, but the M target objects need to be made of the same material. For example, the material of the object can be lychee leather, cowhide, ceramic tile, etc. For each of the M target objects, the surface texture image of each target object collected at N candidate pixel accuracies is obtained respectively. There are many ways to obtain the surface texture image of the target object. For example, the surface texture image of the target object can be directly collected using a camera. The size of the pixel accuracy is determined by factors such as the focal length, field of view, and aperture of the camera lens. Therefore, for each of the N candidate pixel accuracies, the camera lens that matches each candidate pixel accuracy can be determined first, and then the camera lens of the corresponding candidate pixel accuracy can be used for focusing. When the focusing is successful, the surface texture image of the target object is captured to achieve the collection of the surface texture image of the target object according to the corresponding candidate pixel accuracy. Obviously, this method requires repeated replacement of the lens and refocusing when collecting images according to different candidate pixel accuracies.

[0231] In one embodiment, the surface texture image of each target object captured at the minimum candidate pixel precision among N candidate pixel precisions can be first obtained. For example, the surface texture image of each target object (referred to as "initial surface texture image") can be captured using a camera lens that matches the minimum candidate pixel precision. Then, the initial surface texture image of each target object is downsampled to obtain surface texture images of each target object corresponding to N-1 candidate pixel precisions except the minimum candidate pixel precision. In the field of image processing, downsampling processing generally refers to obtaining a new image by reducing the number of pixels in the image. It can be seen that when the image size is fixed, the pixel precision of the image obtained by downsampling processing will increase, so the initial surface texture image of the target object needs to be collected according to the minimum candidate pixel precision. For example, the candidate pixel precisions are 2um / px, 5um / px, 10um / px, and 20um / px, respectively. In the process of acquiring the surface texture image of the target object, the initial surface texture images of M target objects are first collected according to the candidate pixel accuracy of 2um / px, and then the initial surface texture images of each target object are downsampled to obtain surface texture images of each target object corresponding to the three candidate pixel accuracies of 5um / px, 10um / px, and 20um / px. There are many algorithms for implementing downsampling processing, such as interpolation downsampling algorithm, layered downsampling algorithm, approximate downsampling algorithm, etc. Among them, the interpolation algorithm may include but is not limited to a bilinear interpolation algorithm, a trilinear interpolation algorithm, and a neighboring interpolation algorithm. This specification does not limit the specific downsampling algorithm.

[0232] The above-mentioned surface texture image acquisition method only needs to use one lens to capture the initial surface texture image, and other surface texture images can be acquired based on the initial surface texture image. The entire acquisition process does not require repeated lens replacement and repeated focusing, which greatly improves the acquisition efficiency of the target object surface texture image. In addition, the downsampling process can maintain the main image features / image information of the initial surface texture image as much as possible, thereby ensuring that the surface texture image obtained by the downsampling process is a valid image containing the texture features of the object, which helps to improve the accuracy of subsequent image similarity analysis.

[0233] In one embodiment, if the M target objects are printed products, then after acquiring the surface texture images of the target objects, the surface texture images of each target object can be aligned at a macro level to avoid interference with subsequent similarity calculations due to image deformation, tilt, etc.

[0234] Step 1504: For each of the N candidate pixel precisions: perform similarity calculation on the surface texture images of every two target objects among the M target objects that are collected at the corresponding candidate pixel precision to obtain a set of initial similarities, and perform similarity aggregation on the set of initial similarities to obtain a comprehensive similarity corresponding to the corresponding candidate pixel precision.

[0235] After the image acquisition process in step 1502, there are M surface texture images at each candidate pixel precision. For each candidate pixel precision, similarity calculation is performed on every two surface texture images at the candidate pixel precision to obtain a set of initial similarities.

[0236] In one embodiment, an image quality assessment algorithm can be used to calculate the similarity of every two surface texture images. The specific principle of the algorithm is to calculate the similarity of the image quality evaluation indicators of the image. The image quality evaluation indicators may include but are not limited to the contrast, brightness, image structure information, peak signal-to-noise ratio, etc. of the image. There are many image quality assessment algorithms, such as PSNR (Peak Signal-to-Noise Ratio), SSIM (Structural Similarity Index), etc. Among them, the PSNR algorithm calculates the similarity of images by comparing the peak signal-to-noise ratio of the images. The SSIM algorithm calculates the similarity of images by comparing the contrast, brightness and structural information of the images. Those skilled in the art can choose the image quality assessment algorithm according to actual needs, and this specification does not limit it. This similarity calculation method does not require a training model, and the calculation process is simple and efficient, which is particularly suitable for scenarios where image similarity is calculated in batches.

[0237] In addition, the similarity between every two surface texture images can be calculated by comparing the image feature vectors. For each M surface texture image under the candidate pixel accuracy, feature extraction is performed on the M surface texture images to obtain the image features corresponding to each of the M surface texture images. This process can be implemented using feature extraction algorithms such as gray level co-occurrence matrix (GLCM), local binary pattern (LBP, Local Binary Pattern), etc., or it can be implemented using a pre-trained image feature extraction model. An image feature extraction network for extracting image features is deployed in the image feature extraction model, such as ResNet (Residual Network), VGG (Visual Geometry Group), Inception (Google Inception Network, also known as GoogLeNet) and other image feature extraction networks. When using a pre-trained image feature extraction model for feature extraction, the input of the image feature extraction model is the surface texture image, and the output is the image features of the surface texture image. Image features may include texture features, shape descriptors, edges, corners, etc. The image features of each surface texture image are then integrated into a vector representation to obtain an image feature vector corresponding to each surface texture image. The image feature vector is equivalent to a mathematical summary of the image features. By simplifying the complex image feature information into a data structure that can be mathematically operated, it is convenient for subsequent calculations. For example, the similarity of the image feature vectors of every two images can be calculated by methods such as cosine similarity or Euclidean distance to obtain a set of initial similarities, which is not limited in this specification. Since image features can better reflect the high-level semantic information of the image, this similarity calculation method can further improve the accuracy of the calculated initial similarity.

[0238] According to the principle of permutation and combination, a set of initial similarities corresponding to each candidate pixel precision contains M*(M-1) initial similarities. By performing similarity aggregation on a set of initial similarities corresponding to each candidate pixel precision, the comprehensive similarity corresponding to each candidate pixel precision can be obtained. Similarity aggregation aims to integrate the attributes or features of a set of initial similarities corresponding to the corresponding candidate pixel precision, so that the aggregated comprehensive similarity can more comprehensively and accurately reflect the overall similarity of the surface texture images of the M target objects collected at the corresponding candidate pixel precision. There are many specific ways to aggregate similarities, such as weighted averaging a set of initial similarities, using the weighted average result as the comprehensive similarity, or taking the maximum / minimum value in a set of initial similarities as the comprehensive similarity, and this specification does not limit this.

[0239] In one embodiment, the comprehensive similarity obtained by similarity aggregation of a group of initial similarities may include any of the following statistics: the average value of the group of initial similarities, the median of the group of initial similarities, the maximum value of the group of initial similarities, the weighted average value of the group of initial similarities, and the minimum value of the group of initial similarities. Taking the comprehensive similarity as the average value of a group of initial similarities as an example, the calculation principle of the comprehensive similarity can refer to formula (1):

[0240]

[0241] In formula (1), p represents any candidate pixel accuracy among N candidate pixel accuracies, similarity P represents the comprehensive similarity corresponding to the candidate pixel precision p, M represents the number of target items, i and j represent the i-th target item and j-th target item among the M target items respectively, Represents the surface texture image of the i-th target object captured at the candidate pixel accuracy p, Represents the surface texture image of the jth target object captured at the candidate pixel accuracy p, It represents the initial similarity calculated by similarity calculation of the surface texture images of the i-th and j-th target objects respectively collected at the candidate pixel precision p. The numerator in formula (1) represents a set of initial similarities corresponding to the candidate pixel precision p.

[0242] Step 1506: Determine the change rate of the comprehensive similarity corresponding to the N candidate pixel accuracies in order of corresponding pixel accuracies from small to large, and determine the candidate pixel accuracy corresponding to the first mutation of the change rate as the target pixel accuracy suitable for surface texture image acquisition of the object made of the same material.

[0243] According to the order of pixel precision from small to large, the change of the comprehensive similarity change rate corresponding to N candidate pixel precisions is analyzed, and the candidate pixel precision corresponding to the first mutation of the change rate is determined as the target pixel precision, which is suitable for collecting surface texture images of items with the same preparation materials as the target items. First, the mutation of the similarity change rate usually occurs when the comparison is based on a large amount of effective texture feature information. If the effective texture feature information contained in the collected surface texture features is small, the change amplitude of the similarity change rate will be relatively gentle. Therefore, when the change rate of the comprehensive similarity mutates, it indicates that the surface texture image of the item is collected according to the candidate pixel precision corresponding to the mutation, so that the collected surface texture image contains enough effective texture feature information. In this case, the enough effective texture feature information can be used as an identity mark to identify the authenticity of the item. Here, an example is given for "the candidate pixel precision corresponding to the mutation". For example, the change rate of the comprehensive similarity mutates as the candidate pixel precision changes from 5um / px to 8um / px. Then 5um / px is the candidate pixel precision corresponding to the mutation before the mutation, and 8um / px is the candidate pixel precision corresponding to the mutation after the mutation. Secondly, the candidate pixel accuracy corresponding to the first mutation of the change rate is selected as the target pixel accuracy because the candidate pixel accuracy corresponding to the first mutation is smaller on the basis of the pixel accuracy being arranged in order from small to large. Collecting the surface texture image of the object according to the smaller pixel accuracy is conducive to extracting the micro texture information of the object from the surface texture image. Compared with the macro texture information, the micro texture information pays more attention to the subtle surface structure and details of the object, and is more helpful in distinguishing the differences between different objects.

[0244] In the above embodiment, surface texture images of M target objects made of the same material are obtained according to N candidate pixel accuracies, and the target pixel accuracy suitable for the target object is determined according to the similarity between the surface texture images, so that the surface texture image of the target object acquired according to the target pixel accuracy can contain enough surface texture feature information, and based on the surface texture feature information, the differences between different target objects made of the same material can be effectively distinguished. Therefore, using this surface texture feature information as the identity of the object can greatly improve the accuracy of object authenticity identification.

[0245] In one embodiment, the K-means elbow method can be used to analyze the change of the comprehensive similarity change rate corresponding to the N candidate pixel accuracies in the order of the corresponding pixel accuracies from small to large. The K-means elbow method is used to determine the optimal number of clusters used in the K-means clustering algorithm, specifically by analyzing the trend of the sum of squared errors (SSE, Sum of Squared Errors) or the intra-class error changing with the increase of the number of clusters under different numbers of clusters to identify the inflection point. The inflection point indicates that the error reduction rate is significantly slowed down, so the number of clusters corresponding to the inflection point can be used as the optimal number of clusters.

[0246] In this embodiment, when the K-means elbow method is used to analyze the change of the comprehensive similarity change rate corresponding to the N candidate pixel accuracies, it is necessary to first calculate the sum of square errors of the comprehensive similarity corresponding to each candidate pixel accuracy. The calculation principle can refer to the relevant content of the K-means elbow method in the relevant technology, which will not be repeated here. Then, according to the order of the corresponding pixel accuracy from small to large, a curve of the sum of square errors of the comprehensive similarity changing with the candidate pixel accuracy is generated. Fig.16 FIG. 1 is a schematic diagram of a curve showing a variation of the sum of square errors of a comprehensive similarity with the accuracy of candidate pixels provided by an exemplary embodiment. Fig.16 As shown in the figure, the inflection point in the change curve indicates that the change rate of the sum of square errors of the comprehensive similarity has a sudden change from 10um / px to 20um / px. Among them, 10um / px is the candidate pixel accuracy corresponding to the change rate before the sudden change, and 20um / px is the candidate pixel accuracy corresponding to the change rate after the sudden change. Therefore, it can be Fig.16 The candidate pixel accuracy (ie, 20 um / px) corresponding to the first inflection point in the variation curve shown is determined as the target pixel accuracy, which is suitable for collecting surface texture images of objects made of the same material as the target object.

[0247] In the above method, by generating a curve showing the change of the sum of square errors of the comprehensive similarity with the candidate pixel accuracy, the first sudden change in the rate of change of the comprehensive similarity can be intuitively and clearly represented as the first inflection point in the change curve. This method does not require complex calculations, reduces the computational pressure of the system, and improves the efficiency and accuracy of determining the target pixel accuracy.

[0248] In one embodiment, the change of the rate of change of the comprehensive similarity can also be represented by the second-order derivative of the comprehensive similarity. Specifically, the comprehensive similarities corresponding to the N candidate pixel accuracies are arranged in order from small to large to form a comprehensive similarity sequence. Then the second-order derivative of the comprehensive similarity sequence is calculated to obtain the corresponding second-order derivative sequence. Since the comprehensive similarity sequence is a numerical sequence, the second-order derivative of the comprehensive similarity sequence is actually to calculate the second-order difference of the discrete function corresponding to the numerical sequence (that is, the second-order derivative sequence is actually a second-order difference sequence). The first-order difference of the comprehensive similarity sequence can be calculated first to obtain a first-order difference sequence, and each element in the first-order difference sequence is the difference between two adjacent comprehensive similarities in the comprehensive similarity sequence. Then the first-order difference sequence is subjected to a difference operation again to obtain a second-order difference sequence, and each element in the second-order difference sequence is the difference between two adjacent elements in the first-order difference sequence. For example, assuming that the comprehensive similarity sequence is {0.10, 0.15, 0.50, 0.58, 0.60}, then after the first-order difference operation, the first-order difference sequence is {0.05, 0.35, 0.08, 0.02}. The first-order difference sequence is subjected to the difference operation again, and the second-order difference sequence is {0.30, -0.27, -0.06}. Then, the candidate pixel accuracy corresponding to the first second-order derivative greater than the preset threshold in the second-order derivative sequence is determined as the target pixel accuracy.

[0249] Since the first-order derivative of the comprehensive similarity is used to reflect the rate of change of the comprehensive similarity, and the second-order derivative is used to represent the rate of change of the first-order derivative, that is, the second-order derivative can reflect the change of the rate of change of the comprehensive similarity. Therefore, when the second-order derivative of the comprehensive similarity is greater than the preset threshold, it means that the rate of change of the comprehensive similarity has undergone a sudden change. Furthermore, the candidate pixel accuracy corresponding to the first second-order derivative greater than the preset threshold can be determined as the target pixel accuracy. This method uses the physical meaning of the second-order derivative (i.e., reflecting the change of the rate of change of the original numerical sequence) to clearly and accurately determine the target pixel accuracy, which helps to improve the accuracy of the determined target pixel accuracy.

[0250]

Introduction to the representation method of eigenvector

[0251] As mentioned above, the relevant parties need to extract the corresponding feature vector from the collected surface texture image. In order to balance the verification speed and verification accuracy in the above-mentioned rough screening and fine screening stages, a specific method can be used to represent the feature vector. Figure 17-27 The process of determining the target pixel accuracy is described below. Figure 17-27 The numbering of some modules is limited to the attached Figure 17-27 The numbers are used within the scope of the corresponding embodiment without causing any conflict with the numbers of some modules in other drawings outside the scope.

[0252] Fig.17 FIG. 1 is a schematic diagram of a scenario for verifying the source of an item provided by an exemplary embodiment. Fig.17 As shown, in the scenario where the user needs to verify the actual source of the item (hereinafter referred to as the item to be verified 18), in order to improve the convenience of verification, the user can use the camera module of the electronic device 15 to collect the surface texture image 13 of the item to be verified 18, and upload the collected surface texture image 13 to be verified to the server 11 through the network 14, so that the server 11 can recall the target pre-registered surface texture image that matches the surface texture image 13 from the pre-stored N pre-registered surface texture images. The final verification result 12 can be applied to the commodity channeling scenario to verify whether the commodity has channeling. For example, based on the relevant registration information of the registered product to which the target pre-registered surface texture image belongs, the item to be verified is traced to determine whether the item to be verified has channeling. Of course, the verification result 12 can also be applied to the scene of verifying the authenticity of the item. For example, if the verification result 12 shows that the surface texture image of the item to be verified cannot match any pre-registered surface texture image of the brand manufacturer, it means that the item to be verified does not belong to the product produced by the brand manufacturer.

[0253] In addition, since there are many different situations in the process of actually collecting the surface texture image 13 of the object to be verified 18, such as textures of different granularity require different sampling precisions; different types of textures require different light source angles. Therefore, the user can also adjust appropriate collection parameters through professional collection equipment 17 to collect the surface texture image 13 of the object to be verified 18, and the electronic device 16 uploads it to the server 11 through the network 14.

[0254] The server 11 may be a physical server including an independent host, or the server 11 may be a virtual server carried by a host cluster. During operation, the server 11 may run a server-side program of a certain application to implement the relevant functions of the application. For example, when the server 11 runs a program of a surface texture image comparison service, it may be implemented as a corresponding surface texture image comparison service platform.

[0255] The image acquisition device 17 can be an electronic device such as an optical microscope or a camera array that is specifically used to capture the surface texture details of an object. Of course, this solution can also use the camera module of the electronic device 15 to replace the image acquisition function of the image acquisition device 17 to improve the convenience of verifying the object. In fact, the electronic device 15 and / or the electronic device 16 that the user can obviously use can be such as the following types: mobile phones, tablet devices, laptops, PDAs (Personal Digital Assistants), wearable devices (such as smart glasses, smart watches, etc.), etc., and one or more embodiments of this specification do not limit this. During operation, the electronic device can run a program on the client side of a certain application to implement the relevant functions of the application. For example, when the electronic device runs a program for comparing surface texture images, it can be implemented as a client for the comparison service of the surface texture image. Among them, the application program of the client of the above-mentioned surface texture image comparison service can be started and run on the electronic device. The program on the client side can be a native application installed on the electronic device, or the program on the client side can be a small program, a quick application or other similar forms. Of course, when using web technologies such as HTML5 or similar, relevant functions can be implemented through pages displayed by browsers. The browser here can be an independent browser application or a browser module embedded in certain applications.

[0256] As for the network 14 for interaction between electronic devices such as electronic device 15 and electronic device 16 and server 11, it is possible to select a wired or wireless network to achieve communication based on the communication mode supported by the corresponding electronic device, and this specification does not limit this. For example, electronic device 15 can support both wired and wireless communication, so it can use a wired or wireless network to achieve communication as needed, while electronic device 16 usually only supports wireless communication, so it can use a wireless network to achieve communication.

[0257] like Fig.18 As shown, the structure of the feature extraction model 2 includes a local feature extraction module 22 and a global feature extraction module 24. The local feature extraction module 22 is used to identify the key points of the input image 21 and extract the key point description information 23 of the corresponding key points; the global feature extraction module 24 is used to generate a corresponding aggregated feature vector 25 according to at least a part of the key point description information 23 extracted by the local feature extraction module 22.

[0258] The image 21 is input to the local feature extraction module 22 of the feature extraction model 2 to identify the key points of the image 21 and extract the corresponding key point description information 23. The global feature extraction module 24 based on the feature extraction model 2 generates a corresponding aggregate feature vector 25 according to at least a part of the extracted key point description information 23. Among them, the key point description information 23 is used to characterize the relevant feature information of the key points of the identified image 21, for example, it can include a feature vector for characterizing the key point feature, probability information for measuring whether the key point is a real key point and / or the position information of the key point. The local feature extraction module 22 can identify n key points (n is a positive integer, and the value of n is a hyperparameter of the feature extraction model 2) from the input image 21. The key point description information 23 of any key point can characterize the unique details that are distinguished from other images, and the key point description information 23 of different images can be compared to identify the category to which the image belongs or determine whether any two images are the same image. The aggregate feature vector 25 is used to characterize the global features of the entire image 21, and can also realize the recognition of the category to which the image belongs or determine whether any two images are the same image.

[0259] In one embodiment, if Fig.19 As shown, the local feature extraction module 22 may include a backbone network 221 based on a convolutional neural network and an information description layer 222 connected to the backbone network 221 , and the information description layer 222 is used to generate key point description information 23 according to the output of the backbone network 221 .

[0260] Specifically, the backbone network 221 is used to extract feature information such as edges and textures of the image 21, and gradually extract corresponding more abstract and complex feature representations. The backbone network 221 can adopt the existing convolutional neural network architecture such as the VGG network and the ResNet network. Of course, those skilled in the art can also design the architecture of the backbone network 221 according to the requirements, and the specific design architecture of the backbone network 221 does not affect the implementation of this solution.

[0261] Next, the structure of the information description layer 222 is introduced:

[0262] In one embodiment, the information description layer 222 may include a feature description submodule 2222, and the key point description information 23 generated by the information description layer 222 includes a key point feature vector 232. The feature description submodule 2222 may generate n key point feature vectors 232 for characterizing key point feature information, and then, at least a portion of the generated n key point feature vectors 232 may be processed into an aggregate feature vector 25 through the global feature extraction module 24. The global feature extraction module 24 may be used to process all of the generated n key point feature vectors 232 into an aggregate feature vector 25, or the global feature extraction module 24 may be used to process a portion of the generated n key point feature vectors 232 into an aggregate feature vector 25.

[0263] In another embodiment, the information description layer 222 may include a score description submodule 2221 and a feature description submodule 2222. The score description submodule 2221 is used to generate a key point score 231 contained in the key point description information 23, and the key point score 231 is used to measure the probability that the corresponding key point is a true key point. The global feature extraction module 24 is used to generate at least a portion of the key point description information 23 of the aggregated feature vector 25, and the at least a portion of the key point description information 23 may be the key point description information 23 whose corresponding key point score is greater than a preset score. For example, the information description layer 222 identifies three key points of the image 21 and generates three key point description information 23 accordingly, and the values ​​of each key point score 231 are 0.6, 0.3 and 0.7 respectively. If the preset score is set to 0.5, only the key point description information 23 with key point scores of 0.6 and 0.7 is used by the global feature extraction module 24 to generate the aggregated feature vector 25.

[0264] In the above manner, more reliable key point description information can be screened out for the global feature extraction module 24 to generate the aggregated feature vector 25, so that the global feature extraction module 24 can better capture the essential features of the image based on the reliable key point description information, thereby generating a robust aggregated feature vector 25.

[0265] It should be noted that the larger the value of the preset score is, the greater the probability that the key point description information finally selected is the key point description information of the real key point, that is, the key point description information of the key point can more effectively represent the unique details of the image. However, if the preset score is too large, too little key point description information is screened out, and the aggregated feature vector 25 generated based on too little key point description information is difficult to represent the global features of the image 21. Therefore, the preset score can be set according to the actual training effect of the feature extraction model 2, and this specification does not impose any restrictions on this.

[0266] In another embodiment, the information description layer 222 may include a score description submodule 2221, a feature description submodule 2222, and a position description submodule 2223. The position description submodule 2223 is used to generate key point position information 233 corresponding to the key point feature vector 232. The key point position information 233 can be represented by (x, y) to represent the relative offset position, that is, the relative center offset in the x-axis direction and the y-axis direction. The key point repetition rate can be determined by comparing the key point position information of the image 21 with the key point position information of other images, so as to determine whether the image 21 matches the other images according to the key point repetition rate.

[0267] Next, the structure of the global feature extraction module 24 is introduced:

[0268] In one embodiment, in order to achieve the purpose of generating an aggregated feature vector 25 for characterizing the global features of the image 21 based on at least a portion of the extracted key point description information 23, the global feature extraction module 24 may include a projection layer 241 and a pooling layer 242. Among them, the projection layer 241 is used to expand the dimension of the key point feature vector 232 contained in at least a portion of the key point description information 23 extracted by the local feature extraction module 22, and recompress it into an intermediate feature vector with the same dimension as the input. For example, the dimension of the key point feature vector 232 is C*W*D1, and the dimension D1 of the key point feature vector 232 can be expanded to D2 (D2 is greater than D1), and recompressed into an intermediate feature vector with the same dimension as the input D1 (the dimension is still C*W*D1). The pooling layer is used to aggregate the intermediate feature vector into an aggregated feature vector 25. For example, the intermediate feature vector (the dimension is C*W*D1) is aggregated into an aggregated feature vector 25 (the dimension is 1*1*D1).

[0269] In this embodiment, the key point feature vector 232 is dimensionally expanded by the projection layer 241 and then compressed to the original dimension. More valuable features can be retained through dimensional change, and then the higher-value intermediate feature vectors are aggregated into an aggregated feature vector 25 through the pooling layer 242 to improve the global representation capability of the aggregated feature vector 25.

[0270] In another embodiment, the global feature extraction module 24 includes a projection layer 241, a pooling layer 242 and a multi-layer perception layer 243. The projection layer 241 is used to expand the dimension of the key point feature vector 232 contained in at least a portion of the key point description information 23 extracted by the local feature extraction module 22, and then recompress it into an intermediate feature vector with the same dimension as the input. The pooling layer 242 is used to aggregate the intermediate feature vector into an initial aggregate feature vector; the multi-layer perception layer 243 is used to expand the dimension of the initial aggregate feature vector, and normalize it into an aggregate feature vector 25 of the target dimension.

[0271] In this embodiment, compared with the previous embodiment, a multi-layer perception layer 243 is added after the pooling layer 242. By adding the multi-layer perception layer 243, the initial aggregated feature vector is dimensionally expanded and normalized, which can further fully capture the image information, so that a more generalized aggregated feature vector 25 is finally generated. In addition, the newly added multi-layer perception layer 243 can also be used to adjust the dimension size of the aggregated feature vector 25 outputted at the end, thereby improving the flexibility of setting the target dimension of the aggregated feature vector.

[0272] In one embodiment, in order to enhance the differentiated characterization capability of the aggregated feature vector 25, a method is proposed for Fig.18 The global feature extraction module 24 can be trained by the following method:

[0273] (1) Construct a positive sample pair including an original image and a positive sample corresponding to the original image, and a negative sample pair including an original image and a negative sample corresponding to the original image.

[0274] (2) training the global feature extraction module 24 based on the positive sample pairs and the negative sample pairs through a contrast learning strategy; and, during the training process, screening out at least a portion of the positive sample pairs and / or negative sample pairs whose corresponding contrast loss values ​​are lower than a preset loss threshold, and iteratively training the global feature extraction module 24 using the remaining positive sample pairs and negative sample pairs.

[0275] In this embodiment, a global feature extraction module is trained based on positive sample pairs and negative sample pairs through a contrastive learning strategy, so that the aggregated feature vector of the original image output by the training global feature extraction module is closer to the aggregated feature vector of the positive sample and farther away from the aggregated feature vector of the negative sample, thereby improving the differentiated characterization capability of the aggregated feature vector used to characterize the global features of the image. Moreover, based on the contrastive learning strategy, this specification further improves the training effect by iteratively training the misclassified positive sample pairs and negative sample pairs again. Among them, the contrastive learning strategy can adopt the MOCO algorithm or the SimCLR algorithm.

[0276] In one embodiment, the original image is subjected to image augmentation processing to obtain a positive sample and construct a positive sample pair of the original image and the positive sample. The image augmentation processing includes but is not limited to: image rotation, histogram equalization, blurring and / or sharpening. The original image is subjected to elastic grid deformation processing to obtain a negative sample and construct a negative sample pair of the original image and the negative sample; and / or, other images similar to the original image are selected as negative samples and a negative sample pair of the original image and the negative sample is constructed. For example, if the original image is a surface texture image of a collected ceramic tile, then the other images may be surface texture images of other similar ceramic tiles. Of course, if the original image is a grid sub-image of the surface texture image of a ceramic tile, then the other images may be grid sub-images at corresponding positions of similar surface texture images. For example, if the original image is a grid sub-image of a surface texture image at coordinates (2,3), then the other images may also be grid sub-images of similar surface texture images at coordinates (2,3). Wherein, (2,3) indicates that the grid sub-image is a grid sub-image of the second row and third column of the surface texture image.

[0277] In terms of the construction of positive sample pairs and negative sample pairs, complex positive sample pairs and complex negative sample pairs can be constructed in the above manner, making it more difficult for the global feature extraction module to distinguish between samples and original images, so as to improve the differentiated representation ability of the aggregated feature vector by increasing the training difficulty.

[0278] In one embodiment, if Fig. 20 As shown, Fig. 20 This is a flow chart of a surface texture feature registration method provided by an exemplary embodiment. Specifically, it includes the following steps:

[0279] Step 2002: Acquire a pre-registered surface texture image of a pre-registered object.

[0280] In practical applications, manufacturers can use image acquisition equipment to acquire pre-registered surface texture images of pre-registered items and save relevant information of the pre-registered surface texture images, so as to trace the source of the items to be verified based on the relevant information of the pre-registered surface texture images. The types of pre-registered items can be ceramic tiles, marble, paper and other items with microscopic textures, and this manual does not impose any restrictions on this.

[0281] Among them, the pre-registered surface texture image can be collected from the entire area of ​​the surface of the pre-registered object. For example, taking the pre-registered object as a ceramic tile as an example, the pre-registered surface texture image can be an image collected from the entire area of ​​the surface of the ceramic tile. Of course, for some other objects that are too large, it is difficult to collect images of the entire surface area of ​​the object, and subsequent registration and verification are also required based on the collected images. If the area of ​​the collected image is too large, it will also increase the workload of subsequent registration and verification. At this time, you can choose to collect images of specific local areas on the surface of the object. For example, a specific local area with rich surface texture can be used as the area to be collected, and it can be distinguished from other objects based on the surface texture of the specific local area. It should be noted that if the image collected from a specific local area of ​​the pre-registered object is a pre-registered surface texture image, then in the stage of verifying the authenticity of the object, it is also necessary to collect images of a special local area of ​​the same position of the object to be verified and the pre-registered object. This specification does not limit whether the pre-registered surface texture image is collected from the entire area or a local area of ​​the pre-registered object.

[0282] In one embodiment, the collected pre-registered surface texture image of the pre-registered object may be subjected to image preprocessing, and the pre-registered surface texture image after image preprocessing may be used in subsequent steps. The image preprocessing includes but is not limited to image sharpening, image gamma correction, image histogram equalization and / or image graying.

[0283] Step 2004: extracting a pre-registered aggregated feature vector corresponding to the pre-registered surface texture image based on a feature extraction model.

[0284] Step 2006: Store the pre-registered aggregated feature vector into a vector database.

[0285] In one embodiment, if Fig.21 As shown, for any pre-registered item, taking pre-registered item 51a as an example, based on Fig.19 The feature extraction model 2 shown extracts a pre-registered aggregated feature vector 53a corresponding to a pre-registered surface texture image 52a of a pre-registered object 51a.

[0286] Then, the preregistered aggregated feature vector 53a corresponding to the extracted preregistered surface texture image 52a is stored in the vector database 54, so as to be used for verifying the object to be verified based on the preregistered aggregated feature vector 53a of the preregistered surface texture image 52a in the subsequent verification stage.

[0287] The associated information of the pre-registered surface texture image may be the number of the pre-registered surface texture image. By associating the pre-registered surface texture image number and the aggregated feature vector and storing them in the vector database 54, when determining the pre-registered aggregated feature vector, the pre-registered surface texture image corresponding to the pre-registered aggregated feature vector may also be found according to the number of the pre-registered surface texture image stored in association.

[0288] For other pre-registered items such as pre-registered item 51b and pre-registered item 51c, the processing steps are the same as those of pre-registered item 31a, and will not be repeated in this specification.

[0289] Since the aggregated feature vector that represents the global features of the surface texture image needs to be represented by a high-dimensional aggregated feature vector, and surface texture images with a large area generally require a more complex network model to accurately extract the aggregated feature vector that represents the global features of the image.

[0290] In view of the above problems, this specification proposes another implementation method:

[0291] In another embodiment, if Fig. 22 As shown, for any pre-registered object 61, the pre-registered surface texture image 62 of the pre-registered object 61 can be divided into corresponding pre-registered sub-images 621-623 according to a preset size. Fig.23 As shown, the pre-registered surface texture image 61 is divided into 9 pre-registered sub-images ①-⑨ of the same grid size according to the preset size 3*3. For any pre-registered sub-image, the corresponding pre-registered aggregated feature vector is extracted by the feature extraction model 2, and the pre-registered aggregated feature vector corresponding to the pre-registered surface texture image is the 9 pre-registered aggregated feature vectors corresponding to the 9 pre-registered sub-images into which the pre-registered surface texture image is divided.

[0292] The associated information of the pre-registered surface texture image may be the number of the pre-registered surface texture image and the position information of each pre-registered sub-image in the pre-registered surface texture image. Fig.23 As shown, for the preregistered sub-image ③ of the preregistered surface texture image 62, its position information can be represented by the coordinates (1,3), indicating that the preregistered sub-image ③ is located in the first row and third column of the preregistered surface texture image 62; for the preregistered sub-image ⑥, its position information can be represented by the coordinates (2,3), indicating that the preregistered sub-image ⑥ is located in the second row and third column of the preregistered surface texture image 62.

[0293] Finally, the pre-registered aggregated feature vectors 631 - 633 of each pre-registered sub-image 621 - 623 are associated with the associated information of the pre-registered surface texture image 62 and stored in the vector database 54 .

[0294] In this embodiment, by dividing the pre-registered surface texture image into several pre-registered sub-images, each pre-registered sub-image has a smaller area than the pre-registered surface texture image. Therefore, an overly complex deep network model is not required to accurately extract the pre-registered aggregated feature vector of each pre-registered sub-image. Moreover, since the image information in the pre-registered sub-image is less than that in the pre-registered surface texture image, it is easier to improve the accuracy of extracting the image information in the pre-registered sub-image.

[0295] like Fig.24 As shown, Fig.24 This is a flow chart of a surface texture image comparison method provided by an exemplary embodiment. The method includes the following steps:

[0296] Step 2402: Acquire a surface texture image of the object to be verified.

[0297] Step 2404: extracting the aggregated feature vector to be verified corresponding to the surface texture image to be verified based on the feature extraction model.

[0298] Step 2406: perform a similarity comparison between the aggregated feature vector to be verified and the pre-registered aggregated feature vectors in the vector database, and recall a set of pre-registered surface texture images based on the comparison result.

[0299] Step 2408: Based on the local feature extraction module, key point description information of the surface texture image to be verified and the recalled pre-registered surface texture image are respectively extracted, and by comparing the key point description information, it is determined whether there is a pre-registered surface texture image that matches the surface texture image to be verified.

[0300] In one embodiment, if Fig.25 As shown, the user can collect a surface texture image 92 to be verified of an object 91 to be verified.

[0301] Among them, the surface texture image to be verified can be the surface texture image of the entire area of ​​the surface of the object to be verified, or it can be the surface texture image of a specific local area. It should be noted that if the verification surface texture image is the surface texture image of a specific local area, the specific local area where the verification surface texture image is located needs to be consistent with the specific local area where the pre-registered surface texture image of the pre-registered object is located. For example, for a marble slab, if during the registration stage, only the pre-registered surface texture image of the specific local area in the upper left corner of the pre-registered marble slab is collected, then during the verification stage, it is also necessary to collect the surface texture image to be verified of the same specific local area in the upper left corner of the marble slab to be verified, so as to achieve alignment between the pre-registered surface texture image and the surface texture image to be verified.

[0302] Before inputting the surface texture image 92 to be verified into the feature extraction model 2, the surface texture image 92 to be verified may be preprocessed, and the preprocessed surface texture image 92 to be verified is input into the feature extraction model 2. The image preprocessing includes but is not limited to image sharpening, image gamma correction, image histogram equalization and / or image graying.

[0303] In the coarse screening stage, after the to-be-verified aggregate feature vector 93 of the to-be-verified surface texture image 92 is extracted by the feature extraction model 2, in the coarse screening module 94, the to-be-verified aggregate feature vector 93 is compared with the pre-registered aggregate feature vector in the vector database 54 for similarity, and a group of pre-registered surface texture images 95-97 are recalled based on the comparison results.

[0304] In the fine screening stage, the local feature extraction module 24 based on the feature extraction model 2 respectively extracts the key point description information 98 of the surface texture image to be verified and the key point description information 99-911 of the pre-registered surface texture images 95-97 recalled in the preliminary screening stage, and in the fine screening module 912, by comparing the key point description information 98 with the key point description information 99-911 respectively, it is determined whether there is a pre-registered surface texture image that matches the surface texture image 92 to be verified.

[0305] In this embodiment, the verification stage is divided into two stages: a rough screening stage and a fine screening stage. In the rough screening stage, candidate pre-registered surface texture images are preliminarily screened from all pre-registered surface texture images. Then, in the fine screening stage, the matching degree between the candidate pre-registered surface texture images and the surface texture image to be verified is verified to determine the pre-registered surface texture image corresponding to the surface texture image to be verified, so that the authenticity of the object to be verified can be examined according to the pre-registered object information to which the matched pre-registered surface texture image belongs. This embodiment is based on the following example. Fig.18The feature extraction model 2 is used to cooperate with the above two-stage verification method: the feature extraction model includes a local feature extraction module and a global feature extraction module, the local feature extraction module is used to identify key points from the input image and extract the corresponding key point description information, and the global feature extraction module is used to generate a corresponding aggregate feature vector based on at least a part of the key point description information extracted by the local feature extraction module. In the coarse screening stage, the aggregate feature vector to be verified corresponding to the surface texture image to be verified is extracted based on the feature extraction model, the aggregate feature vector to be verified is compared with the pre-registered aggregate feature vector in the vector database for similarity, and a group of pre-registered surface texture images are recalled according to the comparison result; wherein, the pre-registered surface texture image is collected from the pre-registered item, and the pre-registered aggregate feature vector is generated by the feature extraction model based on the pre-registered surface texture image. Through the processing of the above coarse screening stage, candidate pre-registered surface texture images similar to the surface texture image to be verified can be quickly screened out from all pre-registered surface texture images to reduce the verification calculation amount in the fine screening stage and thus improve the verification speed. In the fine screening stage, the key point description information of the surface texture image to be verified and the recalled pre-registered surface texture image are respectively extracted based on the local feature extraction module, and the pre-registered surface texture image that matches the surface texture image to be verified is determined by comparing the key point description information. In the verification stage of the fine screening stage, the pre-registered surface texture image that matches the surface texture image to be verified can be accurately determined based on the key point description information extracted by the local feature extraction module of the feature extraction model to characterize more image detail information. It can be seen that the above-mentioned verification method based on the feature extraction model in combination with the two-stage verification method can achieve the purpose of balancing verification speed and verification accuracy.

[0306] In one embodiment, in the rough screening stage, a similarity comparison can be performed based on the aggregated feature vector to be verified 93 and the preregistered aggregated feature vectors of the preregistered surface texture images of all preregistered items of the same type as the item to be verified stored in the vector database 54, and a group of preregistered surface texture images 95-97 can be recalled based on the comparison result. For example, the similarity between the aggregated feature vector to be verified 93 and the preregistered aggregated feature vectors of the preregistered surface texture images of each preregistered item is calculated based on cosine similarity, and the top K preregistered aggregated feature vectors with the highest similarity are determined based on the similarity calculation result, and the preregistered surface texture images corresponding to the preregistered aggregated feature vectors are recalled.

[0307] In the fine screening stage, the local feature extraction module 24 based on the feature extraction model 2 respectively extracts the key point description information 98 of the surface texture image to be verified and the key point description information 99-911 of the pre-registered surface texture images 95-97 recalled in the fine screening stage, and in the fine screening module 912, by comparing the key point description information 98 with the key point description information 99-911 respectively, it is determined whether there is a pre-registered surface texture image that matches the surface texture image 92 to be verified.

[0308] In one embodiment, for Fig.25 In the coarse screening stage, Fig.26 As shown in FIG. 1 , M sub-images 101-103 to be verified can be intercepted from the surface texture image 92 to be verified by a sliding window of a preset size, and M aggregated feature vectors 104-106 to be verified corresponding to the M sub-images 101-103 to be verified can be extracted based on the feature extraction model 2. It should be noted that each pre-registered surface texture image also needs to be divided into corresponding pre-registered sub-images according to the preset size, and the pre-registered aggregated feature vectors and the pre-registered sub-images are Figure 1 By controlling the size of the sliding window to be the same as the size of the pre-registered surface texture image, it can be ensured that the sub-image to be verified captured by the sliding window is aligned with the pre-registered sub-image.

[0309] For any aggregated feature vector to be verified extracted by the feature extraction model 2, a similarity comparison is performed with each pre-registered aggregated feature vector in the vector database 54, and the first K pre-registered aggregated feature vectors with the highest similarity to the aggregated feature vector to be verified are determined. For the M×K vector pairs formed by the M aggregated feature vectors to be verified and the corresponding pre-registered aggregated feature vectors determined, the vector pairs that meet the geometric consistency constraint conditions are screened out; and at least a portion of the pre-registered surface texture image corresponding to the screened vector pairs is recalled.

[0310] Specifically, a set of M aggregate feature vectors to be verified {a1, a2, a3, …, a m}, for any aggregate feature vector a to be verified i , retrieve the vector corresponding to a from the vector database 54 i The top K pre-registered aggregate feature vectors with the highest similarity {b i,1 ,b i,2 ,b i,3 ,…,b i,k For any aggregate feature vector a to be verified i , forming K vector pairs {a i ,b i,i}, {a i ,b i,2}, ..., {a i ,b i,k}. For any vector pair, verify whether it satisfies the geometric consistency constraint condition, and select the vector pairs that satisfy the geometric consistency constraint condition. And determine the b in each vector pair from the selected vector pairs i,j The pre-registered surface texture image to which it belongs. And if the number of vector pairs corresponding to the same pre-registered surface texture image is greater than the screening threshold, the pre-registered surface texture image is recalled. For example, for the screened vector pair {a1,b 1,1},{a1,b 1,4},{a1,b 2,3},{a2,b 2,5}, if the screening threshold is set to 2, b 1,1 , b 1,4 and b 2,3 are the pre-registered aggregated feature vectors of different pre-registered sub-images in the same pre-registered surface texture image, then the number of vector pairs corresponding to the same pre-registered surface texture image is 3, and the pre-registered surface texture image can be recalled.

[0311] In the fine screening stage, by comparing the key point description information 98 of the surface texture image to be verified 92 extracted by the local feature extraction module 24 and the key point description information 99-911 of a group of recalled pre-registered surface texture images extracted based on the local feature extraction module 24, it is determined whether there is a pre-registered surface texture image that matches the surface texture image to be verified.

[0312] Specifically, the key point feature vector Descriptor of the surface texture image to be verified is extracted based on the local feature extraction module 24. query And key point position information Position query For any recalled pre-registered surface texture image, extract the key point feature vector Descriptor of the pre-registered surface texture image gallery And key point position information Position gallery For any recalled pre-registered surface texture image, construct a vector pair {Descriptor query ,Descriptor gallery}, and select the vector pairs {Descriptor query ,Descriptor gallery}, then, based on the RANSAC method, the vector pairs {Descriptor query ,Descriptor gallery}Affine transformation estimation is performed to obtain the radiation transformation matrix M. Of course, in addition to the RANSAC algorithm, algorithms such as AdaLAM (Adaptive Locally-Affine Matching) can also be used to estimate the above affine transformation matrix. The specific estimation method can be found in the records in the relevant technology, which will not be repeated here.

[0313] For any selected vector pair, determine the corresponding radiation transformation matrix M, the key point feature vector Descriptor of the surface texture image to be verified in the vector pair query The corresponding key point position information Position query , and the key point feature vector Descriptor of the pre-registered surface texture image in the vector pair gallery The corresponding key point position information Position gallery Based on the radiation transformation matrix M, Descriptor query Perform affine transformation on the coordinates to get Position′ query , and calculate the position of query The coordinates of the circle are the center of the circle. Is there a Position within the range of the circle with the preset radius R? gallery , if it exists, it means that the key point is repeated.

[0314] For any pre-registered surface texture image recalled, the repetition rate of the key point repeated vector pairs to all vector pairs is calculated.

[0315] Then, the similarity between the pre-registered surface texture image and the surface texture image to be verified is calculated. When the repetition rate is greater than the preset repetition rate and the image similarity is greater than the preset similarity, it is determined that the surface texture image to be verified matches the corresponding pre-registered surface texture image. Optionally, the pre-registered aggregate feature vector of the pre-registered surface texture image and the aggregate feature vector to be verified of the image to be verified can be extracted respectively by the feature extraction model 2, and the similarity between the pre-registered aggregate feature vector and the aggregate feature vector to be verified can be calculated. Optionally, the similarity between the pre-registered surface texture image and the surface texture image to be verified can be calculated based on contrast algorithms such as PSNR, SSIM, LPIPS, etc. Optionally, the similarity between the pre-registered surface texture image and the surface texture image to be verified can be calculated using a network model (such as ResNet50, VGG19, InceptionV3) pre-trained by MoCo or SimCLR contrast learning method.

[0316] In one embodiment, if Fig. 27 As shown, Fig. 27The present invention is a flow chart of a method for extracting surface texture features provided by an exemplary embodiment, which specifically includes the following steps:

[0317] Step 2702: In the registration phase and the rough screening phase of the verification phase, the pre-registered surface texture image of the pre-registered object and the surface texture image of the object to be verified are respectively input into the feature extraction model to obtain the corresponding pre-registered aggregated feature vector and the aggregated feature vector to be verified.

[0318] Step 2704: In the fine screening stage of the verification stage, the surface texture image to be verified and the pre-registered surface texture image recalled based on the matching of the aggregated feature vector in the coarse screening stage are respectively input into the local feature extraction module, and the key point description information of the surface texture image to be verified and the recalled pre-registered surface texture image are respectively obtained to verify whether there is a pre-registered surface texture image that matches the surface texture image to be verified.

[0319] [Introduction to the rough screening stage of the verification phase]

[0320] As mentioned above, the verification stage includes rough screening, fine screening and comparison. Figure 28-32 The coarse screening stage is described below. Figure 28-32 The numbering of some modules is limited to the attached Figure 28-32 The numbers are used within the scope of the corresponding embodiment without causing any conflict with the numbers of some modules in other drawings outside the scope.

[0321] Fig.28 is a flowchart of a rough screening method provided by an exemplary embodiment, which can be applied to a verification party device (i.e., an electronic device used by a verification party user, such as Figure 1 The verification party client running in the mobile phone 131 shown in FIG. 1 can also be applied to the server side of the surface texture image comparison system (such as Figure 1 Server 11 shown). Fig.28 As shown, the method includes steps 2802-2806.

[0322] Step 2802: Acquire a surface texture image to be verified collected from the object to be verified, and extract a sub-image to be verified from the surface texture image to be verified through a sliding window of a preset size.

[0323] As mentioned above, the verifier can use the verifier device or its associated image acquisition device to collect the corresponding surface texture image to be verified for the object to be verified. Then, the verifier device or the server as the executor of the method can obtain the image and intercept M sub-images to be verified from the image through a sliding window of a preset size (hereinafter referred to as the first preset size), where M is a positive integer (i.e., at least one sub-image to be verified is intercepted).

[0324] Fig.29 This is a schematic diagram of a process for collecting feature vectors for a surface texture image provided by an exemplary embodiment. As can be seen from the figure, the sliding window step size at this time is equal to the above-mentioned first preset size. Fig.29 The surface texture image shown is a surface texture image collected for a tile with a cloud-like pattern. It can be assumed that the image is the surface texture image to be verified. Fig.29 As shown, 24 sub-images to be verified (4 rows and 6 columns in total, M=24 at this time) can be intercepted from the surface texture image to be verified through a sliding window of a first preset size. In view of the fact that the row and column values ​​of the sliding window where each sub-image to be verified is located determines its position in the surface texture image to be verified, each sub-image can be numbered according to the row and column values ​​(e.g., the sub-image to be verified in the 3rd row and 5th column is sub-image PS35, and the same applies to other sub-images), so as to characterize its position in the surface texture image to be verified through the sub-image number.

[0325] In fact, during the registration stage of any pre-registered item, the registration client or server as the registration subject can also divide the pre-registered surface texture image of the image into multiple pre-registered sub-images according to a preset size (hereinafter referred to as the second preset size), and the division method is similar to the interception method for the surface texture image to be verified.

[0326] In one embodiment, the aforementioned first preset size can be set equal to the second preset size to ensure that the aggregated feature vector to be verified extracted in the verification phase and the pre-registered aggregated feature vector extracted in the registration phase have the same feature representation accuracy. It can be understood that the smaller the preset size, the more corresponding sub-images are intercepted / divided in the image, and the greater the amount of calculation in the subsequent registration and verification phases. Therefore, the more appropriate first preset size and second preset size can be determined based on a variety of factors such as computing power resources, computing speed, efficiency / precision requirements, and this specification does not limit the specific values ​​of the two sizes.

[0327] In addition, when the first preset size is equal to the second preset size, the sliding window step size in the verification phase can be set to be less than or equal to the size, so that the corresponding sub-images to be verified can be intercepted as much as possible for the areas corresponding to all pre-registered sub-images, thereby avoiding the omission of key points and the reduction of comparison accuracy due to incomplete interception of the sub-images to be verified. Among them, whether it is the aggregated feature vector to be verified or the pre-registered aggregated feature vector, the feature representation ability of the aggregated feature vector (that is, the ability to represent the micro-texture differences between different images) is determined by the feature extraction algorithm. This solution can use convolutional neural network architectures such as VGG network and ResNet network to build a feature extraction network for extracting aggregated feature vectors, so that it has a higher feature representation ability. Correspondingly, the above sliding window step size can be negatively correlated with the feature representation ability of the aggregated feature vector to be verified, that is, the stronger the feature representation ability, the smaller the sliding window step size can be set, and the weaker the feature representation ability, the larger the sliding window step size can be set. In addition, the smaller the sliding window step size is set, the more likely the sub-image to be verified intercepted in the verification phase is to be aligned with the pre-registered sub-image divided in the registration phase, and the subsequent comparison accuracy will be higher. Based on the above factors, a suitable sliding window step size may be set according to actual conditions, such as 25%, 50%, 75% of the aforementioned first preset size, etc., and this specification does not limit this.

[0328] Step 2804, extracting the aggregated feature vectors to be verified of each sub-graph to be verified, and for each aggregated feature vector to be verified: retrieving a group of pre-registered aggregated feature vectors with the highest vector similarity with the aggregated feature vector to be verified in the vector database, and the aggregated feature vector to be verified and each feature vector in the group of pre-registered aggregated feature vectors respectively constitute an aggregated vector pair; wherein each pre-registered aggregated feature vector is extracted from a pre-registered sub-graph, and the pre-registered sub-graph is obtained by dividing a pre-registered surface texture image collected from a pre-registered object according to the preset size.

[0329] For the M subgraphs to be verified intercepted in step 2802, the aggregate feature vectors to be verified of each subgraph can be extracted. Among them, when extracting the aggregate feature vectors to be verified in the intercepted subgraph to be verified, the same method as when extracting the pre-registered aggregate feature vectors in the divided pre-registered subgraph can be adopted, that is, the aggregate feature vectors to be verified and the pre-registered aggregate feature vectors are extracted in the same manner. Exemplarily, a pre-built and trained feature extraction network can be used to extract the aggregate feature vectors to be verified and the pre-registered aggregate feature vectors, etc., which will not be repeated here.

[0330] In one embodiment, when extracting the aggregated feature vector to be verified of any sub-graph to be verified, the key points to be verified can be identified from the sub-graph and the corresponding description information of the key points to be verified can be extracted, and the description information includes the feature vector of the key points to be verified. Furthermore, the feature vectors of the key points to be verified corresponding to at least a portion of the identified key points to be verified can be aggregated to generate the aggregated feature vector to be verified of any sub-graph to be verified. It can be seen that the aggregated feature vector to be verified extracted in this way is obtained by aggregating the feature vectors of the key points to be verified of each key point to be verified in the sub-graph to be verified, so the aggregated feature vector to be verified can reflect the overall characteristics of these key points to be verified, which is convenient for the subsequent image comparison based on the relevant features of the key points, thereby improving the accuracy of the comparison.

[0331] Among them, SIFT, SURF, ORB, AKAZE, DoG and other methods or ASLFeat, SuperPoint, UnSuperPoint, R2D2 and other deep learning algorithms can be used to identify the above key points. VLAD, ASMK, SMK and other methods or NetVLAD, GhostVLAD, HOW, SPoC and other deep learning algorithms can be used for the above aggregation processing. The specific use process of the above algorithms can be found in the records of the relevant technology, which will not be repeated here.

[0332] At least one key point to be verified may be identified in each sub-image of the surface texture image to be verified. Fig.29 As shown, four key points to be verified are identified in sub-graph SP23, one key point to be verified is identified in sub-graph SP24, and three key points to be verified are identified in sub-graph SP26 (the key points to be verified in the remaining sub-graphs are not shown one by one). Taking sub-graph SP26 as an example, for the three key points to be verified ROI1, ROI2 and ROI3, the corresponding key point feature vectors Qroi26-1, Qroi26-2 and Qroi26-3 can be extracted respectively; then these three feature vectors are aggregated to obtain the aggregate feature vector Qagg26 corresponding to sub-graph SP26.

[0333] In addition, for each key point to be verified identified from any of the subgraphs to be verified, the credibility scores of each of these key points to be verified can also be determined. Among them, the credibility score of any key point to be verified is proportional to the accuracy / credibility of the identification result of the key point to be verified, that is, the larger the credibility score of any key point to be verified, the greater the possibility that the key point actually exists in the subgraph to be verified. Based on the above credibility scores, during the aggregation process, at least a portion of the key points to be verified whose credibility scores are not less than the score threshold can be determined among the key points to be verified, and the feature vectors of the key points to be verified corresponding to these key points can be aggregated. It can be understood that the credibility of the recognition results of at least a part of the key points to be verified whose credible scores are greater than the score threshold is relatively high. Only the feature vectors of the key points to be verified corresponding to these key points are aggregated (instead of using the feature vectors of the key points to be verified corresponding to the key points to be verified whose credible scores are lower than the score threshold). This can ensure that the processed aggregated feature vectors to be verified also have high accuracy, and can truly reflect the distribution of each key point to be verified in the sub-graph to be verified. The credibility is also high, which helps to improve the accuracy of subsequent comparisons.

[0334] As mentioned above, for each sub-graph to be verified that has been intercepted, the corresponding aggregated feature vector to be verified can be extracted. In addition, the coordinates of the sub-graph to be verified of each sub-graph to be verified can also be recorded, where the coordinates of any sub-graph to be verified are used to represent the position of the sub-graph in the surface texture image to be verified (such as the number of rows and columns) - the coordinates can accurately determine the position involved in the coarse screening stage to the sub-graph level. The coordinates of the sub-graph to be verified can be based on the image origin of the surface texture image to be verified (such as Fig.30 In addition, as mentioned above, at least one key point to be verified may be identified in each sub-graph to be verified (the aggregated feature vector to be verified of the sub-graph can be obtained by aggregating the feature vectors of the key points to be verified of each key point in the sub-graph), wherein the description information of the key point to be verified of each key point to be verified may include not only the feature vector of the key point to be verified, but also the position information of the key point to be verified (such as the coordinates of the key point in the texture image of the surface to be verified, which can accurately determine the position involved in the subsequent fine screening stage to the pixel level).

[0335] In addition, given that the fine screening stage shown in the subsequent step 2808 requires the description information of the key points to be verified of each key point to be verified, in order to speed up the data acquisition efficiency of the fine screening stage, the coarse screening stage can cache the extracted description information of the key points to be verified so that it can be directly obtained in the subsequent fine screening stage without the need to extract it again.

[0336] It should be noted that, in the registration stage, for each image to be registered, the above processing can also be performed to extract the pre-registered aggregate feature vector and pre-registered key point description information (including pre-registered key point feature vector and pre-registered key point position information) corresponding to its pre-registered sub-image, and save it in the aforementioned vector database. It can be understood that each pre-registered aggregate feature vector in the database is extracted from a pre-registered sub-image, and the pre-registered sub-image is obtained by dividing the pre-registered surface texture image collected from the pre-registered object according to the preset size.

[0337] The aforementioned method can be used to extract the aggregate feature vector to be verified corresponding to each subgraph in the M subgraphs to be verified, and then the aggregate vector pairs of these aggregate feature vectors to be verified can be constructed. For each aggregate feature vector to be verified, a group of pre-registered aggregate feature vectors with the highest vector similarity with the aggregate feature vector to be verified can be retrieved from the vector database. After the retrieval is completed, the aggregate feature vector to be verified will form an aggregate vector pair with each feature vector in the group of pre-registered aggregate feature vectors. Assuming that a group of pre-registered aggregate feature vectors retrieved for each aggregate feature vector to be verified includes K vectors (K is a positive integer), then the aggregate feature vector to be verified will form K aggregate vector pairs with these K pre-registered aggregate feature vectors, and all M subgraphs to be verified will form K aggregate vector pairs with these K pre-registered aggregate feature vectors. Figure 1 The corresponding M aggregated feature vectors to be verified participate in forming M*K aggregated vector pairs. Of course, the number of vectors in a group of pre-registered aggregated feature vectors corresponding to each aggregated feature vector to be verified may also be unequal, and this embodiment of the specification does not limit this.

[0338] Among them, if the executor of the method is the aforementioned verification client, the client can synchronize the vector database maintained by it from the server in advance or temporarily, and then perform the above-mentioned search locally; or it can also initiate a search request for the aggregate feature vector to be verified to the server, and receive the search results returned by the server (that is, the retrieved M groups of pre-registered aggregate feature vectors). If the executor of the method is the aforementioned server, the server can perform the above-mentioned search locally in response to the search request initiated by the verification client for the aggregate feature vector to be verified, or extract the aggregate feature vector to be verified by itself after receiving the surface texture image to be verified sent by the verification client and perform the above-mentioned search locally. It can be seen that retrieving a corresponding set of pre-registered aggregate feature vectors for each aggregate feature vector to be verified can be completed by the verification client or the server.

[0339] It should also be noted that all pre-registered aggregate feature vectors contained in the vector database can be set according to the verification purpose of the item to be verified. For example, in order to verify whether the item to be verified is a compliant product produced by a certain merchant, the pre-registered surface texture images corresponding to each pre-registered aggregate feature vector in the database can be collected from these compliant products; and in order to verify whether the item to be verified is a batch of goods authorized to be sold by a certain store, the pre-registered surface texture images corresponding to each pre-registered aggregate feature vector in the database can be collected from this batch of goods. In addition, given that the pre-registered aggregate feature vectors in the vector database are extracted from pre-registered sub-graphs obtained by dividing the pre-registered surface texture image, and a pre-registered surface texture image obtained by collecting a pre-registered item can be divided into multiple pre-registered sub-graphs, the number of pre-registered items corresponding to the vector database (i.e., the number of pre-registered surface texture images) is usually less than the total number of pre-registered aggregate feature vectors stored in the database.

[0340] As for the retrieval process for each aggregate feature vector to be verified, in one embodiment, the vector similarity between the aggregate feature vector to be verified and each pre-registered aggregate feature vector stored in the vector database can be calculated. Then, a group of pre-registered aggregate feature vectors whose vector similarity is not less than the similarity threshold are retrieved (at this time, the number of vectors in each group of pre-registered aggregate feature vectors is not certain, and may be zero or any positive integer). Alternatively, a preset number (i.e., the aforementioned K) of pre-registered aggregate feature vectors with the largest vector similarity are retrieved (at this time, the number of vectors in each group of pre-registered aggregate feature vectors is the preset number).

[0341] like Fig.30As shown, each subgraph to be verified (i.e., SP11 to SP54) in the surface texture image to be verified is located at different positions, and each preregistered subgraph in any preregistered surface texture image i (only SPR1 to SPR9 are shown) is also located at different positions. It is advisable to record the aggregated feature vector to be verified corresponding to SP23 as Qagg23, and the preregistered aggregated feature vector corresponding to SPR1 as Qaggr1, and the same is true for other aggregated feature vectors to be verified and preregistered aggregated feature vectors. Among them, the solid lines with arrows pointing to the preregistered subgraphs SPR1, SPR2 and SPR3 of the subgraph to be verified SP23 are used to indicate that the aggregated feature vector to be verified corresponding to SP23 (i.e., Qagg23) and the preregistered aggregated feature vectors corresponding to SPR1, SPR2 and SPR3 (i.e., Qaggr1, Qaggr2 and Qaggr3) each constitute an aggregated vector pair (i.e., the aggregated feature vector to be verified corresponding to SP23 recalls the preregistered aggregated feature vectors corresponding to SPR1, SPR2 and SPR3). Similarly, the dashed arrow lines of SP44 pointing to the pre-registered subgraphs SPR4, SPR5, SPR6 and SPR7 are used to indicate that Qagg44 and Qaggr4, Qaggr5, Qaggr6 and Qaggr7 each form a cluster vector pair. For the sake of simplicity, [Qagg23, Qaggr1] is used below to represent the cluster vector pair formed by Qagg23 and Qaggr1, and the same applies to other cluster vector pairs.

[0342] Through the screening process based on vector similarity in step 2804, a small number of pre-registered aggregated feature vectors with high similarity to the aggregated feature vector to be verified can be preliminarily screened out from the massive / large number of pre-registered aggregated feature vectors saved in the vector database based on vector similarity, so as to eliminate most of the pre-registered surface texture images that have a large difference in micro-texture from the surface texture image to be verified from all the pre-registered surface texture images corresponding to all the pre-registered aggregated feature vectors in the vector database, thereby greatly reducing the amount of calculation in subsequent steps.

[0343] Step 2806, based on the position information of each sub-image to be verified and each pre-registered sub-image in the corresponding surface texture image, select the target aggregate vector pair of the corresponding sub-image that meets the geometric consistency constraint condition from the aggregate vector pair composed of the aggregate feature vector to be verified, and recall at least a part of the pre-registered surface texture image corresponding to the target aggregate vector pair.

[0344] For the M aggregate feature vectors to be verified, step 2804 screens and obtains M groups of corresponding pre-registered aggregate feature vectors, and each aggregate feature vector to be verified and each adjacent group of pre-registered aggregate feature vectors corresponding to itself constitute an aggregate vector pair. Among them, the aggregate feature vectors to be verified that constitute each aggregate vector pair are extracted from the corresponding subgraph to be verified, and the pre-registered aggregate feature vectors are extracted from the corresponding pre-registered subgraph. As mentioned above, the subgraph coordinates of each subgraph are the position information of the subgraph in the surface texture image to which it belongs. Based on the position information of the subgraph, the target aggregate vector pairs whose corresponding subgraphs meet the geometric consistency constraints can be screened out from the aggregate vector pairs formed by the aggregate feature vectors to be verified, and at least a part of the pre-registered surface texture images corresponding to these target aggregate vector pairs can be recalled to achieve further screening of the pre-registered surface texture images.

[0345] In one embodiment, the sub-image coordinates of any aggregation vector pair may include the coordinates of the sub-image to be verified and the coordinates of the pre-registered sub-image, wherein the coordinates of the sub-image to be verified are the position information of the sub-image to be verified corresponding to the aggregation feature vector to be verified in the aggregation vector pair in the surface texture image to which it belongs, and the coordinates of the pre-registered sub-image are the position information of the pre-registered sub-image corresponding to the pre-registered aggregation feature vector in the aggregation vector pair in the pre-registered surface texture image to which it belongs. Fig.30 As shown, for the aggregated vector pair composed of the aggregated feature vector to be verified corresponding to SP23 and the pre-registered aggregated feature vector corresponding to SPR1, its subgraph coordinates include the coordinates of SP23 in the surface texture image to be verified and the coordinates of SPR1 in the pre-registered surface texture image i, and the subgraph coordinates of other aggregated vector pairs are the same. Based on the subgraph coordinates of each aggregated vector pair, when screening the target aggregated vector pair that meets the geometric consistency constraint condition, it is possible to traverse each aggregated vector pair composed of the acquired aggregated feature vectors to be verified, select at least one aggregated vector pair each time according to the quantity required by the geometric consistency constraint condition, and determine whether the subgraph coordinates of the at least one aggregated vector pair all meet the geometric consistency constraint condition; wherein, if the subgraph coordinates of the at least one aggregated vector pair all meet the condition, then the at least one aggregated vector pair is determined to be the target aggregated vector pair; if there is an aggregated vector pair in the at least one aggregated vector pair whose subgraph coordinates do not meet the condition, then it is determined that the at least one aggregated vector pair is not the target aggregated vector pair. In this way, all combinations of all aggregate vector pairs can be checked one by one according to the number requirements of the geometric consistency constraints, and finally the target aggregate vector pairs that meet the geometric consistency constraints can be screened out to avoid omissions, which helps to ensure the accuracy of the final comparison results.

[0346] Geometric consistency refers to the property in geometry that the relationship between two or more geometric objects remains unchanged. In short, geometric consistency describes the ability of a set of geometric objects to maintain similarity and relative position after transformation (such as rotation, translation or scaling). In this scheme, the relative position relationship between different subgraphs is verified by geometric consistency constraints.

[0347] Among them, the geometric consistency constraint condition includes a distance constraint condition, an angle constraint condition and / or a common constraint condition, that is, when screening the target aggregate vector pair, any number of conditions can be selected from these three constraints to check each aggregate vector pair, which are explained below. For example, when the geometric consistency constraint condition includes these three conditions at the same time, for all S0 aggregate vector pairs to be checked, S1 aggregate vector pairs that meet the distance constraint condition can be screened out first; then for these S1 aggregate vector pairs, S2 aggregate vector pairs that meet the angle constraint condition can be screened out; finally, for these S2 aggregate vector pairs, S3 aggregate vector pairs that meet the common constraint condition can be screened out, that is, as the final target aggregate vector pair. It can be understood that the above process can realize the progressive step-by-step screening of the aggregate vector pairs, where S0≥S1≥S2≥S3. In view of the fact that the calculation amount of the distance constraint condition, the angle constraint condition and the common constraint condition increases successively, this step-by-step screening method can effectively reduce the total calculation amount of the geometric consistency constraint screening process, thereby improving the overall efficiency of the rough screening stage to a certain extent.

[0348] Two clustering vector pairs are required for each check of the distance constraint. For example, for the first clustering vector pair and the second clustering vector pair in any two clustering vector pairs, if the absolute value of the difference between the distance of the subgraph to be verified and the distance of the pre-registered subgraph between the two clustering vector pairs is not greater than the distance threshold, it is determined that the corresponding subgraphs of the two clustering vector pairs satisfy the distance constraint; wherein the distance of the subgraph to be verified is the distance between the coordinates of the subgraph to be verified of the first clustering vector pair and the coordinates of the subgraph to be verified of the second clustering vector pair, and the pre-registered subgraph distance is the distance between the coordinates of the pre-registered subgraph of the first clustering vector pair and the coordinates of the pre-registered subgraph of the second clustering vector pair.

[0349] Following the above embodiment, Fig.30As shown, the to-be-verified aggregate feature vectors corresponding to SP23 participate in the formation of three aggregate vector pairs, namely [Qagg23, Qaggr1], [Qagg23, Qaggr2] and [Qagg23, Qaggr3]; the to-be-verified aggregate feature vectors corresponding to SP44 participate in the formation of four aggregate vector pairs, namely [Qagg44, Qaggr4], [Qagg44, Qaggr5], [Qagg44, Qaggr6] and [Qagg44, Qaggr7]. There are twenty-one combinations of the above seven aggregate vector pairs, that is, there are a total of twenty-one combinations of "two aggregate vector pairs". For each of them, it can be determined whether the absolute value of the difference between the distance of the to-be-verified subgraph and the distance of the pre-registered subgraph is greater than the distance threshold d0, and then whether the subgraph corresponding to this combination meets the distance constraint. Taking the combination of [Qagg23, Qaggr1] and [Qagg44, Qaggr5] as an example, Fig.30 As shown, the distance of the subgraph to be verified in this combination is the length d of the line segment between SP23 and SP44, and the distance of the pre-registered subgraph is the length dr of the line segment between SPR1 and SPR5; if |d-dr|>d0, it is determined that SP23, SP44, SPR1 and SPR5 do not meet the distance constraint; otherwise, if |d-dr|≤d0, it is determined that the above subgraphs meet the distance constraint, and the two aggregation vector pairs [Qagg23, Qaggr1] and [Qagg44, Qaggr5] can be screened out. The determination method of the other six combinations is similar to this and will not be repeated.

[0350] It should be noted that, since any aggregation vector pair may form multiple combinations with other multiple aggregation vector pairs, and the judgment results of these combinations are not exactly the same, in order to avoid misjudgment, when any combination satisfies the distance constraint condition, it is determined that the two aggregation vector pairs participating in the formation of the combination satisfy the distance constraint condition, and there is no need to check whether other combinations formed by the two aggregation vector pairs satisfy the condition. Of course, in order to increase the screening strength of the distance constraint condition, a threshold value of the number of times the aggregation vector pair satisfies the condition can also be set. For example, if it is set to twice, any aggregation vector pair needs to satisfy the condition with at least the combination composed of the other two aggregation vector pairs before the aggregation vector pair is judged to satisfy the condition, which will not be repeated.

[0351] At least three clustered vector pairs are required for each check of the angle constraint. For example, for the first clustered vector pair, the second clustered vector pair, and the third clustered vector pair among any three clustered vector pairs, if the absolute value of the difference between the angle of the subgraph to be verified between the three clustered vector pairs and the angle of the pre-registered subgraph is not greater than the angle threshold, then it is determined that the corresponding subgraphs of the three clustered vector pairs all meet the angle constraint; wherein the angle of the subgraph to be verified is the angle between the line connecting the first and second subgraphs to be verified and the line connecting the second and third subgraphs to be verified, and the line connecting the first and second subgraphs to be verified is the angle between the coordinates of the subgraph to be verified of the first clustered vector pair and the coordinates of the subgraph to be verified of the second clustered vector pair. The second-third subgraph to be verified connection line is the connection line between the subgraph coordinates to be verified of the second aggregation vector pair and the subgraph coordinates to be verified of the third aggregation vector pair, the pre-registered subgraph angle is the angle between the first-two pre-registered subgraph connection line and the second-three pre-registered subgraph connection line, the first-two pre-registered subgraph connection line is the connection line between the pre-registered subgraph coordinates of the first aggregation vector pair and the pre-registered subgraph coordinates of the second aggregation vector pair, and the second-three pre-registered subgraph connection line is the connection line between the pre-registered subgraph coordinates of the second aggregation vector pair and the pre-registered subgraph coordinates of the third aggregation vector pair.

[0352] like Fig.31 As shown, assuming that after screening by the distance constraint, the remaining SP32 corresponding to the to-be-verified aggregate feature vector participates in forming two aggregate vector pairs, namely [Qagg32, Qaggr1] and [Qagg32, Qaggr2]; the to-be-verified aggregate feature vector corresponding to SP44 participates in forming an aggregate vector pair, namely [Qagg44, Qaggr5]; the to-be-verified aggregate feature vector corresponding to SP14 participates in forming an aggregate vector pair, namely [Qagg14, Qaggr8]. There are four combinations of any three of the above four aggregate vector pairs, that is, there are four combinations of "three aggregate vector pairs". For each of them, it can be judged that the absolute value of the difference between the angle of the sub-graph to be verified and the angle of the pre-registered sub-graph is not greater than the angle threshold θ0, and then it is determined whether the three aggregate vector pairs in this combination meet the distance constraint. Taking the combination of [Qagg32, Qaggr1], [Qagg44, Qaggr5] and [Qagg14, Qaggr8] as an example, Fig.31As shown, the angle of one of the subgraphs to be verified in the combination is the angle θ between the line segment between SP32 and SP44 and the line segment between SP32 and SP14, and the angle of the pre-registered subgraph is the angle θr between the line segment between SPR1 and SPR5 and the line segment between SPR1 and SPR8; if |θ-θr|>θ0, it is determined that SP32, SP44, SP14, SPR1, SPR5 and SPR8 do not meet the distance constraint; otherwise, if |θ-θr|≤θ0, it is determined that the above subgraphs meet the angle constraint, and the three aggregation vector pairs [Qagg32, Qaggr1], [Qagg44, Qaggr5] and [Qagg14, Qaggr8] can be screened out. The determination method of the other three combinations is similar to this and will not be repeated.

[0353] Similarly, since any aggregate vector pair may form multiple combinations with other multiple aggregate vector pairs, and the judgment results of these combinations are not exactly the same, in order to avoid misjudgment, when any combination satisfies the angle constraint condition, it is determined that the two aggregate vector pairs participating in the combination both satisfy the angle constraint condition, and there is no need to check whether the other combinations formed by the three aggregate vector pairs meet the condition. Of course, in order to increase the screening strength of the angle constraint condition, a threshold value of the number of times the aggregate vector pair meets the condition can also be set. For example, if it is set to three times, any aggregate vector pair needs to meet the condition with at least the combination formed by the other three aggregate vector pairs before the aggregate vector pair is judged to meet the condition. This will not be repeated.

[0354] Each check of the common constraint condition requires an aggregate vector pair, that is, each aggregate vector pair can be checked by itself without combining. For example, for any aggregate vector pair, if the distance between the coordinates of the sub-graph to be verified and the coordinates of the pre-registered sub-graph of the aggregate vector pair is not greater than the distance threshold, and the angle between the line between the coordinates of the sub-graph to be verified of any aggregate vector pair and the coordinate origin of the surface texture image to be verified and the line between the coordinates of the pre-registered sub-graph of any aggregate vector pair and the coordinate origin of the corresponding pre-registered surface texture image is not greater than the angle threshold, then it is determined that the corresponding sub-graph of any aggregate vector pair meets the common constraint condition.

[0355] like Fig.32As shown, assuming that after screening by the distance constraint and the angle constraint, at least one aggregate vector pair may remain, taking the aggregate vector pair corresponding to SP44 and SPR5, [Qagg44, Qaggr5] as an example. At this time, the surface texture image to be verified can be used as a reference to determine the co-located subgraph of SPR5 in the image (i.e., SPR5' shown by the dotted line in the image), and then calculate whether the distance d between SP44 and SPR5' is greater than the distance threshold d0, and the angle θ between the line connecting SP44 and the origin and the line connecting SPR5' and the origin. If |d-dr|≤d0 and |θ-θr|≤θ0, it is determined that SP44 and SPR5 meet the above common constraints, and the aggregate vector pair [Qagg44, Qaggr5] can be screened out; otherwise (i.e., |d-dr|>d0 and / or |θ-θr|>θ0), it is determined that the two do not meet the above common constraints.

[0356] It should be noted that the distance thresholds involved in the above-mentioned different constraints may be the same or different. Similarly, the angle thresholds involved in the above-mentioned different constraints may be the same or different. The specific values ​​of the thresholds may be reasonably set according to accuracy requirements, screening intensity requirements, etc., and this specification does not limit this.

[0357] Through the above screening, some target aggregate vector pairs whose corresponding subgraphs satisfy the geometric consistency constraint conditions can be screened out from all aggregate vector pairs; further, at least a portion of the pre-registered surface texture images corresponding to the target aggregate vector pairs can be recalled. In one embodiment, for each pre-registered surface texture image corresponding to the target aggregate vector pair, the number of target aggregate vector pairs corresponding to each image can be determined first (if the pre-registered aggregate feature vector constituting a certain target aggregate vector pair is extracted from a pre-registered subgraph obtained by dividing a certain pre-registered surface texture image, then the pre-registered surface texture image corresponds to the target aggregate vector pair), and then the pre-registered surface texture images whose number of corresponding target aggregate vector pairs is greater than the number threshold are recalled (at this time, the number of recalled pre-registered surface texture images is not certain, and may be zero or any positive integer); or, the preset number of pre-registered surface texture images with the largest number of corresponding target aggregate vector pairs are recalled (at this time, the number of recalled pre-registered surface texture images is the preset number). At this point, the coarse screening stage of the verification stage is completed, and the coarse screening result is the recalled at least a portion of the above-mentioned pre-registered surface texture images.

[0358] It can be seen that in the coarse screening stage: for the aggregated feature vectors to be verified extracted from each sub-graph of the surface texture image to be verified, a group of pre-registered aggregated feature vectors with the highest similarity are screened out from the pre-registered aggregated feature vectors stored in the vector database to form an aggregated vector pair with the aggregated feature vector to be verified, and then the target aggregated vector pair of the corresponding sub-graph that meets the geometric consistency constraint condition is screened out from all aggregated vector pairs according to the position information of the sub-graph in the surface texture image, and at least a part of the corresponding pre-registered surface texture images is recalled. Furthermore, in the fine screening stage and the comparison stage, for this part of the pre-registered surface texture images recalled in the coarse screening stage, the comparison result between the description information of the key points to be verified and the description information of the pre-registered key points (corresponding to the pre-registered key points in this part of the pre-registered surface texture images) will be used to determine whether there is a pre-registered surface texture image that matches the surface texture image to be verified, so as to complete the comparison.

[0359] The embodiments of this specification realize verification of the object to be verified by comparing the surface texture image to be verified with the pre-registered surface texture image. The above verification stage is based on the following general rule: the surface texture image collected from the object can reflect the microscopic texture of the surface of the object. For any two identical surface texture images and any two sub-images respectively captured from the two images, if the positions of the two sub-images in the corresponding images are the same (or close), then the surface textures of the two sub-images are also the same (or close). This scheme characterizes the overall micro-texture of the sub-graph through the aggregated feature vector corresponding to the sub-graph. It can be understood that: for the aggregated feature vector to be verified collected from each sub-graph to be verified in the object to be verified and the pre-registered aggregated feature vector collected from each pre-registered sub-graph in at least one pre-registered object, if the object to be verified is not a pre-registered object, each pre-registered surface texture image will not match the surface texture image to be verified. Therefore, the sub-graph to be verified in the surface texture image to be verified and the pre-registered sub-graph in each pre-registered surface texture image are unlikely to satisfy the geometric consistency constraint (the condition is used to constrain the relative position of the sub-graph); in addition, if the object to be verified is a pre-registered object (that is, the two are the same object), the pre-registered surface texture image collected from the pre-registered object will match the surface texture image to be verified. Correspondingly, since the pre-registered surface texture image is divided to obtain multiple pre-registered sub-graphs and the surface texture image to be verified is intercepted to obtain multiple sub-graphs to be verified, the positions of the sub-graphs in the corresponding images are not exactly the same, so only the positions of the sub-graphs corresponding to some aggregated vector pairs satisfy the above general rules. It can be seen that among all the aggregated vector pairs before the coarse screening, only a small number of the subgraph positions corresponding to the aggregated vector pairs satisfy the above general rules.

[0360] In this regard, the embodiment of this specification uses vector similarity and geometric consistency constraints to screen all aggregate vector pairs in the rough screening stage, which can preliminarily screen out a large number of aggregate vector pairs whose corresponding subgraphs do not satisfy the above general rules, thereby reducing the processing pressure in the subsequent fine screening stage and comparison stage, and greatly reducing the overall computational workload in the verification stage. Therefore, this solution not only reduces the computing power requirements for the verification party (such as the buyer of the product) in the verification stage, and reduces the difficulty of applying the solution; but also improves the verification efficiency because the computational workload is reduced, which helps to achieve batch verification of a large number of items.

[0361]

Introduction to the fine screening stage of the verification stage

[0362] The following is combined with Figure 33-36 The fine screening stage is described below. Figure 33-36 The numbering of some modules is limited to the attached Figure 33-36 The numbers are used within the scope of the corresponding embodiment without causing any conflict with the numbers of some modules in other drawings outside the scope.

[0363] Fig.33 is a flowchart of a fine screening method provided by an exemplary embodiment, which can be applied to a verification party device (i.e., an electronic device used by a verification party user, such as Figure 1 The verification party client running in the mobile phone 131 shown in FIG. 1 can also be applied to the server side of the surface texture image comparison system (such as Figure 1 Server 11 shown). Fig.33 As shown, the method includes steps 3302-3304.

[0364] Step 3302, obtain the preregistered key point position information and preregistered key point feature vector corresponding to the preregistered key points identified from each recalled preregistered surface texture image, and the key point position information and key point feature vector corresponding to the key points to be verified identified from the surface texture image to be verified.

[0365] In one embodiment, as described above, the vector database maintained by the server records the pre-registered key point position information and pre-registered key point feature vectors corresponding to the recalled pre-registered key points (respectively identified from each pre-registered surface texture image), so these pre-registered key point position information and pre-registered key point feature vectors can be retrieved from the vector database, and the specific process will not be repeated here.

[0366] In one embodiment, as described above, after extracting the description information of the key points to be verified of the sub-graph to be verified (including the feature vectors of the key points to be verified and the position information of the key points to be verified) in the rough screening stage, this information can be cached in the local storage space of the verifier (such as the local memory of the client or server of the verifier). Based on this, when obtaining the position information of the key points to be verified and the feature vectors of the key points to be verified in the fine screening stage, the cached position information of the key points to be verified and the feature vectors of the key points to be verified corresponding to the key points identified from the surface texture image to be verified can be directly obtained. This method exchanges storage space for data acquisition efficiency, which can reduce the time consumption of the fine screening stage to a certain extent.

[0367] Of course, in another embodiment, given that there is only one surface texture image to be verified, when the key point recognition and feature extraction algorithms are relatively efficient, it is completely possible not to sacrifice the above storage space for caching, but to re-identify the key points to be verified from the surface texture image to be verified in the fine screening stage and extract the corresponding key point position information to be verified and key point feature vectors to be verified. The specific acquisition method can be flexibly selected according to actual needs, and this specification does not limit this.

[0368] Among them, when identifying the key points to be verified from the surface texture image to be verified and extracting the corresponding key point position information and key point feature vector to be verified, a sub-image to be verified can be intercepted from the surface texture image to be verified through a sliding window of a preset size; for each intercepted sub-image to be verified: the key points to be verified can be identified from the sub-image to be verified and the corresponding key point position information and key point feature vector to be verified can be extracted. Of course, in addition to dividing the sub-image to be verified, it is also possible not to intercept the sub-image to be verified, but to directly identify each key point to be verified in the surface texture image to be verified and extract the corresponding key point description information to be verified, which will not be repeated.

[0369] Through the above method, the key point position information and key point feature vector of the N key points to be verified in the surface texture image to be verified can be obtained, as well as the pre-registered key point position information and pre-registered key point feature vector of each pre-registered key point contained in each pre-registered surface texture image recalled in the coarse screening stage.

[0370] Step 3304, for each key point feature vector to be verified obtained: retrieve a group of preregistered key point feature vectors with the highest vector similarity with the key point feature vector to be verified from the obtained preregistered key point feature vectors, the key point feature vector to be verified and each feature vector in the group of preregistered key point feature vectors respectively constitute a key point vector pair, and the retrieved preregistered key point vector corresponds to a group of preregistered surface texture images in the at least a part of the preregistered surface texture images that have been recalled; and, filter out the target key point vector pair whose corresponding key points meet the geometric consistency constraint conditions from the key point vector pairs constituted by the obtained key point feature vectors to be verified.

[0371] For each of the N key points to be verified that have been obtained, the key point vector pairs of each of the key point feature vectors to be verified can be constructed next. Among them, when retrieving the set of pre-registered key point feature vectors, the vector similarity between the vector to be verified and each of the pre-registered key point feature vectors obtained can be calculated first; then a set of pre-registered key point feature vectors whose vector similarity is not less than the similarity threshold is retrieved (the number of vectors in each set of pre-registered key point feature vectors is not certain at this time, and may be zero or any positive integer), or a preset number of pre-registered key point feature vectors with the largest vector similarity are retrieved (the number of vectors in each set of pre-registered key point feature vectors is the preset number at this time). For example, assuming that a set of pre-registered key point feature vectors retrieved for each key point feature vector to be verified includes H (H is a positive integer) vectors, then the key point feature vector to be verified will constitute H key point vector pairs with the H pre-registered key point feature vectors, and the N key point feature vectors to be verified that correspond one-to-one to all the N key points to be verified will participate in constituting N*H key point vector pairs. Of course, the number of vectors in a group of pre-registered key point feature vectors corresponding to each key point feature vector to be verified may also be unequal, and the embodiments of this specification do not limit this.

[0372] like Fig.34As shown, each key point to be verified in the surface texture image to be verified (such as ROI1~ROI4, etc.) is located at different positions, and each pre-registered key point in any pre-registered surface texture image i (i.e. ROIR1~ROIR8, etc.) is also located at different positions. It is advisable to record the key point feature vector to be verified corresponding to ROI1 as Qroi1, and the pre-registered key point feature vector corresponding to ROIR1 as Qroir1. The same is true for other key point feature vectors to be verified and pre-registered key point feature vectors. Among them, the arrowed solid lines pointing to the pre-registered key points ROIR1, ROIR2 and ROIR3 of the key point to be verified are used to indicate that Qroi1 and Qroir1, Qroir2 and Qroir3 each constitute a key point vector pair (indicating that Qroi1 recalls Qroir1, Qroir2 and Qroir3). Similarly, ROI2 points to the pre-registered key points ROIR4, ROIR5, ROIR6 and ROIR7 with dotted arrows, which are used to indicate that Qroi2 and Qroir4, Qroir5, Qroir6 and Qroir7 each form a key point vector pair. For the sake of simplicity, [Qroi2, Qroir1] is used below to represent the key point vector pair formed by Qroi2 and Qroir1, and the same applies to other key point vector pairs.

[0373] Through the above-mentioned screening process based on vector similarity, a part of pre-registered key point feature vectors with high similarity to the key point feature vector to be verified can be preliminarily screened out from the pre-registered key point feature vectors recalled in the coarse screening stage, so as to eliminate most of the pre-registered surface texture images that have a large difference in micro-texture from the surface texture image to be verified from all the pre-registered surface texture images corresponding to all the recalled pre-registered key point vectors, thereby greatly reducing the amount of calculation in the subsequent steps.

[0374] For N key point feature vectors to be verified, the aforementioned similarity-based screening process can screen out M groups of corresponding pre-registered key point feature vectors, and each key point feature vector to be verified and each adjacent pre-registered key point feature vector corresponding to itself constitute a key point vector pair. Among them, the key point vector to be verified that constitutes each key point vector pair corresponds to the corresponding key point to be verified, and the pre-registered key point vector corresponds to the corresponding pre-registered key point. As mentioned above, the position information of each key point is used to reflect the position of the key point in the surface texture image to which it belongs. Based on the position information of the key point, the target key point vector pair whose corresponding key point meets the geometric consistency constraint condition can be screened out from the key point vector pair constituted by the key point feature vector to be verified.

[0375] In one embodiment, the key point coordinates of any key point vector pair may include the key point coordinates to be verified and the pre-registered key point coordinates, wherein the key point coordinates to be verified are the position information of the key point to be verified corresponding to the key point feature vector to be verified in the key point vector pair in the surface texture image to be verified, and the pre-registered key point coordinates are the position information of the pre-registered key point corresponding to the pre-registered key point feature vector in the key point vector pair in the pre-registered surface texture image to which it belongs. Fig.34 As shown, for the key point vector pair [Qroi1, Qroir1] composed of the key point feature vector to be verified corresponding to ROI1 and the pre-registered key point feature vector corresponding to ROIR1, its key point coordinates include the coordinates of ROI1 in the surface texture image to be verified and the coordinates of ROIR1 in the pre-registered surface texture image i.

[0376] Based on the above key point coordinates, when screening the target key point vector pairs that meet the geometric consistency constraint conditions, the key point vector pairs formed by the key point feature vectors to be verified can be traversed, and at least one key point vector pair can be selected each time according to the number requirements of the geometric consistency constraint conditions, and it is determined whether the key point coordinates of the at least one key point vector pair all meet the geometric consistency constraint conditions; wherein, if the key point coordinates of the at least one key point vector pair all meet the conditions, then the at least one key point vector pair is determined to be the target key point vector pair; if the key point coordinates of the key point vector pair in the at least one key point vector pair do not meet the conditions, then it is determined that the at least one key point vector pair is not the target key point vector pair. In this way, all combinations of all key point vector pairs can be checked one by one according to the number requirements of the geometric consistency constraint conditions, and finally the target key point vector pairs that meet the geometric consistency constraint conditions are screened out, avoiding omissions, and helping to ensure the accuracy of the final comparison results.

[0377] Geometric consistency refers to the property in geometry that the relationship between two or more geometric objects remains unchanged. In short, geometric consistency describes the ability of a set of geometric objects to maintain similarity and relative position after transformation (such as rotation, translation or scaling). In this solution, the relative position relationship between different key points is verified through geometric consistency constraints.

[0378] Among them, the geometric consistency constraint condition includes a distance constraint condition, an angle constraint condition and / or a common constraint condition, that is, when screening the target key point vector pair, any number of conditions can be selected from these three constraints to check each key point vector pair. They are explained below respectively. For example, when the geometric consistency constraint condition includes these three conditions at the same time, for all S0 key point vector pairs to be checked, S1 key point vector pairs that meet the distance constraint condition can be screened out first; then for these S1 key point vector pairs, S2 key point vector pairs that meet the angle constraint condition can be screened out; finally, for these S2 key point vector pairs, S3 key point vector pairs that meet the common constraint condition can be screened out, that is, as the final target key point vector pair. It can be understood that the above process can realize the progressive step-by-step screening of the aggregated vector pairs, where S0≥S1≥S2≥S3. In view of the fact that the calculation amount of the distance constraint condition, the angle constraint condition and the common constraint condition increases successively, this step-by-step screening method can effectively reduce the total calculation amount of the geometric consistency constraint screening process, thereby improving the overall efficiency of the rough screening stage to a certain extent.

[0379] Two key point vector pairs are required for each check of the distance constraint. For example, for the first key point vector pair and the second key point vector pair in any two key point vector pairs, if the absolute value of the difference between the distance of the key point to be verified and the distance of the pre-registered key point between the two key point vector pairs is not greater than the distance threshold, it is determined that the corresponding key points of the key point pairs corresponding to the two key point vectors respectively meet the distance constraint; wherein the distance of the key point to be verified is the distance between the coordinates of the key point to be verified of the first key point vector pair and the coordinates of the key point to be verified of the second key point vector pair, and the distance of the pre-registered key point is the distance between the coordinates of the pre-registered key point of the first key point vector pair and the coordinates of the pre-registered key point of the second key point vector pair.

[0380] Following the above embodiment, Fig.34As shown, the feature vector of the key point to be verified corresponding to ROI1 participates in the formation of three key point vector pairs, namely [Qroi1, Qroir1], [Qroi1, Qroir2] and [Qroi1, Qroir3]; the feature vector of the key point to be verified corresponding to ROI2 participates in the formation of four key point vector pairs, namely [Qroi2, Qroir4], [Qroi2, Qroir5], [Qroi2, Qroir6] and [Qroi2, Qroir7]. There are twenty-one combinations of the above seven key point vector pairs, that is, there are a total of twenty-one combinations of "two key point vector pairs". For each of them, it can be determined whether the absolute value of the difference between the distance of the key point to be verified and the distance of the pre-registered key point is greater than the distance threshold d0, and then determine whether the key point corresponding to this combination meets the distance constraint. Fig.34 Taking the combination of [Qroi1, Qroir1] and [Qroi2, Qroir5] as an example, the distance of the key point to be verified in this combination is the length d of the line segment between ROI1 and ROI2, and the distance of the pre-registered key point is the length dr of the line segment between ROIR1 and ROIR5; if |d-dr|>d0, it is determined that ROI1, ROI, ROIR1 and ROIR5 do not meet the distance constraint; otherwise, if |d-dr|≤d0, it is determined that the above key points meet the distance constraint, and the two key point vector pairs [Qroi1, Qroir1] and [Qroi1, Qroir5] can be selected. The determination method of the other six combinations is similar and will not be repeated.

[0381] It should be noted that, since any key point vector pair may form multiple combinations with multiple other key point vector pairs, and the judgment results of these combinations are not exactly the same, in order to avoid misjudgment, when any combination satisfies the distance constraint condition, it is determined that the two key point vector pairs participating in the formation of the combination satisfy the distance constraint condition, and there is no need to check whether the other combinations formed by the two key point vector pairs satisfy the condition. Of course, in order to increase the screening strength of the distance constraint condition, a threshold value of the number of times the key point vector pair satisfies the condition can also be set. For example, if it is set to twice, any key point vector pair needs to satisfy the condition with at least the combination composed of the other two key point vector pairs before it is determined that the key point vector pair satisfies the condition, which will not be repeated.

[0382] At least three key point vector pairs are required for each check of the angle constraint. For example, for the first key point vector pair, the second key point vector pair, and the third key point vector pair among any three key point vector pairs, if the absolute value of the difference between the angle of the key point to be verified between the three key point vector pairs and the angle of the pre-registered key point is not greater than the angle threshold, then it is determined that the corresponding key points of the three key point vector pairs all meet the angle constraint; wherein the angle of the key point to be verified is the angle between the line connecting the first and second key points to be verified and the line connecting the second and third key points to be verified, and the line connecting the first and second key points to be verified is the angle between the coordinates of the key point to be verified of the first key point vector pair and the coordinates of the key point to be verified of the second key point vector pair. The line connecting the two and three key points to be verified is the line between the coordinates of the key points to be verified of the second key point vector pair and the coordinates of the key points to be verified of the third key point vector pair, the pre-registered key point angle is the angle between the line connecting the one and two pre-registered key points and the line connecting the two and three pre-registered key points, the line connecting the one and two pre-registered key points is the line between the pre-registered key point coordinates of the first key point vector pair and the pre-registered key point coordinates of the second key point vector pair, and the line connecting the two and three pre-registered key points is the line between the pre-registered key point coordinates of the second key point vector pair and the pre-registered key point coordinates of the third key point vector pair.

[0383] like Fig.35 As shown, assuming that after the distance constraint is screened, the feature vectors of the key points to be verified corresponding to the remaining ROI1 participate in the formation of two key point vector pairs, namely [Qroi1, Qroir1] and [Qroi1, Qroir2]; the feature vectors of the key points to be verified corresponding to ROI2 participate in the formation of a key point vector pair, namely [Qroi2, Qroir4]; the feature vectors of the key points to be verified corresponding to ROI3 participate in the formation of a key point vector pair, namely [Qroi3, Qroir7]. There are four combinations of any three of the above four key point vector pairs, that is, there are four combinations of "three key point vector pairs". For each of them, it can be judged that the absolute value of the difference between the angle of the key point to be verified and the angle of the pre-registered key point is not greater than the angle threshold θ0, and then it is determined whether the three key point vector pairs in this combination meet the distance constraint. Take the combination of [Qroi1, Qroir1], [Qroi2, Qroir4] and [Qroi3, Qroir7] as an example. Fig.35As shown, the angle of one of the key points to be verified in the combination is the angle θ between the line segment between ROI1 and ROI2 and the line segment between ROI2 and ROI3, and the angle of the pre-registered key point is the angle θr between the line segment between ROIR1 and ROIR4 and the line segment between ROIR4 and ROIR8; if |θ-θr|>θ0, it is determined that ROI1, ROI2, ROI3, ROIR1, ROIR4 and ROIR7 do not meet the distance constraint condition; otherwise, if |θ-θr|≤θ0, it is determined that the above key points meet the angle constraint condition. The determination method of the other three combinations is similar to this and will not be repeated.

[0384] Similarly, since any key point vector pair may form multiple combinations with multiple other key point vector pairs, and the judgment results of these combinations are not exactly the same, in order to avoid misjudgment, when any combination satisfies the angle constraint condition, it is determined that the two key point vector pairs participating in the combination satisfy the angle constraint condition, and there is no need to check whether the other combinations formed by the three key point vector pairs meet the condition. Of course, in order to increase the screening strength of the angle constraint condition, a threshold value of the number of times the key point vector pair meets the condition can also be set. For example, if it is set to three times, any key point vector pair needs to meet the condition with at least the combination formed by the other three key point vector pairs before it is determined that the key point vector pair meets the condition. This will not be repeated.

[0385] Each check of the common constraint condition requires a key point vector pair, that is, each key point vector pair can be checked by itself without combining. For example, for any key point vector pair, if the distance between the key point coordinates to be verified and the pre-registered key point coordinates of the key point vector pair is not greater than the distance threshold, and the angle between the line between the key point coordinates to be verified of any key point vector pair and the coordinate origin of the surface texture image to be verified and the line between the pre-registered key point coordinates of any key point vector pair and the coordinate origin of the corresponding pre-registered surface texture image is not greater than the angle threshold, then it is determined that the corresponding key point of any key point vector pair meets the common constraint condition.

[0386] like Fig.36As shown, assuming that after screening the distance constraint and the angle constraint, at least one key point vector pair may remain, taking the key point vector pair corresponding to ROI2 and ROIR4, that is, [Qroi2, Qroir4] as an example. At this time, the surface texture image to be verified can be used as a reference to determine the key point of ROIR4 in the same position in the image (that is, ROIR4' shown by the dotted line in the image), and then calculate whether the distance d between ROI2 and ROIR4' is greater than the distance threshold d0, and the angle θ between the line connecting ROI2 and the origin and the line connecting ROIR4' and the origin. If |d-dr|≤d0 and |θ-θr|≤θ0, it is determined that ROI2 and ROIR4 meet the above common constraints, otherwise (that is, |d-dr|>d0 and / or |θ-θr|>θ0), it is determined that the two do not meet the above common constraints.

[0387] It should be noted that the distance thresholds involved in the above-mentioned different constraints may be the same or different. Similarly, the angle thresholds involved in the above-mentioned different constraints may be the same or different. The specific values ​​of the thresholds may be reasonably set according to accuracy requirements, screening intensity requirements, etc., and this specification does not limit this.

[0388] Through the above screening process based on geometric consistency constraints, some target key point vector pairs whose corresponding key points meet the geometric consistency constraints can be further screened out from each group of key point vector pairs screened based on vector similarity.

[0389] The embodiment of the present scheme realizes verification of the object to be verified by comparing the surface texture image to be verified with the pre-registered surface texture image. The reliability of the above comparison result is based on the following general rule: the surface texture image collected from the object can reflect the microscopic texture of the surface of the object. For any two identical surface texture images and any two key points respectively identified from the two images, if the positions of the two key points in the corresponding images are the same (or close), then the local textures of the two key points are also the same (or close). This scheme characterizes the local micro-texture of the key point through the key point feature vector corresponding to the key point. It can be understood that: for the aggregate feature vector to be verified of each key point to be verified identified in the surface texture image to be verified and the pre-registered aggregate feature vector of each pre-registered key point identified in each pre-registered surface texture image, if the object to be verified is not a pre-registered object, each pre-registered surface texture image will not match the surface texture image to be verified. Therefore, the key points to be verified in the surface texture image to be verified and the pre-registered key points in each pre-registered surface texture image are unlikely to satisfy the geometric consistency constraint (the condition is used to constrain the relative position of the key points); in addition, if the object to be verified is a pre-registered object (that is, the two are the same object), the pre-registered surface texture image collected from the pre-registered object will match the surface texture image to be verified; accordingly, since at least one key point to be verified is identified in the pre-registered surface texture image and at least one pre-registered key point is identified in the surface texture image to be verified, the positions of the key points in the corresponding images are not exactly the same, so only the positions of the key points corresponding to some key point vector pairs satisfy the above general rules. It can be seen that, in at least a portion of the pre-registered surface texture images recalled in the rough screening stage, there may still be some pre-registered surface texture images whose positions of key points do not satisfy the above general rules.

[0390] In this regard, for the key point vectors in at least a portion of the pre-registered surface texture images recalled in the rough screening stage, the embodiments of this specification use vector similarity and geometric consistency constraints to perform more detailed screening again in the fine screening stage, and can screen out the key point vector pairs whose corresponding key points do not meet the above general rules, thereby further reducing the number of images that need to be compared in the subsequent comparison process. Therefore, this solution not only reduces the computing power requirements for the verification party (such as the buyer of the product) in the verification stage, and reduces the difficulty of applying the solution; but also improves the verification efficiency because the amount of calculation is reduced, which helps to achieve batch verification of a large number of items.

[0391] Based on the same concept as the above method, this specification also provides an electronic device, including: a processor; a memory for storing processor executable instructions; wherein the processor implements the steps of the method described in any of the above embodiments by running the executable instructions.

[0392] Based on the same concept as the above method, this specification also provides a computer-readable storage medium on which computer instructions are stored. When the instructions are executed by a processor, the steps of the method described in any of the above embodiments are implemented.

[0393] Based on the same concept as the above method, this specification also provides a computer program product, including a computer program / instruction, which implements the steps of the method described in any of the above embodiments when executed by a processor.

Claims

1. An object verification system based on surface texture images, characterized in that: The system includes: An image acquisition module, used to instruct the image acquisition device of the registration party to respectively acquire corresponding pre-registered surface texture images for N pre-registered objects during the registration phase, where N is a positive integer; and used to instruct the image acquisition device of the verification party to acquire the surface texture image to be verified for the object to be verified during the verification phase; An item registration module, used to instruct the server to obtain and maintain pre-registered texture description information extracted from the N pre-registered surface texture images collected by the image acquisition module during the registration phase; The object verification module is used to instruct the verification party device or the server to obtain the texture description information to be verified extracted from the surface texture image to be verified during the verification phase, and determine whether the object to be verified is one of the N pre-registered objects based on the comparison result between the texture description information to be verified and the N pre-registered texture description information.

2. The system according to claim 1, characterized in that The image acquisition module is further used to send the acquired N pre-registered surface texture images to the object registration module, and the object registration module is specifically used to extract corresponding pre-registered texture description information from the received N pre-registered surface texture images respectively; or, The image acquisition module is also used to extract corresponding pre-registered texture description information from the collected N pre-registered surface texture images and send it to the object registration module.

3. The system according to claim 1, characterized in that The system further comprises: A height determination module, used to determine a target height according to the thickness of any pre-registered object to be imaged; wherein the target height is the sum of the thickness of the pre-registered object and the initial height, and the initial height is the spacing distance between the image acquisition device of the registration party and the surface of the conveying device when the image acquisition device of the registration party meets the shooting conditions required by the pre-registered object and the surface of the conveying device is clearly focused; An adjustment control module, used for controlling the posture control device to adjust the image acquisition device of the registration party to the target height; The image acquisition module is specifically used to instruct the image acquisition device of the registration party to acquire a corresponding registration surface texture image for any pre-registered object placed on the conveying device at the target height.

4. The system according to claim 3, characterized in that The system further comprises: A focus control module is used to determine the target pixel accuracy required for image acquisition when the shooting conditions include pixel accuracy, and determine the initial height according to the target pixel accuracy and the device parameters of the registration party image acquisition device; and control the posture control device to adjust the registration party image acquisition device to the initial height, and obtain the adjustment completion message generated by the posture control device to trigger the registration party image acquisition device to focus.

5. The system according to claim 3 or 4, characterized in that: The registration party image acquisition device is a line scan camera.

6. The system according to claim 1, characterized in that The system further comprises: An information extraction and sending module, used to extract corresponding texture description information to be verified from the surface texture image to be verified acquired by the image acquisition device of the verification party, and send it to the item registration module; or The image sending module is used to send the surface texture image to be verified collected by the verification party image acquisition device to the object registration module, and the object registration module is also used to extract the corresponding texture description information to be verified from the received surface texture image to be verified.

7. The system according to claim 1, characterized in that The image acquisition module is specifically used for: Controlling the image acquisition device of the verification party to independently acquire the texture image of the surface to be verified without being controlled by other devices; or, The image acquisition device of the verification party is controlled to acquire the texture image of the surface to be verified according to the image acquisition instruction sent by other devices.

8. The system according to claim 1, characterized in that The system further comprises: The information display module is used to display the operation prompt information for the verification party image acquisition device to prompt the verification party user to operate the verification party image acquisition device according to a preset operation method to acquire the surface texture image to be verified.

9. The system according to claim 1, characterized in that Texture description information includes sub-image location information, key point description information and aggregated feature vectors. The system further comprises a sub-image division module, which is used to divide the pre-registered surface texture image according to a preset size to obtain pre-registered sub-images, and for each pre-registered sub-image: determine the pre-registered sub-image position information of the pre-registered sub-image in the pre-registered surface texture image to which it belongs, identify the pre-registered key points in the pre-registered sub-image, and extract the pre-registered key point description information of each pre-registered key point and the pre-registered aggregated feature vector corresponding to the pre-registered sub-image based on the identification result; The object registration module is specifically used to associate and store the pre-registered sub-image position information, pre-registered key point description information and pre-registered aggregated feature vector corresponding to each pre-registered sub-image obtained by dividing each pre-registered surface texture image in a vector database; The item verification module is specifically used for: A sub-image to be verified is intercepted from the surface texture image to be verified through the sliding window of the preset size, and for each sub-image to be verified: the sub-image position information of the sub-image to be verified in the surface texture image to be verified is determined, key points to be verified in the sub-image to be verified are identified, and key point description information to be verified of each key point to be verified and a clustered feature vector to be verified of the sub-image to be verified are extracted based on the identification result; For each aggregate feature vector to be verified: a group of pre-registered aggregate feature vectors with the highest vector similarity with the aggregate feature vector to be verified are retrieved from the vector database, and the aggregate feature vector to be verified and each feature vector in the group of pre-registered aggregate feature vectors respectively constitute an aggregate vector pair; according to the position information of each sub-graph to be verified and each pre-registered sub-graph in the corresponding surface texture image, a target aggregate vector pair of corresponding sub-graphs satisfying geometric consistency constraints is screened out from the aggregate vector pairs constituted by the aggregate feature vectors to be verified, and at least a part of the pre-registered surface texture image corresponding to the target aggregate vector pair is recalled; Obtain description information of key points to be verified corresponding to the key points to be verified identified from the surface texture image to be verified and pre-registered description information of key points corresponding to the pre-registered key points identified from each recalled pre-registered surface texture image, and determine whether the object to be verified is one of the N pre-registered objects based on a comparison result between the description information of key points to be verified and the description information of pre-registered key points.

10. The system according to claim 9, characterized in that The key point description information includes key point position information and key point feature vectors corresponding to the key points. The object verification module is specifically used for: For each key point feature vector to be verified that is obtained: a group of pre-registered key point feature vectors having the highest vector similarity with the key point feature vector to be verified are retrieved from the obtained pre-registered key point feature vectors, the key point feature vector to be verified and each feature vector in the group of pre-registered key point feature vectors respectively forming a key point vector pair, and the retrieved pre-registered key point vectors correspond to a group of pre-registered surface texture images in the at least a portion of the recalled pre-registered surface texture images; Filter out target key point vector pairs whose corresponding key points satisfy geometric consistency constraints from the key point vector pairs formed by the acquired key point feature vectors to be verified; Determine whether there is an image matching the surface texture image to be verified in the pre-registered surface texture images corresponding to the target key point vector pair, wherein if there is no pre-registered surface texture image matching the surface texture image to be verified, it is determined that the object to be verified is not one of the N pre-registered objects, and if there is a pre-registered surface texture image matching the surface texture image to be verified, the object to be verified is the pre-registered object corresponding to the pre-registered surface texture image.

11. The system according to claim 1, characterized in that The object registration module is specifically used to maintain a mapping relationship between the object description information of the pre-registered object corresponding to any pre-registered surface texture image and the pre-registered texture description information extracted from any pre-registered surface texture image; The system further includes an information output module, which is used to output the item description information of the pre-registered item acquired according to the mapping relationship when it is determined that the item to be verified is one of the N pre-registered items.

12. An object verification method based on surface texture images, characterized in that: The method is applied to an item verification system including an image acquisition module, an item registration module and an item verification module, and the method includes: The image acquisition module is used to instruct the image acquisition device of the registration party to respectively acquire corresponding pre-registered surface texture images for N pre-registered objects during the registration phase, where N is a positive integer; and to instruct the image acquisition device of the verification party to acquire the surface texture image to be verified for the object to be verified during the verification phase; The object registration module instructs the server to obtain and maintain the pre-registered texture description information extracted from the N pre-registered surface texture images collected by the image acquisition module during the registration phase; During the verification phase, the object verification module instructs the verification party device or the server to obtain the texture description information to be verified extracted from the surface texture image to be verified, and determines whether the object to be verified is one of the N pre-registered objects based on the comparison result between the texture description information to be verified and the N pre-registered texture description information.

13. The method according to claim 12, characterized in that The article verification system further includes a height determination module and an adjustment control module, and the method further includes: The height determination module determines the target height according to the thickness of any pre-registered object to be imaged; wherein the target height is the sum of the thickness of the pre-registered object and the initial height, and the initial height is the spacing distance between the image acquisition device of the registration party and the surface of the conveying device when the image acquisition device of the registration party meets the shooting conditions required by the pre-registered object and the surface of the conveying device is clearly focused; The adjustment control module controls the posture control device to adjust the registration party image acquisition device to the target height; The image acquisition module is specifically used to instruct the image acquisition device of the registration party to acquire a corresponding registration surface texture image for any pre-registered object placed on the conveying device at the target height.

14. The method according to claim 12, characterized in that The article verification system further includes an information extraction and sending module or an image sending module, and the method further includes: The information extraction and sending module extracts the corresponding texture description information to be verified from the surface texture image to be verified acquired by the image acquisition device of the verification party, and sends it to the item registration module; or, The image sending module sends the surface texture image to be verified acquired by the image acquisition device of the verification party to the object registration module, and the object registration module is further used to extract corresponding texture description information to be verified from the received surface texture image to be verified.

15. An electronic device, characterized in that: include: processor; A memory for storing processor-executable instructions; wherein the processor implements the steps of the method according to any one of claims 12 to 14 by executing the executable instructions.

16. A computer-readable storage medium, characterized in that: Computer instructions are stored thereon, and when the instructions are executed by a processor, the steps of the method according to any one of claims 12 to 14 are implemented.

17. A computer program product, characterized in that The method comprises a computer program / instruction, which, when executed by a processor, implements the steps of the method according to any one of claims 12 to 14.

Citation Information

Cited By

  • Method and device for comparing surface texture images

    CN118537587A