# US 2023/0267703 A1 · Hierarchical constraint (hc)-based method and system for classifying fine-grained graptolite images

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2023/0267703 A1
- Document ID: US20230267703A1
- Status: Published application
- Kind: A1
- Application number: 18/147,019
- Filed: 2022-12-28
- Published: 2023-08-24
- Earliest claimed: 2022-02-22
- Assignees: Nanjing Institute of Geology and Palaeontology, CAS; Tianjin University
- Applicants: Nanjing Institute of Geology and Palaeontology, CAS; Tianjin University
- Inventors: Honghe XU; Yaohua PAN; Zhibin NIU
- Web page: https://patentgrep.com/patent/US20230267703A1

## CPC

- G06V 10/761: {Proximity, similarity or dissimilarity measures}
- G06V 10/24: Aligning, centring, orientation detection or correction of the image
- G06V 10/25: Determination of region of interest [ROI] or a volume of interest [VOI]
- G06V 10/26: Segmentation of patterns in the image field; Cutting or merging of image elements to establish the pattern region, e.g. clustering-based techniques; Detection of occlusion
- G06V 10/7635: {based on graphs, e.g. graph cuts or spectral clustering}
- G06V 10/764: using classification, e.g. of video objects
- G06V 10/7715: {Feature extraction, e.g. by transforming the feature space, e.g. multi-dimensional scaling [MDS]; Mappings, e.g. subspace methods}
- G06V 10/774: Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
- G06V 10/82: using neural networks
- G06V: IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING

## Abstract

The present disclosure relates to a hierarchical constraint (HC) based method and system for classifying fine-grained graptolite images. The method includes: constructing a graptolite fossil dataset; extracting features in graptolite images; calculating the similarity between graptolite images, and performing weighting according to a genetic relationship among species to obtain a weighted HC loss function (HC-Loss) of all graptolite images; calculating cross-entropy loss; taking a weighted sum of HC-Loss and CE-Loss as a total loss function in a training stage; and performing model training. The system of the present disclosure includes a processor and a memory.

## Claims

### Claim 1

A hierarchical constraint (HC)-based method for classifying fine-grained graptolite images, comprising:
step 1, collecting an original graptolite image;
step 2, annotating fine granularity of a graptolite specimen in the original graptolite image;
step 3, according to an annotation result of fine granularity, conducting cropping at a pixel level, cropping by an annotation box, and data enhancement on the original graptolite image to obtain a graptolite image representing the graptolite specimen, and constructing a graptolite dataset;
step 4, extracting features in the graptolite image by a Convolutional Neural Network (CNN) model, which specifically comprises: extracting a feature map from an input graptolite image by convolution, activation and pooling operation of the CNN model to obtain a feature vector; and projecting, by an embedding layer, the feature vector into a feature with a dimension being a number of categories in the dataset, wherein a feature vector obtained after projection represents a prediction vector of the CNN to the input graptolite image, each value in the prediction vector represents a prediction score of a corresponding category of the graptolite image, and the higher the prediction score, the greater the probability that a graptolite in the graptolite image belongs to this category;
step 5, calculating a similarity between graptolite images, and performing weighting according to a genetic relationship among species to obtain a weighted HC loss function (HC-Loss) of all graptolite images, which specifically comprises:
dividing graptolite images in a same batch randomly into multiple groups of graptolite image pairs, each group of graptolite image pairs comprising two graptolite images; for two graptolite images in each graptolite image pair, quantifying a similarity weight according to the genetic relationship of categories graptolites in the two graptolite images belong, wherein for the graptolite images belonging to two categories, the closer the genetic relationship is, the greater the degree of similarity is, and the greater the similarity weight value is; on the contrary, the farther the genetic relationship is, the smaller the similarity weight value is; and
in each training batch, calculating the weighted HC-Loss of all graptolite images by the following process: calculating a Euclidean distance between prediction vectors of two graptolite images in each graptolite image pair; according to the similarity weight value for each graptolite image pair, making weighted summation on the similarity of all groups of graptolite image pairs, and dividing a sum by the number of groups to obtain weighted HC-Loss of all graptolite images;
step 6, calculating cross-entropy loss (CE-Loss) used to represent a difference between predicted probability distribution of the CNN model and real label distribution of images;
step 7, taking a weighted sum of HC-Loss and CE-Loss as a total loss function of the CNN model in a training stage; and
step 8, training the CNN model.

### Claim 2 (depends on 1)

The method for classifying fine-grained graptolite images according to claim 1, wherein in step 1, the collected original graptolite image comprises high-resolution images covering various families, genera and species.

### Claim 3 (depends on 1)

The method for classifying fine-grained graptolite images according to claim 1, wherein step 4 is executed by the following process: extracting, from an input graptolite image x, a feature map fx with respect to x by the convolution, activation and pooling operation of the CNN model, and setting a size of fx to C×H×W, wherein C, H and W denote a channel, a height and a width of the feature map, respectively; and expanding the feature map fx to a feature vector with one dimension being C×H×W, and projecting the feature vector into a feature vector with a dimension of N through an embedding layer, wherein N denotes a number of categories in a dataset, the embedding layer is implemented through a fully connected layer, and the final image feature vector represents a prediction vector of the CNN model to the inputted image x.

### Claim 4 (depends on 3)

The method for classifying fine-grained graptolite images according to claim 3, wherein the Euclidean distance between prediction vectors of two graptolite images in each graptolite image pair is expressed as follows:
d
⁡
(
φ
⁡
(
x
m
)
,
φ
⁡
(
x
n
)
)
=
∑
i
=
1
N
(
φ
⁡
(
x
m
)
i
,
φ
⁡
(
x
n
)
i
)
2
wherein (xm,xn) denotes a graptolite image pair, φ(x) denotes a prediction vector regarding a graptolite image x extracted from the CNN model, φ(x)i denotes an ith element in the prediction vector, and d(·) denotes a Euclidean distance.

### Claim 5 (depends on 1)

The method for classifying fine-grained graptolite images according to claim 1, wherein in step 5, said setting a similarity weight value for a graptolite image pair according to the categories and genetic relationship specifically comprises:
if two graptolite images of a graptolite image pair belong to the same category and a lowest common parent category is at a species level, setting the similarity weight value to 0;
if two graptolite images of a graptolite image pair belong to different species of the same genus and a lowest common parent category is at a genus level, setting the similarity weight value to 1.0;
if two graptolite images of a graptolite image pair belong to different genera of the same family and a lowest common parent category is at a family level, setting the similarity weight value to be greater than 0.5 and less than 1.0; and
if two graptolite images of a graptolite image pair belong to different families and a lowest common parent category is at an order level, setting the similarity weight value to be greater than 0.1 and less than 0.3.

### Claim 6 (depends on 5)

The method for classifying fine-grained graptolite images according to claim 5, wherein in step 5, if two graptolite images of a graptolite image pair belong to different genera of the same family and the lowest common parent category is at a family level, the similarity weight value is set to 0.6.

### Claim 7 (depends on 5)

The method for classifying fine-grained graptolite images according to claim 5, wherein in step 5, if two graptolite images of a graptolite image pair belong to different families and the lowest common parent category is at an order level, the similarity weight value is set to 0.2.

### Claim 8 (depends on 1)

An HC-based system for classifying fine-grained graptolite images, comprising a processor and a memory, wherein the memory has a program instruction stored therein, and the processor calls the program instruction stored in the memory to enable the system to perform the steps of the method according to claim 1.

### Claim 9 (depends on 8)

The HC-based system for classifying fine-grained graptolite images according to claim 8, wherein in step 1, the collected original graptolite image comprises high-resolution images covering various families, genera and species.

### Claim 10 (depends on 8)

The HC-based system for classifying fine-grained graptolite images according to claim 8, wherein step 4 is executed by the following process: extracting, from an input graptolite image x, a feature map fx with respect to x by the convolution, activation and pooling operation of the CNN model, and setting a size of fx to C×H×W, wherein C, H and W denote a channel, a height and a width of the feature map, respectively; and expanding the feature map fx to a feature vector with one dimension being C×H×W, and projecting the feature vector into a feature vector with a dimension of N through an embedding layer, wherein N denotes a number of categories in a dataset, the embedding layer is implemented through a fully connected layer, and the final image feature vector represents a prediction vector of the CNN model to the inputted image x.

### Claim 11 (depends on 10)

The HC-based system for classifying fine-grained graptolite images according to claim 10, wherein the Euclidean distance between prediction vectors of two graptolite images in each graptolite image pair is expressed as follows:
d
⁡
(
φ
⁡
(
x
m
)
,
φ
⁡
(
x
n
)
)
=
∑
i
=
1
N
(
φ
⁡
(
x
m
)
i
,
φ
⁡
(
x
n
)
i
)
2
wherein (xm,xn) denotes a graptolite image pair, φ(x) denotes a prediction vector regarding a graptolite image x extracted from the CNN model, φ(x)i denotes an ith element in the prediction vector, and d(·) denotes a Euclidean distance.

### Claim 12 (depends on 8)

The HC-based system for classifying fine-grained graptolite images according to claim 8, wherein in step 5, said setting a similarity weight value for a graptolite image pair according to the categories and genetic relationship specifically comprises:
if two graptolite images of a graptolite image pair belong to the same category and a lowest common parent category is at a species level, setting the similarity weight value to 0;
if two graptolite images of a graptolite image pair belong to different species of the same genus and a lowest common parent category is at a genus level, setting the similarity weight value to 1.0;
if two graptolite images of a graptolite image pair belong to different genera of the same family and a lowest common parent category is at a family level, setting the similarity weight value to be greater than 0.5 and less than 1.0; and
if two graptolite images of a graptolite image pair belong to different families and a lowest common parent category is at an order level, setting the similarity weight value to be greater than 0.1 and less than 0.3.

### Claim 13 (depends on 12)

The HC-based system for classifying fine-grained graptolite images according to claim 12, wherein in step 5, if two graptolite images of a graptolite image pair belong to different genera of the same family and the lowest common parent category is at a family level, the similarity weight value is set to 0.6.

### Claim 14 (depends on 12)

The HC-based system for classifying fine-grained graptolite images according to claim 12, wherein in step 5, if two graptolite images of a graptolite image pair belong to different families and the lowest common parent category is at an order level, the similarity weight value is set to 0.2.

### Claim 15 (depends on 1)

A computer-readable storage medium, wherein the computer-readable storage medium stores a computer program that comprises program instructions, and the program instructions, when executed by a processor, enables the processor to perform the steps of the method according to claim 1.

### Claim 16 (depends on 15)

The computer-readable storage medium according to claim 15, wherein in step 1, the collected original graptolite image comprises high-resolution images covering various families, genera and species.

### Claim 17 (depends on 15)

The computer-readable storage medium according to claim 15, wherein step 4 is executed by the following process: extracting, from an input graptolite image x, a feature map fx with respect to x by the convolution, activation and pooling operation of the CNN model, and setting a size of fx to C×H×W, wherein C, H and W denote a channel, a height and a width of the feature map, respectively; and expanding the feature map fx to a feature vector with one dimension being C×H×W, and projecting the feature vector into a feature vector with a dimension of N through an embedding layer, wherein N denotes a number of categories in a dataset, the embedding layer is implemented through a fully connected layer, and the final image feature vector represents a prediction vector of the CNN model to the inputted image x.

### Claim 18 (depends on 17)

The computer-readable storage medium according to claim 17, wherein the Euclidean distance between prediction vectors of two graptolite images in each graptolite image pair is expressed as follows:
d
⁡
(
φ
⁡
(
x
m
)
,
φ
⁡
(
x
n
)
)
=
∑
i
=
1
N
(
φ
⁡
(
x
m
)
i
,
φ
⁡
(
x
n
)
i
)
2
wherein (xm,xn) denotes a graptolite image pair, φ(x) denotes a prediction vector regarding a graptolite image x extracted from the CNN model, φ(x)i denotes an ith element in the prediction vector, and d(·) denotes a Euclidean distance.

### Claim 19 (depends on 15)

The computer-readable storage medium according to claim 15, wherein in step 5, said setting a similarity weight value for a graptolite image pair according to the categories and genetic relationship specifically comprises:
if two graptolite images of a graptolite image pair belong to the same category and a lowest common parent category is at a species level, setting the similarity weight value to 0;
if two graptolite images of a graptolite image pair belong to different species of the same genus and a lowest common parent category is at a genus level, setting the similarity weight value to 1.0;
if two graptolite images of a graptolite image pair belong to different genera of the same family and a lowest common parent category is at a family level, setting the similarity weight value to be greater than 0.5 and less than 1.0; and
if two graptolite images of a graptolite image pair belong to different families and a lowest common parent category is at an order level, setting the similarity weight value to be greater than 0.1 and less than 0.3.

### Claim 20 (depends on 19)

The computer-readable storage medium according to claim 19, wherein in step 5, if two graptolite images of a graptolite image pair belong to different genera of the same family and the lowest common parent category is at a family level, the similarity weight value is set to 0.6.
