Apparatus and especially computer-based method for determining the similarity between datasets
A computer-implemented method using neural networks with pre-configured architectures enhances the efficiency and accuracy of similarity determination between datasets by training models and minimizing feature distance, addressing inefficiencies in existing methods.
Patent Information
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- ROBERT BOSCH GMBH
- Filing Date
- 2022-03-15
- Publication Date
- 2026-07-22
AI Technical Summary
Existing methods for determining the similarity between datasets, particularly images, are inefficient and lack a standardized approach to capture similarities effectively.
A computer-implemented method using artificial neural networks with pre-configured architectures to determine similarity by training models on datasets, extracting features, and applying a mapping to minimize distance between feature representations, thereby enhancing similarity capture.
Improves the efficiency and accuracy of identifying similar datasets by selecting optimal training datasets and pre-training models, ensuring robust similarity determination across various data sets.
Smart Images

Figure 0007893428000003 
Figure 0007893428000004 
Figure 0007893428000001
Abstract
Description
Technical Field
[0004] ,
[0003] ,
[0001] The present invention relates to an apparatus and in particular a computer-implemented method for determining the similarity between datasets, particularly between images.
Summary of the Invention
Means for Solving the Problems
[0002] Disclosure of the Invention A method for determining the similarity of datasets, particularly a computer-implemented method, is configured as follows. That is, a first dataset including a plurality of first embeddings is preset, a second dataset including a plurality of second embeddings is preset, a first model is trained based on the first dataset, a second model is trained based on the second dataset, a set of first features of the first model is determined based on a second dataset including one feature of the first model for each second embedding, a set of second features of the second model is determined based on a second dataset including one feature of the second model for each second embedding, a mapping that maps the set of first features to the set of second features as well as possible is determined, and the similarity is determined depending on the distance of the mapping from a predetermined criterion. This method is applicable using a model that provides a feature representation without depending on an individual model architecture. By doing so, the capture of the similarity of datasets is significantly improved.
[0003] Preferably, the first embedding in the plurality of first embeddings represents one digital image out of the plurality of first digital images, and the second embedding in the plurality of second embeddings represents one digital image out of the plurality of second digital images. Thereby, two datasets including digital images whose contents are particularly similar to each other can be found.
[0004] Preferably, in a plurality of first embeddings, each first embedding represents a portion of the first corpus, and in a plurality of second embeddings, each second embedding represents a portion of the second corpus. This makes it possible to find two corpora whose content is particularly similar to each other.
[0005] One possibility is that the first model includes an artificial neural network with an input layer and an output layer, and for each second embedding in the input layer of the first model, the output of a layer located between the input layer and the output layer, in particular the layer immediately preceding the output layer, is determined, and this output represents the characteristics of one feature assigned to the second embedding, and / or the second model includes an artificial neural network with an input layer and an output layer, and for each second embedding in the input layer of the second model, the output of a layer located between the input layer and the output layer, in particular the layer immediately preceding the output layer, is determined, and this output represents the characteristics of one feature assigned to the second embedding, and so on.
[0006] Preferably, artificial neural networks having the same architecture, particularly the classifier architecture, are configured such that the layers having pre-configured or feature-representing outputs have the same dimensions.
[0007] One possible approach is that if the similarity of the first dataset to the second dataset is greater than the similarity of the third dataset to the second dataset, a training dataset containing the first dataset or a portion thereof is determined for training. If the similarity is not greater, the training dataset is determined based on the third dataset. During training, the second model is pre-trained using the data in the training dataset, and then trained using the data in the second dataset. This ensures that the second model is pre-trained based on data belonging to datasets that have a particularly high similarity to the second dataset.
[0008] Preferably, the dataset having the shortest distance to the second dataset is selected, and in particular, the best possible dataset is selected for pre-training.
[0009] Preferably, the mapping is determined based on the distance from each first feature to each second feature, and in particular, using the Procrustes method to minimize this distance.
[0010] Preferably, similarity is determined based on the norm of the mapping distance from the reference.
[0011] In one embodiment, a second model is trained or is trained for the classification of embeddings, in which case at least one embedding of a digital image or a portion of a corpus is captured or received and classified by the second model.
[0012] The device for determining the similarity of datasets is configured to perform the method described above.
[0013] A computer program containing computer-readable instructions is also provided, and the above-described method is carried out by the computer through the execution of these computer-readable instructions.
[0014] Further advantageous embodiments will be revealed from the following description and drawings. [Brief explanation of the drawing]
[0015] [Figure 1] This diagram schematically shows a part of the device used to determine the similarity of datasets. [Figure 2] This figure shows the steps in a method for determining the similarity of datasets. [Modes for carrying out the invention]
[0016] Figure 1 schematically shows a portion of the device 100 for determining the similarity of datasets. This will be explained below based on the first dataset 101 and the second dataset 102. In this embodiment, these datasets are digital representations, in particular, numerical or alphanumeric representations of images, image metadata, or portions of a corpus. In this embodiment, the second dataset 102 is the target dataset, and a model for solving a certain task is trained on this target dataset. In this embodiment, the first dataset 101 is a candidate for a training dataset, and if this training dataset is found to be suitable for the model, the model is pre-trained on it.
[0017] The device 100 is configured to determine the similarity of a dataset to a second dataset 102. This will be explained, for example, with respect to the similarity between the first dataset 101 and the second dataset 102.
[0018] The apparatus 100 includes multiple models. Figure 1 schematically shows a first model and a second model. The apparatus 100 is configured to use the first and second models to determine the similarity of the first dataset 101 to a second dataset 102. The apparatus 100 may include a third model, which is used to determine the similarity of the third dataset to the second dataset 102. The apparatus 100 may also include a number of additional models for other datasets.
[0019] In this embodiment, the first model is a first artificial neural network 103, which includes an input layer 104, an output layer 105, and a layer 106 positioned between the input layer 104 and the output layer 105.
[0020] In the case of this embodiment, the second model is the second artificial neural network 107, which includes an input layer 108, an output layer 109, and a layer 110 disposed between the input layer 108 and the output layer 109.
[0021] These artificial neural networks can be used as classifiers. In the case of this embodiment, these artificial neural networks have the same architecture. The architecture does not necessarily have to be the same.
[0022] The device 100 includes a computing device 111. The computing device 111 is configured to train a model using individual data sets. The computing device 111 is configured to train the first model using, for example, the embedding 112 belonging to the first data set 101. The computing device 111 is configured to train the second model using, for example, the embedding 113 belonging to the second data set 102.
[0023] The computing device 111 is configured to extract the feature 114 from the layer 106. The computing device 111 is configured to extract the feature 115 from the layer 110. In the case of this embodiment, the layers 106 and 110 having outputs representing the characteristics of the features 114 and 115 have the same dimension. The dimension does not necessarily have to be the same.
[0024] The computing device 111 is configured to select one data set having a higher similarity to the second data set 102 from among a plurality of data sets than one other data set or all other data sets of those plurality of data sets. In the case of this embodiment, the computing device 111 is configured to implement the method described below.
[0025] The computing device 111 is configured to determine the selected data set 116, for example, depending on the features 114 and 115 extracted from the layers 106 and 110.
[0026] During training, for example, the computing device 111 is configured to first train a second model using the selected dataset 116 and then train it using the second dataset 102.
[0027] In one embodiment, assume that the second model is trained using the second dataset 102 for a certain task. For the second dataset 102, in this embodiment, there is only a very small amount of training data. In contrast, for the first dataset 101 and other datasets among the multiple datasets, in this embodiment, there is more training data.
[0028] According to the method described below, it is determined which of the multiple datasets is closest to the second dataset 102 and suitable for pre-training the second model. The second model is pre-trained using the dataset thus determined and then trained by the second dataset 102. By doing so, a performance improvement is achieved compared to the performance expected when training the second model using only the second dataset 102.
[0029] This will be described by taking examples of the first dataset 101, the second dataset 102, and the third dataset. This method is correspondingly applicable to multiple datasets.
[0030] Instead of using one of the aforementioned datasets, it is also possible to use only randomly selected parts of those datasets.
[0031] This method can be applied to various datasets. The first embedding 112 can, for example, represent one digital image from a plurality of first digital images. The second embedding 113 can, for example, represent one digital image from a plurality of second digital images. These embeddings can numerically represent, for example, the individual red, green, and blue components of an image, pixel by pixel.
[0032] The first embedding 112 can numerically represent each portion of the first corpus, for example, a single word, a part of a word, or a part of a sentence. The second embedding 113 can numerically represent each portion of the second corpus, for example, a single word, a part of a word, or a part of a sentence.
[0033] According to this method, in step 202, a first dataset 101 containing multiple first embeddings 112 is pre-configured.
[0034] According to this method, in step 204, a second dataset 102 containing multiple second embeddings 113 is pre-configured.
[0035] In step 206, the first artificial neural network 103 is trained based on the first dataset 101.
[0036] In step 208, a second artificial neural network 107 is trained based on a second dataset 102.
[0037] These artificial neural networks are trained for classification in this embodiment. In this embodiment, they are trained in a supervised manner. In this embodiment, the training data includes labels that assign one of several classes to each individual embedding, and each artificial neural network can classify the embeddings into those classes. Digital images in the training data can be classified, for example, according to the objects or subjects they depict. Corpora can be classified, for example, according to the names they contain.
[0038] These steps can be carried out sequentially or substantially in parallel with each other in terms of time.
[0039] Subsequently, in step 210, a first set of features 114 of the first artificial neural network 103 is determined based on the second dataset 102. In this embodiment, for each embedding 113 in the second dataset 102, one feature 114 of the first artificial neural network 103 is determined and added to the first set of features 114. The feature 114 is the output of layer 106, to which the first artificial neural network 103 maps the embedding 113 in the input layer 104.
[0040] In step 212, a second set of features 115 of the second artificial neural network 107 is determined based on the second dataset 102. In this embodiment, for each second embedding 113 in the second dataset 102, one feature 115 of the second artificial neural network 107 is determined and added to the set of second features 115. This step 212 can be performed sequentially or substantially in parallel with each other in time. The feature 115 is the output of layer 110, to which the second artificial neural network 107 maps the embedding 113 in the input layer 108.
[0041] Next, in step 214, a mapping MP is determined that maps the first set of features 114 to the second set of features 115 as best as possible.
[0042] In this embodiment, the first feature 114 belonging to the first set of features 114 is a vector F1(v) relating to each embedding v. In this embodiment, the second feature 115 belonging to the second set of features 115 is a vector F2(v) relating to each embedding v. In this embodiment, the embeddings are also vectors. In one embodiment, the mapping MP is defined depending on a matrix M having the dimensions of the features. MP:F2(v)≈M F1(v)
[0043] In this embodiment, the mapping MP is determined such that feature F1 is remarkably similar to feature F2 after mapping. This mapping is determined using the Procrustes method, which minimizes a matrix M containing the point-to-point distances of the vectors by shifting, scaling, and rotating the features.
number
[0044] The mapping MP can also be calculated by other methods.
[0045] Next, in step 216, the similarity is determined based on the distance of the mapping MP from a predetermined criterion.
[0046] In this embodiment, the mapping is performed using a matrix norm and compared to the identity matrix I as a reference. The distance between models is, for example,
number
[0047] Steps 202 to 216 can be performed to compare several other datasets with the second dataset 102. In this embodiment, these steps are performed for at least a third dataset.
[0048] Next, in step 218, it is checked whether the similarity of the first dataset 101 to the second dataset 102 is greater than the similarity of the third dataset to the second dataset 102. If the similarity of the first dataset to the second dataset 102 is greater, step 220 is performed. Otherwise, step 222 is performed.
[0049] In step 220, the training dataset, which includes the first dataset 101 or a portion thereof, is determined. Then, step 224 is performed.
[0050] In step 222, a training dataset containing the third dataset or a portion thereof is determined. Then, step 224 is performed.
[0051] In step 224, during training, the second artificial neural network 107 is pre-trained using the data from the training dataset, and then trained using the data from the second dataset 102.
[0052] In this embodiment, step 226 is then carried out.
[0053] In step 226, at least one embedding is captured or set up and classified by the second artificial neural network 107 trained as described above.
[0054] Embedding can be either a digital image embedding or a portion of a corpus embedding, depending on what it was trained for.
Claims
1. In computer-based methods, particularly computer-implemented methods, for determining the similarity of datasets, A first dataset (101) containing multiple first embeddings (112) is pre-configured (202), A second dataset (102) containing multiple second embeddings (113) is pre-configured (204), A first model (103) is trained on the first dataset (101) (206), A second model (107) is trained on the second dataset (102) (208), The set of first features (114) of the first model (103) is determined based on the second dataset (102) which contains one feature of the first model (103) for each second embedding (113) (210), The set of second features (115) of the second model (107) is determined (212) based on the second dataset (102) which includes one feature of the second model (107) for each second embedding (113), A mapping is determined (214) that maps the set of the first feature (114) to the set of the second feature (115) as best as possible. The degree of similarity is determined depending on the distance of the mapping from a predetermined standard (216). A method characterized by the following:
2. In the plurality of first embeddings (112), each first embedding (112) represents one digital image from among the plurality of first digital images, and in the plurality of second embeddings (113), each second embedding (113) represents one digital image from among the plurality of second digital images. The method according to claim 1.
3. In the plurality of first embeddings (112), each first embedding (112) represents a portion of the first corpus, and in the plurality of second embeddings (113), each second embedding (113) represents a portion of the second corpus. The method according to claim 1.
4. The first model (103) includes an artificial neural network comprising an input layer (104) and an output layer (105). For each second embedding (113) in the input layer (104) of the first model (103), the output of the layer (106) located between the input layer (104) and the output layer (105), in particular the layer immediately preceding the output layer (105), is determined, and the output represents the characteristics of one feature (114) assigned to the second embedding (113), and / or The second model (107) includes an artificial neural network comprising an input layer (108) and an output layer (109). For each second embedding (113) in the input layer (108) of the second model (107), the output of a layer (110) located between the input layer (108) and the output layer (109), in particular the layer immediately preceding the output layer (109), is determined, and the output represents the characteristics of one feature (115) assigned to the second embedding (113). The method according to any one of claims 1 to 3.
5. The artificial neural network having the same architecture, particularly the classifier architecture, has layers that are pre-configured or have outputs representing the characteristics of the features, and these layers have the same dimensions. The method according to claim 4.
6. If the similarity of the first dataset (101) to the second dataset (102) is greater than the similarity of the third dataset to the second dataset (102), then a training dataset including the first dataset (101) or a portion of the first dataset (101) is determined (218). If it is not large, the training dataset is determined depending on the third dataset (222), During training, the second model (107) is pre-trained using the data from the training dataset, and then trained using the data from the second dataset (102) (224). The method according to any one of claims 1 to 5.
7. The mapping is determined depending on the distance from each first feature (114) to each second feature (115), and in particular using the Procrustes method to minimize the distance (214). The method according to any one of claims 1 to 6.
8. The similarity is determined depending on the norm of the distance of the mapping from the aforementioned criteria (216). The method according to any one of claims 1 to 7.
9. The second model (107) is trained or has been trained for the classification of embeddings, and at least one embedding of one digital image or a portion of one corpus is captured or received and the embedding is classified by the second model (107) (226). The method according to any one of claims 1 to 8.
10. In a device (100) for determining the similarity of digital datasets, An apparatus (100) characterized by being configured to carry out the method described in any one of claims 1 to 9.
11. A computer program that includes computer-readable instructions, A computer program characterized in that, by executing the computer-readable instruction, the method described in any one of claims 1 to 9 is performed by a computer.