Ancient Coin Multi-Type Fine Recognition Method and System Optimized Based on Artificial Intelligence Architecture

By adopting artificial intelligence architecture optimization methods in ancient coin image processing, including light equalization processing, noise filtering and texture enhancement processing, combined with pre-trained ancient coin recognition model and historical database, the problem of low recognition accuracy of ancient coin is solved, and the fine recognition and identification of many types of ancient coin is achieved.

CN119919930BActive Publication Date: 2025-06-20WEIPAITANG
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510387195.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-03-31
Publication Date
2025-06-20
Estimated Expiration
2045-03-31

AI Technical Summary

Technical Problem

The prior art faces problems of uneven lighting, noise interference and difficult to capture texture details in the image processing of ancient coins, resulting in low recognition accuracy of ancient coins and the inability to achieve fine recognition of multiple types of ancient coins.

Method used

Using an artificial intelligence architecture optimization method, the original ancient coin image data is collected through multi-spectral imaging equipment, light equalization processing and noise filtering are performed to generate a standardized initial image. Then, texture enhancement processing based on edge-keeping algorithm is performed to generate the target ancient coin image. Finally, the pre-trained target ancient coin recognition model is called for identification, and the historical ancient coin database is retrieved based on the recognition results to construct a fine identification report.

Benefits of technology

It realizes the fine recognition of many types of ancient coins, improves the accuracy and efficiency of ancient coins identification, and overcomes the problems of uneven lighting, noise interference and difficult to capture texture details.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119919930B_ABST
    Figure CN119919930B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and system for fine recognition of multiple types of ancient coins based on the optimization of the artificial intelligence architecture, including: First, collecting the original ancient coin image data through a multispectral imaging device, generating a standardized initial image through illumination equalization and noise filtering, and then performing enhancement processing with texture enhancement to obtain a target image. Then, calling a pre-trained target ancient coin recognition model to identify the type of ancient coin and obtain a type identifier. Finally, retrieving the historical ancient coin database according to the identifier, outputting relevant data and constructing a fine recognition report, realizing the fine recognition of multiple types of ancient coins, and improving the accuracy and efficiency of identification.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of artificial intelligence technology. Specifically, it relates to a method and system for fine recognition of multiple types of ancient coins based on the optimization of the artificial intelligence architecture. Background Art

[0002] Traditional identification of ancient coins mainly relies on the experience and professional knowledge of experts. However, this method has problems such as low efficiency and strong subjectivity, and the expert resources are limited, making it difficult to meet the needs of a large number of ancient coin identifications. With the development of artificial intelligence technology, using image recognition technology for ancient coin type recognition has become a research hotspot. However, when dealing with ancient coin images, existing methods face problems such as uneven illumination, noise interference, and difficulty in capturing texture details, resulting in low recognition accuracy and inability to achieve fine recognition of multiple types of ancient coins. Therefore, there is an urgent need for a method for fine recognition of multiple types of ancient coins based on the optimization of the artificial intelligence architecture to improve the accuracy and efficiency of ancient coin recognition. Summary of the Invention

[0003] The purpose of the present invention is to provide a method and system for fine recognition of multiple types of ancient coins based on the optimization of the artificial intelligence architecture.

[0004] In a first aspect, an embodiment of the present invention provides a method for fine recognition of multiple types of ancient coins based on the optimization of the artificial intelligence architecture, including:

[0005] Collecting original ancient coin image data through a multispectral imaging device, and performing illumination equalization processing and noise filtering on the original ancient coin image data to generate a standardized initial ancient coin image;

[0006] Performing enhancement processing on the initial ancient coin image to generate a target ancient coin image, where the enhancement processing includes texture enhancement processing based on an edge-preserving algorithm;

[0007] Invoking a pre-trained target ancient coin recognition model to perform ancient coin type recognition on the target ancient coin image to obtain the ancient coin type identifier of the target ancient coin image;

[0008] Triggering a directional retrieval of a preset historical ancient coin database based on the ancient coin type identifier, outputting the ancient coin-related data corresponding to the ancient coin type identifier, and constructing a fine recognition report of the ancient coin type based on the ancient coin-related data.

[0009] In a second aspect, an embodiment of the present invention provides a server system, including a server, where the server is used to execute the method described in the first aspect.

[0010] Compared with the prior art, the beneficial effects provided by the present invention include: adopting a multi-type fine recognition method and system for ancient coins optimized based on an artificial intelligence architecture, including: first, collecting original ancient coin image data through a multi-spectral imaging device, generating a standardized initial image through illumination equalization and noise filtering, and then performing enhancement processing with texture enhancement to obtain a target image. Then, call a pre-trained target ancient coin recognition model to identify the type of ancient coin and obtain a type identifier. Finally, retrieve the historical ancient coin database based on the identifier, output relevant data, and construct a fine recognition report to achieve multi-type fine recognition of ancient coins and improve the accuracy and efficiency of identification. BRIEF DESCRIPTION OF THE DRAWINGS

[0011] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as limiting the scope. For those of ordinary skill in the art, other related drawings can also be obtained based on these drawings without creative efforts.

[0012] Figure 1 It is a schematic flow chart of the steps of the multi-type fine recognition method for ancient coins optimized based on an artificial intelligence architecture provided by an embodiment of the present invention;

[0013] Figure 2 It is a schematic block diagram of the structure of a computer device provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0014] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. Usually, the components of the embodiments of the present invention described and shown in the drawings here can be arranged and designed in various different configurations.

[0015] The following will describe in detail the specific embodiments of the present invention with reference to the drawings.

[0016] To solve the technical problems in the foregoing background art, Figure 1 It is a schematic flow chart of the multi-type fine recognition method for ancient coins optimized based on an artificial intelligence architecture provided by an embodiment of the present disclosure. The following will introduce in detail the multi-type fine recognition method for ancient coins optimized based on an artificial intelligence architecture.

[0017] Step S201, collect original ancient coin image data through a multi-spectral imaging device, and perform illumination equalization processing and noise filtering on the original ancient coin image data to generate a standardized initial ancient coin image;

[0018] Step S202: Perform enhancement processing on the initial ancient coin image to generate a target ancient coin image. The enhancement processing includes texture strengthening processing based on an edge-preserving algorithm;

[0019] Step S203: Invoke a pre-trained target ancient coin recognition model to perform ancient coin type recognition on the target ancient coin image, and obtain the ancient coin type identifier of the target ancient coin image;

[0020] Step S204: Trigger a directional retrieval of a preset historical ancient coin database based on the ancient coin type identifier, output the ancient coin-related data corresponding to the ancient coin type identifier, and construct a refined ancient coin type recognition report based on the ancient coin-related data.

[0021] In an embodiment of the present invention, exemplarily, the server controls a multispectral imaging device to collect images of ancient coins. For example, in an ancient coin identification laboratory, staff place the ancient coin to be identified within the shooting area of the multispectral imaging device. The server sends an instruction to the multispectral imaging device, and the device takes pictures of the ancient coin from multiple spectral bands according to preset parameters to obtain the original ancient coin image data. There may be problems of uneven illumination and noise interference in these image data. For illumination equalization processing, the server analyzes the brightness values of each pixel point in the original ancient coin image data. For example, if the left part of the ancient coin image is brighter and the right part is darker, the server will use algorithms such as histogram equalization to adjust the brightness distribution of the image. It will count the number of pixels at each brightness level in the image, and then redistribute the brightness values according to the statistical results, making the overall brightness of the image more uniform, just like adding a uniform "lighting" effect to the ancient coin image. In terms of noise filtering, the server will use algorithms such as median filtering or Gaussian filtering. For example, when there is salt-and-pepper noise (some randomly appearing black and white pixel points) in the image, the server uses the median filtering algorithm. For each pixel point, it will select the pixel value of this pixel point and its neighboring pixels, and then sort these values and take the median value as the new value of this pixel point, thereby removing the noise and making the image clearer. After illumination equalization processing and noise filtering, the server generates a standardized initial ancient coin image, which has uniform brightness and less noise, and is more conducive to subsequent processing. The server performs enhancement processing on the generated initial ancient coin image, including texture enhancement processing based on edge-preserving algorithms. Taking an ancient coin with complex patterns as an example, the server will identify the edge information in the ancient coin image, such as the outlines of the characters and patterns on the ancient coin. It uses edge-preserving algorithms such as bilateral filtering to retain the edge information while smoothing the image. Bilateral filtering takes into account the spatial distance of pixel points and the similarity of pixel values. Pixel points that are close and have similar pixel values are smoothed, while pixel points with large differences in pixel values at the edges retain their original values. In terms of texture enhancement, the server will enhance the details of the texture in the ancient coin image. For example, some fine patterns on the ancient coin may not be very obvious in the initial image. The server will sharpen the image through algorithms such as the Laplacian operator. The Laplacian operator calculates the second-order derivative of each pixel point in the image, enhancing the regions with large gray-scale changes in the image, thereby highlighting the texture details of the ancient coin and making the characters and patterns on the ancient coin clearer and distinguishable. After these enhancement processes, the server generates a target ancient coin image, which has clearer texture and more obvious features. The server calls a pre-trained target ancient coin recognition model to process the target ancient coin image. This target ancient coin recognition model is trained with a large amount of ancient coin image data. For example, during the training phase, the model learns the features of various different types of ancient coins, such as shape, size, characters, patterns, etc.When the server inputs the target ancient coin image into the target ancient coin recognition model, the model will extract and analyze the features of the image. It will identify the shape of the ancient coin to determine whether it is round, square, or other special shapes; analyze the characters on the ancient coin to determine the font, content, etc. of the characters; and also observe the patterns on the ancient coin, such as dragons and phoenixes, flowers, etc. Based on these features, the model will match them with the types of ancient coins it has learned. Suppose the target ancient coin image is an ancient coin with a round hole in the square, and there are the characters "Kaiyuan Tongbao" on it. During the analysis process, the model will compare these features with the features of various ancient coin types in its knowledge base, and finally determine that the type of this ancient coin is Kaiyuan Tongbao of the Tang Dynasty, and output the corresponding ancient coin type identifier, such as "T001" (assuming this is the identifier of Kaiyuan Tongbao). The server triggers the directional retrieval of the preset historical ancient coin database according to the obtained ancient coin type identifier "T001". A large amount of relevant data of different types of ancient coins is stored in the historical ancient coin database, including information such as the historical background, casting process, market value, and rarity of the ancient coins. The server searches for the ancient coin-related data corresponding to "T001" in the database. For example, it will find the historical information of Kaiyuan Tongbao, such as Kaiyuan Tongbao was first cast in the fourth year of Wude of Emperor Gaozu of the Tang Dynasty and was the main currency in circulation in the Tang Dynasty; in terms of the casting process, the lost-wax casting method was adopted, etc.; the market value will vary according to factors such as the condition and rarity of the ancient coin; in terms of rarity, ordinary Kaiyuan Tongbao is relatively common, but some special editions of Kaiyuan Tongbao are relatively rare. The server sorts out and analyzes these retrieved ancient coin-related data, and constructs a detailed identification report of the ancient coin type based on these data. The report will include the basic information of the ancient coin, such as type, age, etc.; a detailed introduction to the historical background and casting process; an assessment of the market value of the ancient coin and an explanation of its rarity, etc. Finally, the server outputs the generated detailed identification report of the ancient coin type, providing comprehensive and detailed ancient coin information for ancient coin appraisers or relevant researchers.

[0022] In the embodiment of the present invention, the target ancient coin recognition model is trained in the following manner.

[0023] Obtain an ancient coin recognition model and sample ancient coin images. The ancient coin training images in the sample ancient coin images include first ancient coin training images and second ancient coin training images. The first ancient coin training images are marked with their corresponding ancient coin type identifiers, and the second ancient coin training images are unlabeled ancient coin training images;

[0024] For each ancient coin training image, perform region division processing on the ancient coin training image to obtain multiple ancient coin sub-images of the ancient coin training image;

[0025] Through the ancient coin recognition model, feature extraction processing is respectively performed on the ancient coin training image and each ancient coin sub-image of the ancient coin training image to obtain the coarse-grained image features of the ancient coin training image and the fine-grained image features corresponding to each ancient coin sub-image;

[0026] According to the ancient coin type identifier of the first ancient coin training image, contrastive learning is performed on the coarse-grained image features of each ancient coin training image in the sample ancient coin image to obtain the ancient coin type identifier corresponding to the second ancient coin training image;

[0027] For each ancient coin sub-image of the ancient coin training image, according to the fine-grained image features corresponding to the ancient coin sub-image and the coarse-grained image features of the ancient coin training image to which the ancient coin sub-image belongs, calculate the multi-granularity feature alignment degree between the ancient coin sub-image and the ancient coin training image to which the ancient coin sub-image belongs;

[0028] According to the multi-granularity feature alignment degree and the ancient coin type identifier corresponding to the second ancient coin training image, the parameters of the ancient coin recognition model are iteratively optimized to obtain the target ancient coin recognition model.

[0029] In an embodiment of the present invention, exemplarily, the server obtains a predefined ancient coin recognition model architecture from a storage device. This model architecture is like a "framework" waiting to be filled with knowledge. At the same time, the server collects a large number of sample ancient coin images from different channels, such as the ancient coin photo library in a museum, the shooting materials at an archaeological excavation site, etc. The ancient coin training images in the sample ancient coin images are divided into the first ancient coin training images and the second ancient coin training images. The first ancient coin training images have been labeled with corresponding ancient coin type identifiers by professionals. For example, an ancient coin image labeled as "Qianlong Tongbao of the Qing Dynasty"; while the second ancient coin training images have not been labeled yet. For each ancient coin training image, the server uses an image segmentation algorithm to perform region division. Taking a round ancient coin with a square hole as an example, the server divides it into multiple ancient coin sub-images, such as separating the square hole part, the text area, the edge pattern area, etc., to obtain multiple independent ancient coin sub-images. The purpose of doing this is to analyze the different features of the ancient coin more meticulously. The server extracts features from the ancient coin training images and each of their ancient coin sub-images through the ancient coin recognition model. For the ancient coin training images, the server obtains their overall shape, size and other visual features in the visual feature domain, as well as the inscription features such as the approximate text content in the semantic feature domain. After cross-domain feature integration and gated recurrent unit feature interaction, the server obtains the coarse-grained image features of the ancient coin training images, just like grasping the "overall outline" of the ancient coin. For each ancient coin sub-image, the server also obtains its sub-features in the visual and semantic feature domains, and obtains the corresponding fine-grained image features after processing, just like deeply understanding the "detail texture" of the ancient coin. The server performs contrastive learning on the coarse-grained image features of all ancient coin training images according to the ancient coin type identifiers of the first ancient coin training images. For example, the server sets ancient coin type templates with a category base number, and calculates the feature fitness of the coarse-grained image features of each ancient coin training image with each template. If the coarse-grained image features of an unlabeled ancient coin training image have a high fitness with the ancient coin training image labeled as "Kaiyuan Tongbao of the Tang Dynasty", the server will add it to the ancient coin type pool corresponding to "Kaiyuan Tongbao of the Tang Dynasty". Through continuous iteration, the server determines the ancient coin type templates that meet the feature fluctuation threshold range, and then obtains the ancient coin type identifiers corresponding to the second ancient coin training images. For each ancient coin sub-image of the ancient coin training images, the server calculates the multi-granularity feature alignment degree between its fine-grained image features and the coarse-grained image features of the ancient coin training image to which it belongs. For example, if the ancient coin sub-image is the text area on the ancient coin, the server analyzes the matching degree between the detailed features of the text and the overall features of the ancient coin to determine the multi-granularity feature alignment degree. The server iteratively optimizes the parameters of the ancient coin recognition model according to the multi-granularity feature alignment degree and the ancient coin type identifiers corresponding to the second ancient coin training images. The server will calculate the coarse-grained error parameter and the fine-grained error parameter, and continuously adjust the parameters of the model according to these error parameters to continuously improve the recognition accuracy of the model.After multiple iterations, the server obtains a target ancient coin recognition model, which can more accurately identify the types of ancient coins.

[0030] In the embodiment of the present invention, comparing and learning the coarse-grained image features of each ancient coin training image in the sample ancient coin image according to the ancient coin type identifier of the first ancient coin training image to obtain the ancient coin type identifier corresponding to the second ancient coin training image can be implemented through the following examples.

[0031] Set ancient coin type templates with a class cardinality, and calculate the feature fitness between the coarse-grained image features of each ancient coin training image in the sample ancient coin image and each ancient coin type template;

[0032] For each ancient coin training image, determine the target ancient coin type template adjacent to the features of the ancient coin training image from each ancient coin type template according to the feature fitness and the ancient coin type identifier of the first ancient coin training image, and add the ancient coin training image to the ancient coin type pool corresponding to the target ancient coin type template;

[0033] For the ancient coin type pool corresponding to each ancient coin type template, select the ancient coin training image with the highest type representativeness in the ancient coin type pool as the evolved ancient coin type template;

[0034] Repeat the step of calculating the feature fitness between the coarse-grained image features of each ancient coin training image in the sample ancient coin image and each ancient coin type template until the determined ancient coin type template meets the feature fluctuation threshold range; determine the ancient coin type identifier of the second ancient coin training image in the target ancient coin image set according to the ancient coin type identifier of the first ancient coin training image in the target ancient coin image set corresponding to the ancient coin type template that meets the feature fluctuation threshold range.

[0035] In an embodiment of the present invention, exemplarily, the server first sets up coin type templates with category bases according to known ancient coin types. These templates are like standard reference samples, covering the typical characteristics of ancient coins of different dynasties and different shapes. For example, for common ancient coin types such as the Han Dynasty Wu Zhu coin, the Tang Dynasty Kai Yuan Tong Bao coin, and the Song Dynasty Da Guan Tong Bao coin, the server extracts representative features from a large number of labeled first ancient coin training images to construct corresponding ancient coin type templates. Then, for each ancient coin training image in the sample ancient coin images, the server extracts its coarse-grained image features. The coarse-grained image features include information such as the overall outline, general shape, and color distribution of the ancient coin. The server determines the similarity degree between the ancient coin training image and each ancient coin type template by calculating the feature fitness degree between these coarse-grained image features and each ancient coin type template. When calculating the feature fitness degree, the server will adopt methods such as cosine similarity and Euclidean distance. For example, for an ancient coin training image, the server calculates that the cosine similarity between its coarse-grained image feature vector and the Han Dynasty Wu Zhu coin template is 0.7, and the cosine similarity with the Tang Dynasty Kai Yuan Tong Bao coin template is 0.3, which indicates that the ancient coin training image has a higher feature fitness degree with the Han Dynasty Wu Zhu coin template. For each ancient coin training image, the server determines the target ancient coin type template adjacent to the features of the ancient coin training image from all ancient coin type templates according to the calculated feature fitness degree and the ancient coin type identifier of the first ancient coin training image. If the feature fitness degree of a certain ancient coin training image is the highest with the Han Dynasty Wu Zhu coin template, and it is known that the identifier of the Han Dynasty Wu Zhu coin in the first ancient coin training image is "Han-Wuzhu", then the server determines that the ancient coin training image is adjacent to the features of the Han Dynasty Wu Zhu coin. Subsequently, the server adds the ancient coin training image to the ancient coin type pool corresponding to the target ancient coin type template. For example, for the ancient coin training image determined to be adjacent to the features of the Han Dynasty Wu Zhu coin, the server adds it to the ancient coin type pool corresponding to the Han Dynasty Wu Zhu coin template. In this way, each ancient coin type pool gradually gathers ancient coin training images similar to the features of the ancient coin type. For each ancient coin type pool corresponding to an ancient coin type template, the server needs to select the ancient coin training image with the highest type representativeness from it as the evolved ancient coin type template. The server will comprehensively consider factors such as the feature stability of the ancient coin training image and the similarity with other images. For example, in the ancient coin type pool of the Han Dynasty Wu Zhu coin, the server will analyze the coarse-grained image features of each ancient coin training image and find the images with the most typical features that can represent the general features of the Han Dynasty Wu Zhu coin. Suppose the shape, characters, perforation, etc. of an ancient coin training image are highly consistent with the features of most Han Dynasty Wu Zhu coins, and the feature changes under different angles and lighting conditions are small, then the server will use this image as the evolved ancient coin type template of the Han Dynasty Wu Zhu coin. The server repeats the step of calculating the feature fitness degree between the coarse-grained image features of each ancient coin training image in the sample ancient coin images and each ancient coin type template.As the ancient coin type templates continue to evolve, the server will continuously update the target ancient coin type templates and the ancient coin type pool to which each ancient coin training image belongs. This process will continue until the determined ancient coin type template meets the characteristic fluctuation threshold range. The characteristic fluctuation threshold range is a standard preset by the server to measure the stability of the ancient coin type template. When the characteristics of the ancient coin type template change by less than this threshold after multiple iterations, it indicates that the template has become relatively stable. Finally, the server determines the ancient coin type identifier of the second ancient coin training image in the target ancient coin image set based on the ancient coin type identifier of the first ancient coin training image corresponding to the ancient coin type template that meets the characteristic fluctuation threshold range. For example, in the target ancient coin image set corresponding to the stable ancient coin type template of the Han Dynasty Wu Zhu coins, if the identifiers of some of the first ancient coin training images are known to be "Han-Wuzhu", then the server will also label the second ancient coin training images in this image set as "Han-Wuzhu". In this way, the server completes the annotation of the second ancient coin training images, providing richer annotation data for the subsequent training of the ancient coin recognition model.

[0036] In the embodiment of the present invention, the obtaining of the ancient coin type identifier corresponding to the second ancient coin training image by performing contrastive learning on the coarse-grained image features of each ancient coin training image in the sample ancient coin image according to the ancient coin type identifier of the first ancient coin training image can be implemented through the following examples.

[0037] Determine the sample feature fitness between every two ancient coin training images according to the coarse-grained image features of every two ancient coin training images;

[0038] Construct an ancient coin association hypergraph according to the sample feature fitness, where the ancient coin association hypergraph represents the association topology between each ancient coin training image;

[0039] Perform type feature propagation processing on the ancient coin type identifier of the first ancient coin training image according to the ancient coin association hypergraph to obtain the ancient coin type identifier corresponding to the second ancient coin training image.

[0040] In an embodiment of the present invention, exemplarily, the server first obtains the coarse-grained image features of all ancient coin training images in the sample ancient coin images. These coarse-grained image features contain macroscopic information such as the overall shape, approximate size, and color distribution of the ancient coins. The server will conduct a detailed comparison of the coarse-grained image features of every two ancient coin training images. For example, among numerous ancient coin training images, one image is of an ancient coin of Kaiyuan Tongbao in the Tang Dynasty, and another is of an ancient coin of Xining Yuanbao in the Song Dynasty. The server will extract the coarse-grained features of the ancient coin training image of Kaiyuan Tongbao, such as the round square hole, the layout of the front text, and the rust color distribution, etc.; and at the same time extract the corresponding features of the ancient coin training image of Xining Yuanbao. Then, the server uses specific similarity calculation methods, such as cosine similarity, Euclidean distance, etc., to determine the sample feature fit degree between these two ancient coin training images. If the calculated cosine similarity of these two images is 0.3, it indicates that their feature fit degree is relatively low. The server will perform such calculations for all pairs of ancient coin training images, thereby obtaining a comprehensive sample feature fit degree matrix, which records the feature similarity degree between any two ancient coin training images. The server constructs an ancient coin association hypergraph based on the calculated sample feature fit degree. The ancient coin association hypergraph is a graphical structure used to represent the complex relationships between ancient coin training images, which consists of feature units and topological connections. Each ancient coin training image corresponds to a feature unit, and the feature unit contains the coarse-grained image feature information of this ancient coin training image. The topological connection represents the association topology between two connected feature units, and its weight is determined by the sample feature fit degree. For example, if the sample feature fit degree between two ancient coin training images is relatively high, then the topological connection weight connecting their feature units is larger, which means that these two ancient coins are more similar in features and more closely associated; on the contrary, if the sample feature fit degree is relatively low, the weight of the topological connection is smaller. Suppose the server has 100 ancient coin training images, and it will establish corresponding topological connections for these 100 feature units. For the pair of ancient coin training images of Kaiyuan Tongbao with high feature fit degree, the server will connect their corresponding feature units with a thicker line (indicating a larger weight); while for the pair of images of Kaiyuan Tongbao and Xining Yuanbao with low feature fit degree, their feature units will be connected with a thinner line. In this way, the server constructs a complete ancient coin association hypergraph, clearly showing the association topological relationship between each ancient coin training image. The server uses the constructed ancient coin association hypergraph to perform type feature propagation processing on the ancient coin type identifier of the first ancient coin training image, so as to determine the ancient coin type identifier corresponding to the second ancient coin training image. In the ancient coin association hypergraph, the server starts from the feature unit of the first ancient coin training image with a known label, and through the topological connections between the feature units, spreads the feature information of its ancient coin type identifier to other connected feature units.For example, there is a first ancient coin training image clearly marked as "Kaiyuan Tongbao of the Tang Dynasty". The server will transmit the feature information of the type identifier "Kaiyuan Tongbao of the Tang Dynasty" to adjacent feature units along the topological connections associated with it. For the adjacent second ancient coin training image feature units, the server will preliminarily determine their reference ancient coin type identifiers based on the received type feature information and the association between this feature unit and other feature units. Then, for each second ancient coin training image, the server will perform predictive iterative optimization on the reference ancient coin type identifier according to the feature units adjacent to it in the ancient coin association hypergraph. This process will be repeated continuously until the results of the feature units in the ancient coin association hypergraph are stably determined. For example, after multiple iterations, a second ancient coin training image feature unit receives type feature information from multiple "Kaiyuan Tongbao of the Tang Dynasty" feature units, and its own features match those of these "Kaiyuan Tongbao of the Tang Dynasty" feature units more and more closely. Then the server will finally determine that the ancient coin type identifier corresponding to this second ancient coin training image is "Kaiyuan Tongbao of the Tang Dynasty". Through such a type feature propagation and iterative optimization process, the server determines the corresponding ancient coin type identifiers for all second ancient coin training images.

[0041] In the embodiment of the present invention, the ancient coin association hypergraph includes feature units corresponding to each ancient coin training image and topological connections between the feature units, and the topological connections represent the association topology between two connected feature units;

[0042] Performing type feature propagation processing on the ancient coin type identifier of the first ancient coin training image according to the ancient coin association hypergraph to obtain the ancient coin type identifier corresponding to the second ancient coin training image can be implemented through the following examples.

[0043] Performing type feature propagation processing on the ancient coin type identifier of the first ancient coin training image through the topological connections between feature units in the ancient coin association hypergraph to determine the reference ancient coin type identifier of the second ancient coin training image;

[0044] For each second ancient coin training image, performing predictive iterative optimization on the reference ancient coin type identifier of the second ancient coin training image according to the feature units adjacent to the second ancient coin training image in the ancient coin association hypergraph until the results of the feature units in the ancient coin association hypergraph are stably determined to obtain the ancient coin type identifier corresponding to the second ancient coin training image.

[0045] In an embodiment of the present invention, exemplarily, the server has first constructed an ancient coin association hypergraph including feature units corresponding to each ancient coin training image and topological connections between feature units. The existence of topological connections reflects the association topology between two connected feature units, and the tightness of this association topology is determined by the previously calculated sample feature fit. In this hypergraph, the server starts type feature propagation from the feature unit corresponding to the first ancient coin training image that has been labeled with the ancient coin type identifier. For example, among many ancient coin training images, there is a first ancient coin training image clearly marked as "Han Dynasty Wuzhu Coin", and its corresponding feature unit stores the coarse-grained image features of the ancient coin and the type identifier "Han Dynasty Wuzhu Coin". The server will pass the feature information of the type identifier "Han Dynasty Wuzhu Coin" to the adjacent feature unit along the topological connection connected to the feature unit. Assume that a feature unit adjacent to the "Han Dynasty Wuzhu Coin" feature unit corresponds to an unlabeled second ancient coin training image. After the server passes the type feature information of "Han Dynasty Wuzhu Coin", based on the received information and the coarse-grained image features of the feature unit itself, it preliminarily determines that the reference ancient coin type identification of this second ancient coin training image is "suspected Han Dynasty Wuzhu Coin". The server will perform such type feature propagation operations on the feature units corresponding to all the first ancient coin training images, thereby determining the initial reference ancient coin type identification for all the second ancient coin training images. For each second ancient coin training image, the server will predict and iterate the reference ancient coin type identification based on its neighboring feature units in the ancient coin association hypergraph. Taking the second ancient coin training image that was preliminarily determined to be "suspected Han Dynasty Wuzhu Coin" as an example, the server will check its other neighboring feature units in the ancient coin association hypergraph. If there are multiple neighboring feature units that correspond to the clearly marked "Han Dynasty Wuzhu Coin" first ancient coin training image, and the topological connection weight between these feature units and the feature units of the second ancient coin training image is large (that is, the sample feature fit is high), then the server will increase the credibility of the type identification of "Han Dynasty Wuzhu Coin". On the contrary, if some of the neighboring feature units correspond to other types of ancient coin training images, and there is a certain correlation between these feature units and the feature units of the second ancient coin training image (the topological connection has a certain weight), the server will comprehensively consider this information and adjust the reference ancient coin type identification. For example, it may be adjusted to "Han Dynasty Wuzhu coins or other similar ancient coins to be further confirmed." The server will continue to repeat this process of prediction and iterative optimization. With each iteration, more information from neighboring feature units will be integrated to make more accurate adjustments to the reference ancient coin type identification. In this process, the server will check whether the results of each feature unit in the ancient coin association hypergraph are stable. The so-called result stability judgment means that after multiple iterations, the ancient coin type identification corresponding to each feature unit no longer changes significantly.For example, after multiple iterations, the reference ancient coin type identifier of the feature unit corresponding to the second ancient coin training image has been steadily "Han Dynasty Wu Zhu coin", and its association relationship with the surrounding "Han Dynasty Wu Zhu coin" feature units has also remained stable. Then the server can determine that the result has been stabilized. At this time, the server determines that the ancient coin type identifier corresponding to this second ancient coin training image is "Han Dynasty Wu Zhu coin". The server will perform such an iterative optimization process on all the second ancient coin training images until the results of all feature units are stably determined, so as to determine the final corresponding ancient coin type identifiers for all the second ancient coin training images.

[0046] In the embodiment of the present invention, for each ancient coin sub-image of the ancient coin training image, according to the fine-grained image feature corresponding to the ancient coin sub-image and the coarse-grained image feature of the ancient coin training image to which the ancient coin sub-image belongs, calculating the multi-grained feature alignment degree between the ancient coin sub-image and the ancient coin training image to which the ancient coin sub-image belongs can be implemented through the following examples.

[0047] Construct a coarse-grained feature set according to the coarse-grained image features of each ancient coin training image, and construct a fine-grained feature set according to the fine-grained image features of the ancient coin sub-images of each ancient coin training image;

[0048] For each ancient coin training image, traverse at least one neighboring coarse-grained image feature adjacent to the coarse-grained image feature of the ancient coin training image in the coarse-grained feature set, and determine the category candidate of the ancient coin training image according to the ancient coin type identifier of the ancient coin training image to which the neighboring coarse-grained image feature belongs;

[0049] For each ancient coin sub-image of the ancient coin training image, traverse at least one neighboring fine-grained image feature adjacent to the fine-grained image feature of the ancient coin sub-image in the fine-grained feature set, and determine the category candidate of the ancient coin sub-image according to the ancient coin type identifier of the ancient coin training image to which the neighboring fine-grained image feature belongs;

[0050] Calculate the multi-grained feature alignment degree between the ancient coin sub-image and the ancient coin training image to which the ancient coin sub-image belongs according to the category candidate of the ancient coin sub-image and the category candidate of the ancient coin training image to which the ancient coin sub-image belongs.

[0051] In an embodiment of the present invention, exemplarily, the server has obtained the coarse-grained image features of all ancient coin training images and the fine-grained image features of each ancient coin sub-image. For the coarse-grained image features, it contains macroscopic information such as the overall shape, approximate size, and color distribution of the ancient coin; the fine-grained image features cover microscopic information such as the detailed texture, local patterns, and text strokes of the ancient coin sub-image. The server integrates the coarse-grained image features of all ancient coin training images together to construct a coarse-grained feature set. For example, if there are 100 ancient coin training images, the server combines these 100 coarse-grained image features into a set. Similarly, the server integrates the fine-grained image features of all ancient coin sub-images to construct a fine-grained feature set. Suppose these 100 ancient coin training images are divided into 500 ancient coin sub-images, and the server includes these 500 fine-grained image features in the fine-grained feature set. For each ancient coin training image, the server traverses the coarse-grained feature set. Taking an ancient coin training image labeled "Kaiyuan Tongbao of the Tang Dynasty" as an example, the server calculates the similarity between its coarse-grained image feature and other coarse-grained image features in the coarse-grained feature set, and finds at least one neighboring coarse-grained image feature with similar features. Assume that a neighboring coarse-grained image feature with a high similarity to it is found, and the ancient coin training image to which it belongs is also labeled "Kaiyuan Tongbao of the Tang Dynasty". The server determines the candidate category of this ancient coin training image as "Kaiyuan Tongbao of the Tang Dynasty" according to the ancient coin type identifier of the ancient coin training image to which these neighboring coarse-grained image features belong. For all ancient coin training images, the server will perform such an operation to determine the candidate category for each ancient coin training image. For each ancient coin sub-image of the ancient coin training image, the server traverses the fine-grained feature set. For example, the text area on an ancient coin training image is divided into an ancient coin sub-image, and the server calculates the similarity between the fine-grained image feature of this ancient coin sub-image and other fine-grained image features in the fine-grained feature set, and finds at least one neighboring fine-grained image feature. If the ancient coin training image to which this neighboring fine-grained image feature belongs is labeled "Kaiyuan Tongbao of the Tang Dynasty", the server determines the candidate category of this ancient coin sub-image as "Kaiyuan Tongbao of the Tang Dynasty". The server performs such an operation on all ancient coin sub-images of each ancient coin training image to determine their respective candidate categories. The server calculates the multi-granularity feature alignment degree according to the candidate category of the ancient coin sub-image and the candidate category of the ancient coin training image to which this ancient coin sub-image belongs. Taking the ancient coin sub-image in the text area of an ancient coin training image of "Kaiyuan Tongbao of the Tang Dynasty" as an example, if the candidate category of this ancient coin sub-image and the candidate category of the ancient coin training image to which it belongs are both "Kaiyuan Tongbao of the Tang Dynasty", it indicates that they are highly consistent in category. The server can measure the multi-granularity feature alignment degree by calculating the coincidence degree of the candidate categories. If the candidate categories are exactly the same and the coincidence degree is 100%, the multi-granularity feature alignment degree is relatively high; if there is partial coincidence, the server can determine the multi-granularity feature alignment degree according to the coincidence ratio.For example, if the category candidates of a sub-image of an ancient coin are "Kaiyuan Tongbao of the Tang Dynasty" and "a certain similar ancient coin of the Song Dynasty", and the category candidate of the training image of the ancient coin to which it belongs is "Kaiyuan Tongbao of the Tang Dynasty", then the overlap is 50%, and the server can set the multi-granularity feature alignment degree to 50%. The server performs such calculations for each sub-image of an ancient coin and the training image of the ancient coin to which it belongs, so as to obtain all the multi-granularity feature alignment degrees. These alignment degrees reflect the matching degree of the sub-image of an ancient coin and the training image of the ancient coin to which it belongs in different granularity features, providing an important basis for the optimization of the subsequent ancient coin recognition model.

[0052] In an embodiment of the present invention, calculating the multi-granularity feature alignment degree between the sub-image of an ancient coin and the training image of the ancient coin to which the sub-image of the ancient coin belongs according to the category candidate of the sub-image of the ancient coin and the category candidate of the training image of the ancient coin to which the sub-image of the ancient coin belongs can be implemented through the following examples.

[0053] Model the probability distribution of the ancient coin type identifiers in the category candidates of the sub-image of the ancient coin to determine the confidence distribution of the ancient coin type of the sub-image of the ancient coin;

[0054] Model the probability distribution of the ancient coin type identifiers in the category candidates of the training image of the ancient coin to which the sub-image of the ancient coin belongs to determine the confidence distribution of the ancient coin type of the training image of the ancient coin to which the sub-image of the ancient coin belongs;

[0055] Calculate the multi-granularity feature alignment degree between the sub-image of the ancient coin and the training image of the ancient coin to which the sub-image of the ancient coin belongs according to the confidence distribution of the ancient coin type of the sub-image of the ancient coin and the confidence distribution of the ancient coin type of the training image of the ancient coin to which the sub-image of the ancient coin belongs.

[0056] In an embodiment of the present invention, exemplarily, the server first focuses on the category candidates of the ancient coin sub-images. Suppose an ancient coin sub-image is an image of the text area on an ancient coin, and its category candidates include "Kaiyuan Tongbao of the Tang Dynasty", "Xining Yuanbao of the Song Dynasty", and "Wuzhu Coin of the Han Dynasty". The server will model the probability distribution of these ancient coin type identifications. The server will comprehensively consider the matching degree between the fine-grained image features of the ancient coin sub-image and each category candidate. For example, by analyzing the fine-grained features such as the font, style, and strokes of the text, it is found that the similarity of its text features with "Kaiyuan Tongbao of the Tang Dynasty" is 70%, the similarity with "Xining Yuanbao of the Song Dynasty" is 20%, and the similarity with "Wuzhu Coin of the Han Dynasty" is 10%. Based on these similarities, the server constructs a probability distribution and determines that the confidence distribution of the ancient coin type of this ancient coin sub-image is: the confidence of "Kaiyuan Tongbao of the Tang Dynasty" is 0.7, the confidence of "Xining Yuanbao of the Song Dynasty" is 0.2, and the confidence of "Wuzhu Coin of the Han Dynasty" is 0.1. This confidence distribution reflects the likelihood of this ancient coin sub-image belonging to each ancient coin type. Next, the server performs the same operation on the category candidates of the ancient coin training image to which this ancient coin sub-image belongs. Suppose the category candidates of this ancient coin training image are "Kaiyuan Tongbao of the Tang Dynasty" and "Qianyuan Zhongbao of the Tang Dynasty". The server analyzes the coarse-grained image features of this ancient coin training image, such as the overall shape, size, and rust color distribution, and finds that the similarity of its coarse-grained features with "Kaiyuan Tongbao of the Tang Dynasty" is 80%, and the similarity with "Qianyuan Zhongbao of the Tang Dynasty" is 20%. Based on these similarities, the server constructs a probability distribution and determines that the confidence distribution of the ancient coin type of the ancient coin training image to which this ancient coin sub-image belongs is: the confidence of "Kaiyuan Tongbao of the Tang Dynasty" is 0.8, and the confidence of "Qianyuan Zhongbao of the Tang Dynasty" is 0.2. This confidence distribution reflects the likelihood of this ancient coin training image belonging to each ancient coin type. After the server obtains the confidence distribution of the ancient coin type of the ancient coin sub-image and the confidence distribution of the ancient coin type of the ancient coin training image to which it belongs, it begins to calculate the multi-grained feature alignment degree. The server will adopt a specific algorithm to measure the similarity between the two confidence distributions. A common method is to calculate the KL divergence (Kullback-Leibler divergence) between the two distributions. The KL divergence can measure the degree of difference between two probability distributions. The smaller the difference, the more similar the two distributions are. For the ancient coin sub-image and the ancient coin training image to which it belongs in the above example, the server calculates the KL divergence between their confidence distributions of the ancient coin type. Suppose the calculated KL divergence value is small, which indicates that the two confidence distributions are relatively similar, meaning that the ancient coin sub-image and the ancient coin training image to which it belongs are relatively consistent in terms of the likelihood of the ancient coin type, and the multi-grained feature alignment degree is high. If the KL divergence value is large, it means that the two confidence distributions are quite different, and there is a large deviation in the likelihood of the ancient coin type between the ancient coin sub-image and the ancient coin training image to which it belongs, and the multi-grained feature alignment degree is low.In this way, the server calculates the multi-granularity feature alignment degrees for each ancient coin sub-image and its corresponding ancient coin training image. These alignment degree data are crucial for the subsequent optimization of the ancient coin recognition model, enabling the model to better understand the relationships between different granularity features of ancient coins and improving the accuracy of ancient coin type recognition.

[0057] In the embodiment of the present invention, the step of iteratively optimizing the parameters of the ancient coin recognition model according to the multi-granularity feature alignment degree and the ancient coin type identifier corresponding to the second ancient coin training image to obtain the target ancient coin recognition model can be implemented through the following example.

[0058] Perform ancient coin type recognition on the ancient coin training image according to the coarse-grained image features of the ancient coin training image to obtain the coarse-grained type confidence distribution corresponding to the ancient coin training image;

[0059] Perform ancient coin type recognition on the ancient coin sub-image according to the fine-grained image features corresponding to the ancient coin sub-image to obtain the fine-grained type confidence distribution corresponding to the ancient coin sub-image;

[0060] Iteratively optimize the parameters of the ancient coin recognition model according to the coarse-grained type confidence distribution, the fine-grained type confidence distribution, the multi-granularity feature alignment degree, and the ancient coin type identifier corresponding to the second ancient coin training image to obtain the target ancient coin recognition model.

[0061] In an embodiment of the present invention, exemplarily, the server first extracts the coarse-grained image features of the ancient coin training images. These features include macroscopic information such as the overall shape, approximate size, and color distribution of the ancient coins. Taking an ancient coin training image as an example, its coarse-grained image features show that the ancient coin is round with a square hole, of medium overall size, and the rust color shows a certain sense of age. The server inputs these coarse-grained image features into the ancient coin recognition model for ancient coin type recognition. The model will judge the possible ancient coin types to which the ancient coin training image belongs based on the knowledge it has learned, and give the corresponding confidence levels. Suppose after model recognition, the confidence distribution of the coarse-grained type corresponding to this ancient coin training image is: the confidence level of "Kaiyuan Tongbao of the Tang Dynasty" is 0.6, the confidence level of "Xining Yuanbao of the Song Dynasty" is 0.3, and the confidence level of "Wuzhu Coin of the Han Dynasty" is 0.1. This distribution reflects the likelihood of this ancient coin training image belonging to each ancient coin type from the perspective of coarse-grained features. For each ancient coin sub-image in the ancient coin training image, the server extracts its fine-grained image features. These features include microscopic information such as the detailed texture, local patterns, and text strokes of the ancient coin sub-image. For example, an ancient coin sub-image is the text area on the ancient coin, and its fine-grained image features show details such as the font style and stroke thickness of the text. The server inputs these fine-grained image features into the ancient coin recognition model for ancient coin type recognition. The model analyzes and judges based on these fine-grained features and gives the confidence distribution of the fine-grained type corresponding to this ancient coin sub-image. Suppose the confidence distribution of the fine-grained type corresponding to this ancient coin sub-image is: the confidence level of "Kaiyuan Tongbao of the Tang Dynasty" is 0.7, the confidence level of "Xining Yuanbao of the Song Dynasty" is 0.2, and the confidence level of "Wuzhu Coin of the Han Dynasty" is 0.1. This distribution reflects the likelihood of this ancient coin sub-image belonging to each ancient coin type from the perspective of fine-grained features. After the server obtains the coarse-grained type confidence distribution, the fine-grained type confidence distribution, the multi-granularity feature alignment degree, and the ancient coin type identifier corresponding to the second ancient coin training image, it starts to iteratively optimize the parameters of the ancient coin recognition model. First, the server will compare the coarse-grained type confidence distribution with the ancient coin type identifier corresponding to the second ancient coin training image. If the ancient coin type identifier corresponding to the second ancient coin training image is "Kaiyuan Tongbao of the Tang Dynasty", and the confidence level of "Kaiyuan Tongbao of the Tang Dynasty" in the coarse-grained type confidence distribution is 0.6, there is a certain deviation. The server will adjust the parameters related to the processing of coarse-grained features in the model so that the model can more accurately judge the ancient coin type of similar ancient coin training images with coarse-grained features in the future. Then, the server compares the fine-grained type confidence distribution with the ancient coin type identifier corresponding to the second ancient coin training image. If there is a difference between the two, the server will adjust the parameters related to the processing of fine-grained features in the model to improve the model's recognition ability for fine-grained features. The multi-granularity feature alignment degree is also an important basis for optimization. If the multi-granularity feature alignment degree is low, it means that the matching degree between the ancient coin sub-image and its corresponding ancient coin training image in different granularity features is poor.The server adjusts the parameters in the model for fusing coarse-grained and fine-grained features, enabling the model to better understand the relationship between different granularity features and improving the alignment degree of multi-granularity features. The server continuously repeats the above iterative optimization process, and each iteration adjusts the model parameters according to the new recognition results and known information. After multiple iterations, the model parameters gradually converge, and the recognition accuracy of the ancient coin type continuously improves, finally obtaining the target ancient coin recognition model, which can more accurately identify the type of ancient coins.

[0062] In the embodiment of the present invention, the iterative optimization of the parameters of the ancient coin recognition model according to the coarse-grained type confidence distribution, the fine-grained type confidence distribution, the multi-granularity feature alignment degree, and the ancient coin type identifier corresponding to the second ancient coin training image to obtain the target ancient coin recognition model can be implemented through the following examples.

[0063] For each ancient coin training image, calibrate the ancient coin type identifier of the ancient coin training image according to the fine-grained type confidence distribution of each ancient coin sub-image in the ancient coin training image and the multi-granularity feature alignment degree corresponding to each ancient coin sub-image to obtain the calibrated ancient coin type identifier of the ancient coin training image;

[0064] Integrate the calibrated ancient coin type identifiers of each ancient coin training image according to the coarse-grained type confidence distribution corresponding to each ancient coin training image to obtain the coarse-grained error parameter;

[0065] Iteratively optimize the parameters of the ancient coin recognition model according to the coarse-grained error parameter to obtain the target ancient coin recognition model.

[0066] In an embodiment of the present invention, exemplarily, the server works on each ancient coin training image. Taking an ancient coin training image labeled as "Chongning Tongbao of the Song Dynasty" as an example, this image is divided into multiple ancient coin sub-images such as a text area and an edge pattern area. The server first checks the fine-grained type confidence distribution of each ancient coin sub-image. For example, for the ancient coin sub-image in the text area, its fine-grained type confidence distribution is that the confidence of "Chongning Tongbao of the Song Dynasty" is 0.8, the confidence of "Kaiyuan Tongbao of the Tang Dynasty" is 0.1, and the confidence of "Wuzhu Coin of the Han Dynasty" is 0.1. At the same time, the multi-grained feature alignment degree corresponding to this ancient coin sub-image in the text area is 0.9, which indicates that it has a relatively high matching degree with the corresponding ancient coin training image in terms of multi-grained features. The server synthesizes the fine-grained type confidence distribution and the multi-grained feature alignment degree of all ancient coin sub-images to calibrate the ancient coin type identification of the ancient coin training image. If the fine-grained type confidence distributions of most ancient coin sub-images point to "Chongning Tongbao of the Song Dynasty" and the multi-grained feature alignment degree is relatively high, then the server confirms that the calibrated ancient coin type identification of this ancient coin training image is still "Chongning Tongbao of the Song Dynasty". However, if the fine-grained type confidence distributions of some ancient coin sub-images are significantly different from the original identification and the multi-grained feature alignment degree is also low, the server will re-evaluate and may adjust the calibrated ancient coin type identification to a type that better conforms to the overall characteristics. Then, the server integrates the calibrated ancient coin type identifications of each ancient coin training image according to the coarse-grained type confidence distribution corresponding to each ancient coin training image. Still taking the ancient coin training image of "Chongning Tongbao of the Song Dynasty" as an example, its coarse-grained type confidence distribution is that the confidence of "Chongning Tongbao of the Song Dynasty" is 0.7, the confidence of "Daguan Tongbao of the Song Dynasty" is 0.2, and the confidence of "Qianyuan Zhongbao of the Tang Dynasty" is 0.1. The server compares this coarse-grained type confidence distribution with the calibrated ancient coin type identification of "Chongning Tongbao of the Song Dynasty". The server calculates the difference between the two. For example, it measures this difference through a cross-entropy loss function. The cross-entropy loss function can reflect the error between the coarse-grained type confidence distribution predicted by the model and the actual calibrated ancient coin type identification. The server performs such calculations on all ancient coin training images and then integrates these errors to obtain a coarse-grained error parameter. This parameter reflects the overall error situation of the model in identifying the ancient coin type at the coarse-grained level. After obtaining the coarse-grained error parameter, the server starts to iteratively optimize the parameters of the ancient coin recognition model. The server adopts optimization algorithms such as the gradient descent algorithm and adjusts the parameters of the model according to the coarse-grained error parameter. The gradient descent algorithm will calculate the gradient of the error parameter with respect to the model parameters and then update the model parameters in the opposite direction of the gradient, so that the error parameter gradually decreases. In each iteration process, the server will apply the new parameters to the model, re-identify the ancient coin training images, obtain new coarse-grained type confidence distributions and fine-grained type confidence distributions, and then repeat the above steps of calibrating the ancient coin type identification and integrating to obtain the coarse-grained error parameter.As the number of iterations increases, the coarse-grained error parameter will become smaller and smaller, and the recognition accuracy of the model will also continue to improve. After multiple iterations of optimization, when the coarse-grained error parameter converges to a small value or reaches the preset number of iterations, the server considers that the model has been trained well enough. At this time, the target ancient coin recognition model is obtained, and this model can more accurately identify the types of ancient coins.

[0067] In the embodiment of the present invention, the parameters of the ancient coin recognition model are iteratively optimized according to the coarse-grained error parameter to obtain the target ancient coin recognition model, which can be implemented through the following examples.

[0068] Calculate the fine-grained category error parameter of the ancient coin sub-image according to the fine-grained type confidence distribution of the ancient coin sub-image and the ancient coin type identifier of the ancient coin training image to which the ancient coin sub-image belongs;

[0069] Iteratively optimize the parameters of the ancient coin recognition model according to the coarse-grained error parameter and the fine-grained category error parameter to obtain the target ancient coin recognition model.

[0070] In an embodiment of the present invention, exemplarily, the server takes a training image of an ancient coin labeled "Kaiyuan Tongbao of the Tang Dynasty" as an example. This image contains multiple sub-images of ancient coins such as a text region and an edge pattern region. For the sub-image of the ancient coin in the text region, its fine-grained type confidence distribution is that the confidence of "Kaiyuan Tongbao of the Tang Dynasty" is 0.7, the confidence of "Xining Yuanbao of the Song Dynasty" is 0.2, and the confidence of "Wuzhu Coin of the Han Dynasty" is 0.1. The server calculates the fine-grained category error parameter based on this fine-grained type confidence distribution and the ancient coin type identifier "Kaiyuan Tongbao of the Tang Dynasty" of the ancient coin training image to which the sub-image of the ancient coin belongs. The server uses the cross-entropy loss function to measure the difference between the two. The cross-entropy loss function takes into account the matching degree between the confidence of each ancient coin type in the fine-grained type confidence distribution and the actual identifier. In this example, the actual identifier of "Kaiyuan Tongbao of the Tang Dynasty" corresponds to a confidence of 0.7 in the fine-grained type confidence distribution, and the server calculates the error value between the two through the function. The server performs such calculations on all sub-images of the ancient coin training image to obtain the fine-grained category error parameter of each sub-image of the ancient coin. The server has obtained the coarse-grained error parameter and the fine-grained category error parameters of each sub-image of the ancient coin. The server combines these two error parameters to iteratively optimize the parameters of the ancient coin recognition model. The server uses the gradient descent algorithm, which is a commonly used optimization algorithm. The server first calculates the gradients of the coarse-grained error parameter and all fine-grained category error parameters with respect to the model parameters. The gradient represents the rate of change of the error parameter as the model parameters change. The server updates the model parameters in the opposite direction of the gradient, so that the error parameter gradually decreases. In each iteration, the server applies the new parameters to the model, re-identifies the ancient coin training image and the sub-images of the ancient coin, and obtains a new coarse-grained type confidence distribution and a new fine-grained type confidence distribution. Then, the server calculates the coarse-grained error parameter and the fine-grained category error parameter again. As the number of iterations increases, both the coarse-grained error parameter and the fine-grained category error parameter will continuously decrease. When the error parameter converges to a small value or reaches the preset number of iterations, the server considers that the model has been trained well enough. At this time, the server obtains the target ancient coin recognition model, which can comprehensively consider the coarse-grained and fine-grained features of the ancient coin and more accurately identify the type of the ancient coin.

[0071] In an embodiment of the present invention, the iterative optimization of the parameters of the ancient coin recognition model according to the coarse-grained error parameter and the fine-grained category error parameter to obtain the target ancient coin recognition model can be implemented through the following example.

[0072] Perform distribution difference calculation processing between the fine-grained type confidence distribution of the sub-image of the ancient coin and the reference distribution to obtain the feature difference index corresponding to the sub-image of the ancient coin;

[0073] Integrate the fine-grained category error parameter and the feature difference index according to the multi-granularity feature alignment degree corresponding to the ancient coin sub-image, to obtain the fine-grained error parameter of the ancient coin sub-image;

[0074] Iteratively optimize the parameters of the ancient coin recognition model according to the coarse-grained error parameter and the fine-grained error parameter corresponding to each ancient coin sub-image of the ancient coin training image, to obtain the target ancient coin recognition model.

[0075] In an embodiment of the present invention, by way of example, the server takes an ancient coin training image labeled as "Han Dynasty Wu Zhu coin" as an example. This image has multiple ancient coin sub-images such as characters and outlines. For the ancient coin sub-image in the text area, its fine-grained type confidence distribution is: confidence of "Han Dynasty Wu Zhu coin" is 0.6, confidence of "Tang Dynasty Kai Yuan Tong Bao" is 0.3, and confidence of "Song Dynasty Yuan Feng Tong Bao" is 0.1. The server pre-sets a reference distribution, which reflects the characteristic distribution that the ancient coin sub-image of "Han Dynasty Wu Zhu coin" should have in an ideal state. The server uses methods such as the Kullback-Leibler divergence to calculate and process the distribution difference between the fine-grained type confidence distribution of the ancient coin sub-image in the text area and the reference distribution. Through calculation, the server obtains the feature difference index corresponding to this ancient coin sub-image, which quantifies the difference degree between the actual feature distribution and the ideal distribution of this ancient coin sub-image. The server knows that the multi-granularity feature alignment degree corresponding to this ancient coin sub-image in the text area is 0.8, as well as the fine-grained category error parameter calculated previously. The server integrates the fine-grained category error parameter and the feature difference index according to the multi-granularity feature alignment degree. If the multi-granularity feature alignment degree is high, it indicates that the ancient coin sub-image matches well with the ancient coin training image to which it belongs in terms of multi-granularity features. At this time, relatively large weights are assigned to the fine-grained category error parameter and the feature difference index during integration; otherwise, smaller weights are assigned. The server integrates the two by means of weighted summation, etc., to obtain the fine-grained error parameter of this ancient coin sub-image. The server performs such operations on all ancient coin sub-images of this ancient coin training image to obtain the fine-grained error parameter of each ancient coin sub-image. After the server obtains the coarse-grained error parameter and the fine-grained error parameter corresponding to each ancient coin sub-image, it uses optimization algorithms such as gradient descent to iteratively optimize the parameters of the ancient coin recognition model. The server calculates the gradient of these error parameters with respect to the model parameters, and updates the model parameters in the opposite direction of the gradient, so that the error parameters continue to decrease. In each iteration, the server re-evaluates the recognition effect of the model and updates the coarse-grained error parameter and the fine-grained error parameter. After multiple iterations, when the error parameter converges to a smaller value or reaches the preset number of iterations, the server considers that the model training is completed, and obtains the target ancient coin recognition model, which can more accurately identify the ancient coin type.

[0076] In an embodiment of the present invention, the coarse-grained image features of the ancient coin training image and the fine-grained image features corresponding to each ancient coin sub-image of the ancient coin training image can be obtained by performing feature extraction processing on the ancient coin training image and each ancient coin sub-image of the ancient coin training image respectively through the ancient coin recognition model, and the implementation can be carried out through the following examples.

[0077] Obtain the visual feature set of the ancient coin training image in the visual feature domain and the inscription feature set in the semantic feature domain, and obtain the visual sub-feature set of each ancient coin sub-image of the ancient coin training image and the inscription sub-feature set in the semantic feature domain;

[0078] Perform cross-domain feature integration processing on the visual feature set and the inscription feature set of the ancient coin training image to obtain the multi-dimensional feature set corresponding to the ancient coin training image; perform cross-domain feature integration processing on the visual sub-feature set and the inscription sub-feature set of the ancient coin sub-image to obtain the multi-dimensional feature set corresponding to the ancient coin sub-image;

[0079] Through the ancient coin recognition model, perform gated recurrent unit feature interaction on the multi-dimensional feature set of the ancient coin training image to obtain the coarse-grained image features of the ancient coin training image;

[0080] Through the ancient coin recognition model, perform gated recurrent unit feature interaction on the multi-dimensional feature set of the ancient coin sub-image to obtain the fine-grained image features of the ancient coin sub-image.

[0081] In an embodiment of the present invention, exemplarily, the server first faces an ancient coin training image, which represents an unearthed Kaiyuan Tongbao of the Tang Dynasty. In the visual feature domain, the server uses image analysis technology to obtain the visual feature set of this ancient coin training image. For example, it can recognize that the overall shape of the ancient coin is round with a square hole in the middle, measure the diameter of the ancient coin, and analyze the distribution of the rust color on its surface. These visual features together constitute the visual feature set. In the semantic feature domain, the server uses technologies such as optical character recognition (OCR) to extract the inscription feature set on the ancient coin, and recognizes the four characters of "Kaiyuan Tongbao" on the front of the ancient coin, including information such as the font and stroke thickness of the characters. For each sub-image of the ancient coin divided from this ancient coin training image, the server also performs feature acquisition. Taking the sub-image of the text area on the ancient coin as an example, in the visual feature domain, the server obtains visual sub-feature sets such as the clarity of the text edge and color contrast of this sub-image; in the semantic feature domain, it obtains inscription sub-feature sets such as the specific shape and stroke trend of individual characters in this sub-image. The server performs cross-domain feature integration processing on the visual feature set and inscription feature set of the ancient coin training image. It fuses features such as the round shape with a square hole and the rust color distribution visually with the inscription information of "Kaiyuan Tongbao" semantically. The server uses methods such as feature splicing to combine visual features and inscription features together to form a multi-dimensional feature set corresponding to the ancient coin training image. This multi-dimensional feature set combines information from both the visual and semantic aspects and more comprehensively describes this ancient coin of Kaiyuan Tongbao of the Tang Dynasty. For the sub-image of the ancient coin, the server also performs cross-domain feature integration processing on its visual sub-feature set and inscription sub-feature set. Still taking the multi-dimensional feature set of the text area sub-image as an example, the server fuses visual sub-features such as the clarity of the text edge with inscription sub-features such as the stroke trend of individual characters to obtain a multi-dimensional feature set corresponding to this sub-image of the ancient coin. The server inputs the multi-dimensional feature set of the ancient coin training image into the gated recurrent unit (GRU) in the ancient coin recognition model for feature interaction. The gated recurrent unit can process sequential data, and it will analyze and interact according to the relationships between various feature elements in the multi-dimensional feature set. When processing the multi-dimensional feature set of the ancient coin training image of Kaiyuan Tongbao of the Tang Dynasty, the gated recurrent unit will consider the association between visual features and inscription features. For example, the rust color distribution may affect the recognition clarity of the inscription, and the gated recurrent unit will learn this association and perform feature interaction. After being processed by the gated recurrent unit, the server obtains the coarse-grained image features of this ancient coin training image. This coarse-grained image feature contains the macroscopic information of the whole ancient coin, such as the overall style being more in line with the casting characteristics of the Tang Dynasty, and the possibility of being preliminarily judged as Kaiyuan Tongbao of the Tang Dynasty is relatively high. The server also performs gated recurrent unit feature interaction on the multi-dimensional feature set of the sub-image of the ancient coin. Taking the multi-dimensional feature set of the text area sub-image as an example, the gated recurrent unit will deeply analyze the relationships between the detailed features of the text.It will consider the mutual influence among features such as the stroke trend and edge sharpness of the characters, and through continuous feature interaction, dig out more detailed feature information. After being processed by the gated recurrent unit, the server obtains the fine-grained image features of the ancient coin sub-image. These fine-grained image features can accurately describe the subtle differences of the characters, such as the starting angle of the character 'Kai' and the length of the second horizontal stroke of the character 'Yuan'. These detail information is of great significance for accurately judging the edition type of the ancient coin, etc. Through the above steps, the server has completed the feature extraction process of the ancient coin training image and its respective ancient coin sub-images, and obtained the coarse-grained image features and fine-grained image features, providing rich and accurate feature data for subsequent ancient coin type recognition and model training.

[0082] An embodiment of the present invention provides a computer device 100. The computer device 100 includes a processor and a non-volatile memory storing computer instructions. When the computer instructions are executed by the processor, the computer device 100 executes the foregoing ancient coin multi-type fine recognition method optimized based on the artificial intelligence architecture. As Figure 2 shown, Figure 2 is a structural block diagram of the computer device 100 provided by an embodiment of the present invention. The computer device 100 includes a memory 111, a processor 112, and a communication unit 113. To achieve data transmission or interaction, each element of the memory 111, the processor 112, and the communication unit 113 is directly or indirectly electrically connected to each other. For example, these elements can be electrically connected to each other through one or more communication buses or signal lines.

[0083] For illustrative purposes, the foregoing description has been made with reference to specific embodiments. However, the above illustrative discussion is not intended to be exhaustive or to limit the disclosure to the precise forms disclosed. Numerous modifications and variations are possible in light of the above teachings. The embodiments are selected and described in order to best illustrate the principles of the disclosure and its practical applications, so that those skilled in the art can best utilize the disclosure and use various embodiments with different modifications to suit the particular applications contemplated.

Claims

1. A multi-type fine identification method for ancient coins based on artificial intelligence architecture optimization, characterized in that: include: The original image data of the ancient coins is collected by a multi-spectral imaging device, and the original image data of the ancient coins is subjected to light equalization processing and noise filtering to generate a standardized initial image of the ancient coins; Performing enhancement processing on the initial image of the ancient coin to generate a target ancient coin image, wherein the enhancement processing includes texture enhancement processing based on an edge preservation algorithm; Calling a pre-trained target ancient coin recognition model to perform ancient coin type recognition on the target ancient coin image to obtain an ancient coin type identifier of the target ancient coin image; Based on the ancient coin type identifier, a directional search of a preset historical ancient coin database is triggered, the ancient coin related data corresponding to the ancient coin type identifier is output, and a detailed identification report of the ancient coin type is constructed based on the ancient coin related data; The target ancient coin recognition model is trained by the following methods, including: Acquire an ancient coin recognition model and a sample ancient coin image, wherein the ancient coin training image in the sample ancient coin image includes a first ancient coin training image and a second ancient coin training image, wherein the first ancient coin training image is marked with its corresponding ancient coin type identifier, and the second ancient coin training image is an unlabeled ancient coin training image; For each ancient coin training image, performing region division processing on the ancient coin training image to obtain a plurality of ancient coin sub-images of the ancient coin training image; Through the ancient coin recognition model, feature extraction is performed on the ancient coin training image and each ancient coin sub-image of the ancient coin training image to obtain coarse-grained image features of the ancient coin training image and fine-grained image features corresponding to each ancient coin sub-image; According to the ancient coin type identification of the first ancient coin training image, comparative learning is performed on the coarse-grained image features of each ancient coin training image in the sample ancient coin images to obtain the ancient coin type identification corresponding to the second ancient coin training image; A coarse-grained feature set is constructed based on the coarse-grained image features of each ancient coin training image, and a fine-grained feature set is constructed based on the fine-grained image features of the ancient coin sub-image of each ancient coin training image; For each ancient coin training image, traverse at least one neighboring coarse-grained image feature adjacent to the coarse-grained image feature of the ancient coin training image in the coarse-grained feature set, and determine a category candidate for the ancient coin training image according to the ancient coin type identifier of the ancient coin training image to which the neighboring coarse-grained image feature belongs; For each ancient coin sub-image of the ancient coin training image, traverse at least one neighboring fine-grained image feature adjacent to the fine-grained image feature of the ancient coin sub-image in the fine-grained feature set, and determine a category candidate for the ancient coin sub-image according to the ancient coin type identifier of the ancient coin training image to which the neighboring fine-grained image feature belongs; Probability distribution modeling is performed on the ancient coin type identifiers in the category candidates of the ancient coin sub-image to determine the ancient coin type confidence distribution of the ancient coin sub-image; Probability distribution modeling is performed on the ancient coin type identifiers in the category candidates of the ancient coin training image to which the ancient coin sub-image belongs, and the ancient coin type confidence distribution of the ancient coin training image to which the ancient coin sub-image belongs is determined; Calculate the multi-granularity feature alignment between the ancient coin sub-image and the ancient coin training image to which the ancient coin sub-image belongs, according to the ancient coin type confidence distribution of the ancient coin sub-image and the ancient coin type confidence distribution of the ancient coin training image to which the ancient coin sub-image belongs; According to the coarse-grained image features of the ancient coin training image, the ancient coin type recognition is performed on the ancient coin training image to obtain the coarse-grained type confidence distribution corresponding to the ancient coin training image; According to the fine-grained image features corresponding to the ancient coin sub-image, the ancient coin type is identified on the ancient coin sub-image to obtain the fine-grained type confidence distribution corresponding to the ancient coin sub-image; According to the coarse-grained type confidence distribution, the fine-grained type confidence distribution, the multi-granularity feature alignment and the ancient coin type identification corresponding to the second ancient coin training image, the parameters of the ancient coin recognition model are iteratively optimized to obtain a target ancient coin recognition model.

2. The method according to claim 1, characterized in that The method of performing comparative learning on the coarse-grained image features of each ancient coin training image in the sample ancient coin images according to the ancient coin type identification of the first ancient coin training image to obtain the ancient coin type identification corresponding to the second ancient coin training image includes: Setting a category cardinality of ancient coin type templates, and calculating the degree of fit between the coarse-grained image features of each ancient coin training image in the sample ancient coin image and the features of each ancient coin type template; For each ancient coin training image, according to the feature fit and the ancient coin type identifier of the first ancient coin training image, determine a target ancient coin type template adjacent to the feature of the ancient coin training image from each ancient coin type template, and add the ancient coin training image to the ancient coin type pool corresponding to the target ancient coin type template; For each ancient coin type pool corresponding to each ancient coin type template, select the most representative ancient coin training image from the ancient coin type pool as the evolved ancient coin type template; Repeat the step of calculating the degree of fit between the coarse-grained image features of each ancient coin training image in the sample ancient coin image and the features of each ancient coin type template until the determined ancient coin type template meets the feature fluctuation threshold range; determine the ancient coin type identifier of the second ancient coin training image in the target ancient coin image set based on the ancient coin type identifier of the first ancient coin training image in the target ancient coin image set corresponding to the ancient coin type template that meets the feature fluctuation threshold range.

3. The method according to claim 1, characterized in that The method of performing comparative learning on the coarse-grained image features of each ancient coin training image in the sample ancient coin images according to the ancient coin type identification of the first ancient coin training image to obtain the ancient coin type identification corresponding to the second ancient coin training image includes: According to the coarse-grained image features of the ancient coin training images, the sample feature fit between the ancient coin training images is determined; According to the sample feature fit, an ancient coin association hypergraph is constructed, wherein the ancient coin association hypergraph represents the association topology between each ancient coin training image; According to the ancient coin association hypergraph, type feature propagation processing is performed on the ancient coin type identification of the first ancient coin training image to obtain the ancient coin type identification corresponding to the second ancient coin training image.

4. The method according to claim 3, characterized in that The ancient coin association hypergraph includes a feature unit corresponding to each ancient coin training image and a topological connection between the feature units, wherein the topological connection represents the association topology between two connected feature units; The method of performing type feature propagation processing on the ancient coin type identifier of the first ancient coin training image according to the ancient coin association hypergraph to obtain the ancient coin type identifier corresponding to the second ancient coin training image includes: Performing type feature propagation processing on the ancient coin type identification of the first ancient coin training image through topological connections between feature units in the ancient coin association hypergraph to determine the reference ancient coin type identification of the second ancient coin training image; For each second ancient coin training image, the reference ancient coin type identification of the second ancient coin training image is predicted and iteratively optimized according to the adjacent feature units of the second ancient coin training image in the ancient coin association hypergraph until the results of the feature units in the ancient coin association hypergraph are stably determined, and the ancient coin type identification corresponding to the second ancient coin training image is obtained.

5. The method according to claim 1, characterized in that The method iteratively optimizes the parameters of the ancient coin recognition model according to the coarse-grained type confidence distribution, the fine-grained type confidence distribution, the multi-granularity feature alignment and the ancient coin type identification corresponding to the second ancient coin training image to obtain a target ancient coin recognition model, including: For each ancient coin training image, according to the fine-grained type confidence distribution of each ancient coin sub-image in the ancient coin training image and the multi-granular feature alignment corresponding to each ancient coin sub-image, the ancient coin type identification of the ancient coin training image is calibrated to obtain the calibrated ancient coin type identification of the ancient coin training image; According to the coarse-grained type confidence distribution corresponding to each ancient coin training image, the calibrated ancient coin type identification of each ancient coin training image is integrated to obtain the coarse-grained error parameter; According to the coarse-grained error parameter, the parameters of the ancient coin recognition model are iteratively optimized to obtain a target ancient coin recognition model.

6. The method according to claim 5, characterized in that The method of iteratively optimizing the parameters of the ancient coin recognition model according to the coarse-grained error parameter to obtain a target ancient coin recognition model includes: Calculate the fine-grained category error parameter of the ancient coin sub-image according to the fine-grained type confidence distribution of the ancient coin sub-image and the ancient coin type identifier of the ancient coin training image to which the ancient coin sub-image belongs; According to the coarse-grained error parameter and the fine-grained category error parameter, the parameters of the ancient coin recognition model are iteratively optimized to obtain a target ancient coin recognition model.

7. The method according to claim 6, characterized in that The iterative optimization of the parameters of the ancient coin recognition model according to the coarse-grained error parameter and the fine-grained category error parameter to obtain a target ancient coin recognition model includes: Performing distribution difference calculation processing on the fine-grained type confidence distribution of the ancient coin sub-image and the reference distribution to obtain a feature difference index corresponding to the ancient coin sub-image; According to the multi-granularity feature alignment corresponding to the ancient coin sub-image, the fine-grained category error parameter and the feature difference index are integrated to obtain the fine-grained error parameter of the ancient coin sub-image; According to the coarse-grained error parameter and the fine-grained error parameter corresponding to each ancient coin sub-image of the ancient coin training image, the parameters of the ancient coin recognition model are iteratively optimized to obtain a target ancient coin recognition model.

8. The method according to claim 1, characterized in that: The ancient coin recognition model is used to perform feature extraction processing on the ancient coin training image and each ancient coin sub-image of the ancient coin training image to obtain coarse-grained image features of the ancient coin training image and fine-grained image features corresponding to each ancient coin sub-image, including: Obtaining a visual feature set in a visual feature domain and an inscription feature set in a semantic feature domain of the ancient coin training image, and obtaining a visual sub-feature set in a visual feature domain and an inscription sub-feature set in a semantic feature domain of each ancient coin sub-image of the ancient coin training image; Performing cross-domain feature integration processing on the visual feature set and the inscription feature set of the ancient coin training image to obtain a multidimensional feature set corresponding to the ancient coin training image; performing cross-domain feature integration processing on the visual sub-feature set and the inscription sub-feature set of the ancient coin sub-image to obtain a multidimensional feature set corresponding to the ancient coin sub-image; Through the ancient coin recognition model, gated recurrent unit feature interaction is performed on the multidimensional feature set of the ancient coin training image to obtain coarse-grained image features of the ancient coin training image; Through the ancient coin recognition model, the multi-dimensional feature set of the ancient coin sub-image is subjected to gated recurrent unit feature interaction to obtain the fine-grained image features of the ancient coin sub-image.

9. A server system, characterized in that: The method comprises a server, wherein the server is used to execute the method described in any one of claims 1 to 8.

Citation Information

Patent Citations

  • Intelligent recognition device for Chinese herbal medicine

    CN118781390A

  • Intelligent evaluation method and system based on ancient coin image

    CN119313954A