CN117194721B - Method and device for generating graph data and computer equipment - Google Patents

Method and device for generating graph data and computer equipment Download PDF

Info

Publication number
CN117194721B
CN117194721B CN202311054825.7A CN202311054825A CN117194721B CN 117194721 B CN117194721 B CN 117194721B CN 202311054825 A CN202311054825 A CN 202311054825A CN 117194721 B CN117194721 B CN 117194721B
Authority
CN
China
Prior art keywords
data
matrix
sample
projection
type
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202311054825.7A
Other languages
Chinese (zh)
Other versions
CN117194721A (en
Inventor
许聪
刘海成
王佳杰
王峥
唐弢
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Heilongjiang Institute of Technology
Original Assignee
Heilongjiang Institute of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Heilongjiang Institute of Technology filed Critical Heilongjiang Institute of Technology
Priority to CN202311054825.7A priority Critical patent/CN117194721B/en
Publication of CN117194721A publication Critical patent/CN117194721A/en
Application granted granted Critical
Publication of CN117194721B publication Critical patent/CN117194721B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application provides a method for generating graph data, which comprises the following steps: when graph data containing multiple types of samples are obtained, generating a sample correlation matrix of each type of samples to obtain a total sample correlation matrix, wherein the sample correlation matrix is used for reflecting the data characteristics contained in each type of samples; according to the data characteristics, decomposing the total sample correlation matrix to obtain each type of characteristic vector matrix; screening target feature vector matrixes meeting preset screening conditions from the feature vector matrixes of each class; generating a projection space according to the target feature vector matrix, wherein the projection space is used for reflecting the data features contained in the target feature vector matrix; when projection is carried out on a projection space according to a preset projection direction to obtain projection data, map coarsening processing is carried out on the projection data to obtain target map data. In addition, the application also provides a device and computer equipment for generating the graph data.

Description

Method and device for generating graph data and computer equipment
Technical Field
The present application relates to the field of data processing technologies, and in particular, to a method, an apparatus, and a computer device for generating graph data.
Background
The Graph Neural Network (GNN) is an algorithm overview for learning graph structure data, extracting and exploring features and modes in the graph structure data, and meeting the requirements of graph learning tasks such as clustering, classifying, predicting, segmenting, generating and the like. GNNs can be used to process undirected graphs, directed graphs, labeled graphs, cyclic graphs, and the like. Existing GNNs often suffer from more serious overfitting problems due to lack of training samples. In addition, since the graph data is located in an irregular non-euclidean space, it is more general and complex than the image data or the language data located in the euclidean space, resulting in difficulty in applying the existing sample expansion method applicable to the euclidean space to the graph data.
Existing methods for expanding graph data can be divided into three categories: attribute-based methods, topology-based methods, and methods of fusion of both. However, the data acquired by the method is not based on the data itself, and uncertainty exists.
Disclosure of Invention
The application provides a method, a device and computer equipment for generating graph data, which are based on the characteristics of the data and obtain proper target graph data after data processing.
In a first aspect, an embodiment of the present application provides a method for generating graph data, where the method for generating graph data includes: when graph data containing multiple types of samples are obtained, generating a sample correlation matrix of each type of samples to obtain a total sample correlation matrix, wherein the sample correlation matrix is used for reflecting the data characteristics contained in each type of samples; according to the data characteristics, decomposing the total sample correlation matrix to obtain each type of characteristic vector matrix; screening target feature vector matrixes meeting preset screening conditions from the feature vector matrixes of each class; generating a projection space according to the target feature vector matrix, wherein the projection space is used for reflecting the data features contained in the target feature vector matrix; when projection is carried out on a projection space according to a preset projection direction to obtain projection data, map coarsening processing is carried out on the projection data to obtain target map data.
In a second aspect, an embodiment of the present application provides an apparatus for generating graph data, where the apparatus for generating graph data includes a matrix generating module, a matrix decomposing module, a matrix analyzing module, a projection space generating module, and a first data processing module, where when graph data including multiple types of samples is acquired, the matrix generating module is configured to generate a sample correlation matrix of each type of sample to obtain a total sample correlation matrix, where the sample correlation matrix is configured to reflect data features included in each type of sample; the matrix decomposition module is used for decomposing the total sample correlation matrix according to the data characteristics to obtain each type of characteristic vector matrix; the matrix analysis module is used for screening out target feature vector matrixes meeting preset screening conditions from the feature vector matrixes of each class; the projection space generation module is used for generating a projection space according to the target feature vector matrix, and the projection space is used for reflecting the data features contained in the target feature vector matrix; when projection is performed on the projection space according to a preset projection direction to obtain projection data, the first data processing module is used for performing map coarsening processing on the projection data to obtain target map data.
In a third aspect, embodiments of the present application provide a computer apparatus comprising a memory for storing a computer program, and a processor; the processor is configured to execute the computer program to implement the method of generating graph data described above.
When the graph data containing multiple types of samples is obtained, the data features contained in the samples are reflected through generating the sample correlation matrix, so that the total sample correlation matrix is decomposed according to the data features to obtain the feature vector matrix, the target feature vector matrix meeting the preset screening condition is screened out from the feature vector matrix to generate projection data to reflect the data features contained in the target feature vector matrix, and then graph coarsening processing is carried out on the projection data to obtain the target graph data. Since the generated target graph data is based on the characteristics of the data itself, the assurance of certainty of the generated graph data can be realized.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings that are required in the embodiments or the description of the prior art will be briefly described, and it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to the structures shown in these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a first flowchart of a method for generating graph data according to an embodiment of the present application.
Fig. 2 is a flowchart of a substep of step S103 provided in an embodiment of the present application.
Fig. 3 is a flowchart of a substep of step S105 provided in an embodiment of the present application.
Fig. 4 is a second flowchart of a method for generating graph data according to an embodiment of the present application.
Fig. 5 is a schematic structural diagram of an apparatus for generating graph data according to an embodiment of the present application.
Fig. 6 is a schematic diagram of an internal structure of a computer device according to an embodiment of the present application.
Fig. 7 is a schematic diagram of a method for generating graph data according to an embodiment of the present application.
The achievement of the objects, functional features and advantages of the present application will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
The present application will be described in further detail with reference to the drawings and examples, in order to make the objects, technical solutions and advantages of the present application more apparent. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the scope of the application. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
The terms "first," "second," "third," "fourth" and the like in the description and in the claims and in the above-described figures, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged under appropriate circumstances, or in other words, the described embodiments may be implemented in other sequences than those illustrated or otherwise described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, may also include other items, such as processes, methods, systems, articles, or apparatus that include a series of steps or elements, are not necessarily limited to only those steps or elements explicitly listed, but may include other steps or elements not explicitly listed or inherent to such processes, methods, articles, or apparatus.
It should be noted that the description of "first", "second", etc. in this disclosure is for descriptive purposes only and is not to be construed as indicating or implying a relative importance or implying an indication of the number of technical features being indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include one or more such feature. In addition, the technical solutions of the embodiments may be combined with each other, but it is necessary to base that the technical solutions can be realized by those skilled in the art, and when the technical solutions are contradictory or cannot be realized, the combination of the technical solutions should be considered to be absent and not within the scope of protection claimed in the present application.
Referring to fig. 7, a schematic diagram of a method for generating graph data according to an embodiment of the present application is shown.
As shown in fig. 7, the present application provides a method of generating graph data. The data characteristics contained in each type of sample are reflected by acquiring graph data containing samples of different types from a graph neural network and generating a sample correlation matrix of each type of sample. After the data features are acquired, carrying out feature decomposition on the sample correlation matrix based on the data features to obtain a plurality of feature vector matrixes. After a plurality of eigenvector matrixes are obtained, the objective eigenvector matrixes with different categories are screened out from the eigenvector matrixes to generate a projection space to reflect the data characteristics contained in the objective eigenvector matrixes. After the projection space is obtained, the projection space is subjected to orthogonal projection to obtain projection data, and the projection data is subjected to map roughening processing to generate target map data. The method of generating the map data will be specifically described below to explain how the target map data is obtained.
Referring to fig. 4, a second flowchart of a method for generating graph data according to an embodiment of the present application is shown. The method of generating map data includes step S100.
Step S100, obtaining initial graph data containing different categories, so as to divide the initial graph data into graph data containing multiple types of samples according to the categories.
At step S100, different classes of initial map data may be obtained from the map neural network. In this embodiment, the graph data includes various categories, such as a mesh graph for planning a route, a tree data structure for a spatial index or a geographic information system, a hyperspherical set or a curved set for machine learning or data mining, and the like. The graph data is divided into graph data containing multiple classes of samples according to different classes of the graph data.
In some possible embodiments, the initial map data may also be manifold data. Wherein manifold data is distributed with a plurality of different types of data points over its corresponding different manifolds. Manifold data is divided into graph data for multiple classes of samples according to different classes of data points. In other possible embodiments, the initial graph data may also be graph data and manifold data. When the initial graph data is divided, the categories of the data in the initial graph data are divided, and then the data divided according to the categories of the data are divided to obtain graph data of multiple types of samples. The above examples are only partial examples of the data in the graph neural network and are not limiting of the data in the graph neural network and the corresponding graph data. And will not be described in detail herein.
It will be appreciated that both the graph data and the manifold data are non-European spatial data. Therefore, the conventional data expansion method of the European space is not applicable to the graph data and the manifold data. After the graph data of the multiple types of samples are obtained, in order to effectively expand the data of the graph neural network, the data processing of the graph data by the method for generating the graph data is needed, so that more effective data are obtained on the basis of the graph data.
Please refer to fig. 1, which is a first flowchart of a method for generating graph data according to an embodiment of the present application. The method of generating map data further comprises steps S101-S105.
In step S101, when the graph data including multiple types of samples is obtained, a sample correlation matrix of each type of sample is generated to obtain a total sample correlation matrix.
In step S101, the sample correlation matrix is used to reflect the data features contained in each type of sample. In this embodiment, the sample correlation matrix can be represented by equation 1.
In formula 1, R i represents a class i sample correlation matrix, where i=1, 2,3, … c, M i represents the number of data points of class i sample map data, and x T represent transposed matrices of data points and data points, respectively, to reflect data characteristics of each data point in each class of sample map data.
In this embodiment, after generating the sample correlation matrix of each type of sample to obtain the total sample correlation matrix, a weight is given to the sample correlation matrix of each type of sample. The weight is used for reflecting the sample graph data characteristics contained in the sample correlation matrix of each type of sample. The sample map data features are derived from the data features contained in each type of sample, i.e., the sample map data features are a collection of data features contained in each type of sample. After the weight corresponding to the sample correlation matrix of each type of sample is acquired, the total sample correlation matrix can be represented by equation 2.
In equation 2, R T represents a total sample correlation matrix, and ω i represents a weight corresponding to the i-th type sample correlation matrix.
Step S102, according to the data characteristics, decomposing the total sample correlation matrix to obtain each type of characteristic vector matrix.
In step S102, the process of decomposing the total sample correlation matrix can be represented by equation 3.
In formula 3, P T andDenote an orthogonal matrix and a transpose matrix of the orthogonal matrix, respectively, and a T denotes a diagonal matrix. The diagonal matrix has a plurality of eigenvalues to reflect the data characteristics of each type of eigenvector matrix.
Step S103, screening out target feature vector matrixes meeting preset screening conditions from each type of feature vector matrixes.
In step S103, each type of feature vector matrix includes feature values. The target eigenvector matrix is at least two different types of eigenvector matrix. The preset screening condition is to screen out feature vector matrixes with feature values larger than a preset feature value threshold value from each type of feature vector matrixes. In this embodiment, the preset feature value threshold may be adjusted correspondingly according to the graph data of each type of sample.
Please refer to fig. 2, which is a flowchart illustrating a sub-step of step S103 according to an embodiment of the present application. Screening the target feature vector matrix meeting the preset screening condition from each type of feature vector matrix comprises the steps S1031-S1032.
Step S1031, judging whether target characteristic values meeting preset screening conditions exist or not from each type of characteristic values.
Step S1032, when judging that the target feature value meeting the preset screening condition exists, confirming the feature vector matrix corresponding to the target feature value as a target feature vector matrix.
In this embodiment, for equation 3, a feature vector matrix is set to be represented by equation 4.
In equation 4, Z represents a feature vector matrix.
At this time, the process of substituting equation 4 into equation 3, that is, decomposing the total sample correlation matrix, can be represented by equation 5.
Z TRT z=i (5)
It will be appreciated that the target feature vector matrix is assumed to be of two types, i.e., the i-th type target feature vector matrix ω iZTRi Z and the j-th type target feature vector matrix ω jZTRj Z. As can be seen from equation 5, when the i-th target feature vector matrix is used as the filtering reference, the obtained i-th target feature vector matrix ω iZTRi Z and the corresponding form Σ j≠iωjZTRj Z of the j-th target feature vector matrix have the same feature vector and the sum of the corresponding feature values is 1.
Step S104, generating a projection space according to the target feature vector matrix.
In step S104, the projection space is used to reflect the data features contained in the target feature vector matrix. In this embodiment, the projection space is a projection matrix.
In step S105, when the projection space is projected according to the preset projection direction to obtain projection data, the projection data is subjected to map roughening processing to obtain target map data.
In step S105, a preset projection direction is preset according to the target feature vector matrix. In the present embodiment, the target feature vector matrix is set to two types, i.e., an i-th type feature vector U i and a j-th type feature vector U j. It will be appreciated that for U i, substituting equation 5 may result in equation 6 while the weight of U i is obtained.
In the case of the method of 6,Representing the transposed matrix of U i.
Meanwhile, for U j, when the weight of U j is obtained, the corresponding form of the target feature vector matrix is substituted to obtain the formula 7.
In the case of the method of step 7,Representing the transposed matrix of U j.
After equation 6 and equation 7 are obtained, equation 8 is obtained by combining equation 6 and equation 7.
In this embodiment, the following formulas 9 and 10 can be obtained according to formula 8.
And then, the formula 11 is obtained according to the formulas 9 and 10.
From equation 11, different types of feature vectors can generate projection spaces that are orthogonal to each other. Therefore, when certain specified sample graph data exists in the graph neural network, the method for generating the graph data can be used for acquiring projection space data orthogonal to the sample graph data, and then the projection space data is applied to the graph neural network after data processing. At this time, the preset projection direction is also preset according to the feature vector.
Please refer to fig. 3, which is a flowchart illustrating a sub-step of step S105 according to an embodiment of the present application. When projection is performed on the projection space according to the preset projection direction to obtain projection data, performing map roughening processing on the projection data to obtain target map data includes steps S1051-S1052.
In step S1051, projection space is projected in each preset projection direction to obtain sub-projection data of each preset projection direction, so as to obtain projection data.
In step S1052, when the projection data is obtained, the sub-projection data of each preset projection direction is subjected to a map roughening process to obtain target map data.
In step S1052, the projection matrix can be represented by expression 12.
In equation 12, P u denotes a projection matrix.
Similarly, according to equation 12, a projection matrix corresponding to U j can be obtained.
In this embodiment, after the projection data is acquired, appropriate data processing, such as map roughening, may be performed on the projection data to optimize the projection data to reduce the amount of computation of the data in the map neural network. The effect of reducing the calculated amount can be achieved by deleting part of data points, so that the application of the data in the graph neural network is facilitated. Specifically, map roughening of projection data can be represented by equation 13.
In equation 13, P' u represents the target map data, m represents the number of data points in the sample map data, t represents the number of map-coarsened target map data points,Representing edge weights in the projection data.
Fig. 5 is a schematic structural diagram of an apparatus for generating graph data according to an embodiment of the application.
As shown in fig. 5, the apparatus 11 for generating map data includes a matrix generation module 110, a matrix decomposition module 111, a matrix analysis module 112, a projection space generation module 113, a first data processing module 114, a data acquisition module 115, and a second data processing module 116.
When the graph data containing multiple types of samples is acquired, the matrix generation module 110 is configured to generate a sample correlation matrix of each type of sample to obtain a total sample correlation matrix, where the sample correlation matrix is used to reflect the data features contained in each type of sample.
The matrix decomposition module 111 is configured to decompose the total sample correlation matrix according to the data features to obtain a feature vector matrix of each type.
The matrix analysis module 112 is configured to screen out a target feature vector matrix that meets a preset screening condition from each type of feature vector matrix.
The projection space generating module 113 is configured to generate a projection space according to the target feature vector matrix, where the projection space is configured to reflect the data features included in the target feature vector matrix.
When the projection space is projected according to the preset projection direction to obtain projection data, the first data processing module 114 is configured to perform a map roughening process on the projection data to obtain target map data.
The data acquisition module 115 is configured to acquire initial graph data including different classes, so as to divide the initial graph data into graph data including multiple classes of samples according to the classes.
The second data processing module 116 is configured to assign weights to the sample correlation matrices of each type of samples after generating the sample correlation matrices of each type of samples to obtain a total sample correlation matrix, where the weights are used to reflect the data features of the sample map included in the sample correlation matrices of each type of samples, and the data features of the sample map are obtained according to the data features included in each type of samples.
Fig. 6 is a schematic diagram of an internal structure of a computer device to which a method for generating graph data is applied according to an embodiment of the present application.
As shown in fig. 6, the computer device 100 includes a memory 901 and a processor 902. Wherein the processor 902 is adapted to execute computer program instructions in the memory 901 for implementing a method of generating graph data.
The memory 901 includes at least one type of readable storage medium including flash memory, a hard disk, a multimedia card, a card type memory (e.g., SD or DX memory, etc.), magnetic memory, magnetic disk, optical disk, etc. Memory 901 may be an internal storage unit of a computer device in some embodiments, such as a hard disk of a computer device. The memory 901 may also be a storage device of an external computer device in other embodiments, for example, a plug-in hard disk configured in the computer device, a smart memory card (SMART MEDIA CARD, SMC), a Secure Digital (SD) card, a flash memory card (FLASH CARD), and so on. Further, the memory 901 may also include both internal storage units and external storage devices of the computer device. The memory 901 may be used not only for storing application software installed in a computer device and various types of data, such as code of a method of generating map data, but also for temporarily storing data that has been output or is to be output.
Further, the computer device 100 also includes a bus 903. Bus 903 may be a peripheral component interconnect standard (PERIPHERAL COMPONENT INTERCONNECT, PCI) bus, or an extended industry standard architecture (extended industry standard architecture, EISA) bus, among others. The bus may be classified as an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown in fig. 6, but not only one bus or one type of bus.
Further, the computer device 100 can also include a display component 904. The display component 904 may be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, an OLED (Organic Light-Emitting Diode) touch device, or the like. The display component 904 may also be referred to as a display device or display unit, as appropriate, for displaying information processed in the computer device 100 and for displaying a visual user interface.
Further, the computer device 100 can also include a communication component 905. The communication component 905 may optionally include a wired communication component and/or a wireless communication component (e.g., WI-FI communication component, bluetooth communication component, etc.), typically used to establish a communication connection between the computer device 100 and other computer devices.
Fig. 6 illustrates only a computer device 100 having partial components and methods of generating diagram data, and it will be understood by those skilled in the art that the structure illustrated in fig. 6 is not limiting of the computer device 100 and may include fewer or more components than illustrated, or may combine certain components, or a different arrangement of components.
In the above embodiment, when the graph data including multiple types of samples is obtained, the data features included in the samples are reflected by generating the sample correlation matrix, so as to decompose the total sample correlation matrix according to the data features to obtain the feature vector matrix, and the target feature vector matrix meeting the preset screening condition is screened out from the feature vector matrix to generate the projection data to reflect the data features included in the target feature vector matrix, and then the graph roughening processing is performed on the projection data according to the preset projection direction to obtain the target graph data. Since the generated target graph data is based on the characteristics of the data itself, the assurance of certainty of the generated graph data can be realized.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present application without departing from the spirit or scope of the application. Thus, if and when such modifications and variations of the present application fall within the scope of the claims and the equivalents thereof, the present application is intended to encompass such modifications and variations.
The above list of preferred embodiments of the present application is, of course, not intended to limit the scope of the application, and equivalent variations according to the claims of the present application are therefore included in the scope of the present application.

Claims (10)

1. A method of generating graph data comprising a mesh graph for planning a route, a tree data structure for a spatial index or geographical information system, a hyperspherical or curved set for machine learning or data mining, manifold data; the method for generating the graph data is characterized by comprising the following steps:
when graph data containing multiple types of samples are obtained, generating a sample correlation matrix of each type of samples to obtain a total sample correlation matrix, wherein the sample correlation matrix is used for reflecting data features contained in each type of samples, the sample correlation matrix is represented by a formula 1, and the formula 1 is as follows:
In formula 1, R i represents an i-th type sample correlation matrix, where i=1, 2,3, … c, M i represents the number of data points of the i-th type sample map data, and x T represent transposed matrices of data points and data points, respectively, to reflect data characteristics of each data point in each type of sample map data;
the total sample correlation matrix is represented by formula 2, where formula 2 is:
In formula 2, R T represents a total sample correlation matrix, ω i represents a weight corresponding to the i-th type sample correlation matrix;
according to the data characteristics, decomposing the total sample correlation matrix to obtain each type of characteristic vector matrix, wherein the total sample correlation matrix is expressed by a formula 3, and the formula 3 is as follows:
In formula 3, P T and Respectively representing an orthogonal matrix and a transposed matrix of the orthogonal matrix, wherein, a T represents a diagonal matrix, and the diagonal matrix has a plurality of eigenvalues so as to reflect the data characteristics of each type of eigenvector matrix;
screening target feature vector matrixes meeting preset screening conditions from the feature vector matrixes of each class;
Generating a projection space according to the target feature vector matrix, wherein the projection space is used for reflecting the data features contained in the target feature vector matrix; and
When projection is carried out on a projection space according to a preset projection direction to obtain projection data, map coarsening processing is carried out on the projection data to obtain target map data.
2. The method of generating map data of claim 1, wherein said method of generating map data further comprises: initial graph data containing different categories are acquired, and the initial graph data are divided into the graph data containing multiple types of samples according to the categories.
3. The method for generating map data as recited in claim 1, wherein after generating the sample correlation matrix for each type of sample to obtain the total sample correlation matrix, the method for generating map data further comprises: and assigning weights to the sample correlation matrix of each type of sample, wherein the weights are used for reflecting sample graph data features contained in the sample correlation matrix of each type of sample, and the sample graph data features are obtained according to the data features contained in each type of sample.
4. The method for generating graph data according to claim 1, wherein each type of eigenvector matrix includes eigenvalues, the target eigenvector matrix is at least two different types of eigenvector matrix, and the preset screening condition is to screen out eigenvector matrices with eigenvalues greater than a preset eigenvalue threshold from each type of eigenvector matrix.
5. The method for generating graph data as claimed in claim 4, wherein selecting the target feature vector matrix satisfying a predetermined selection condition from the feature vector matrices of each class comprises: judging whether target characteristic values which accord with the preset screening conditions exist or not from each type of characteristic values; and when judging that the target characteristic value meeting the preset screening condition exists, confirming a characteristic vector matrix corresponding to the target characteristic value as the target characteristic vector matrix.
6. The method of generating map data as claimed in claim 1, wherein the preset projection direction is preset according to the target feature vector matrix; when projection is performed on a projection space according to a preset projection direction to obtain projection data, performing map coarsening processing on the projection data to obtain target map data, including: projecting the projection space in each preset projection direction to obtain sub-projection data of each preset projection direction so as to obtain the projection data; and when the projection data are obtained, performing map coarsening processing on the sub-projection data of each preset projection direction to obtain the target map data.
7. An apparatus for generating graph data comprising a mesh graph for planning a route, a tree data structure for a spatial index or geographic information system, a hyperspherical or curved set for machine learning or data mining, manifold data; the device for generating the graph data is characterized by comprising the following steps:
the matrix generation module is used for generating a sample correlation matrix of each type of sample to obtain a total sample correlation matrix when the graph data containing the multiple types of samples is obtained, the sample correlation matrix is used for reflecting the data characteristics contained in each type of sample, the sample correlation matrix is represented by a formula 1, and the formula 1 is:
In formula 1, R i represents an i-th type sample correlation matrix, where i=1, 2,3, … c, M i represents the number of data points of the i-th type sample map data, and x T represent transposed matrices of data points and data points, respectively, to reflect data characteristics of each data point in each type of sample map data;
the total sample correlation matrix is represented by formula 2, where formula 2 is:
In formula 2, R T represents a total sample correlation matrix, ω i represents a weight corresponding to the i-th type sample correlation matrix;
The matrix decomposition module is configured to decompose the total sample correlation matrix according to the data features to obtain feature vector matrices of each class, where the total sample correlation matrix is decomposed and represented by formula 3, and formula 3 is:
In formula 3, P T and Respectively representing an orthogonal matrix and a transposed matrix of the orthogonal matrix, wherein, a T represents a diagonal matrix, and the diagonal matrix has a plurality of eigenvalues so as to reflect the data characteristics of each type of eigenvector matrix;
The matrix analysis module is used for screening out target feature vector matrixes meeting preset screening conditions from the feature vector matrixes of each class;
the projection space generation module is used for generating a projection space according to the target feature vector matrix, and the projection space is used for reflecting the data features contained in the target feature vector matrix; and
And the first data processing module is used for carrying out map coarsening processing on the projection data to obtain target map data when the projection space is projected according to a preset projection direction to obtain the projection data.
8. The apparatus for generating map data of claim 7, wherein said apparatus for generating map data further comprises:
the data acquisition module is used for acquiring initial graph data containing different categories so as to divide the initial graph data into the graph data containing multiple types of samples according to the categories.
9. The apparatus for generating map data of claim 8, wherein said apparatus for generating map data further comprises: the second data processing module is used for assigning a weight to the sample correlation matrix of each type of sample after the sample correlation matrix of each type of sample is generated to obtain a total sample correlation matrix, wherein the weight is used for reflecting the sample graph data characteristics contained in the sample correlation matrix of each type of sample, and the sample graph data characteristics are obtained according to the data characteristics contained in each type of sample.
10. A computer device, the computer device comprising: a memory for storing a computer program; and a processor for executing the computer program to implement the method of generating graph data as claimed in any one of claims 1-6.
CN202311054825.7A 2023-08-22 2023-08-22 Method and device for generating graph data and computer equipment Active CN117194721B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311054825.7A CN117194721B (en) 2023-08-22 2023-08-22 Method and device for generating graph data and computer equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311054825.7A CN117194721B (en) 2023-08-22 2023-08-22 Method and device for generating graph data and computer equipment

Publications (2)

Publication Number Publication Date
CN117194721A CN117194721A (en) 2023-12-08
CN117194721B true CN117194721B (en) 2024-07-02

Family

ID=88995247

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311054825.7A Active CN117194721B (en) 2023-08-22 2023-08-22 Method and device for generating graph data and computer equipment

Country Status (1)

Country Link
CN (1) CN117194721B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102831600A (en) * 2012-07-24 2012-12-19 长安大学 Image layer cutting method based on weighting cut combination
CN115310594A (en) * 2022-08-10 2022-11-08 东北大学 Method for improving expandability of network embedding algorithm

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5410355B2 (en) * 2010-04-13 2014-02-05 富士フイルム株式会社 Matrix generation apparatus, method, program, and information processing apparatus
CN114723037A (en) * 2022-02-25 2022-07-08 上海理工大学 Heterogeneous graph neural network computing method for aggregating high-order neighbor nodes
CN115879507A (en) * 2022-09-23 2023-03-31 同济大学 Large-scale graph generation method based on deep confrontation learning

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102831600A (en) * 2012-07-24 2012-12-19 长安大学 Image layer cutting method based on weighting cut combination
CN115310594A (en) * 2022-08-10 2022-11-08 东北大学 Method for improving expandability of network embedding algorithm

Also Published As

Publication number Publication date
CN117194721A (en) 2023-12-08

Similar Documents

Publication Publication Date Title
CN109784293B (en) Multi-class target object detection method and device, electronic equipment and storage medium
CN111950329A (en) Target detection and model training method and device, computer equipment and storage medium
US8121967B2 (en) Structural data classification
CN112101437A (en) Fine-grained classification model processing method based on image detection and related equipment thereof
CN109495513B (en) Unsupervised encrypted malicious traffic detection method, unsupervised encrypted malicious traffic detection device, unsupervised encrypted malicious traffic detection equipment and unsupervised encrypted malicious traffic detection medium
CN108764369B (en) Figure identification method and device based on data fusion and computer storage medium
EP4343616A1 (en) Image classification method, model training method, device, storage medium, and computer program
CN111626346A (en) Data classification method, device, storage medium and device
CN112631751A (en) Task scheduling method and device, computer equipment and storage medium
CN112818314A (en) Equipment detection method, device, equipment and storage medium
CN110716857B (en) Test case management method, device, computer equipment and storage medium
CN110069997B (en) Scene classification method and device and electronic equipment
CN108830302B (en) Image classification method, training method, classification prediction method and related device
CN110909768A (en) Method and device for acquiring marked data
CN117194721B (en) Method and device for generating graph data and computer equipment
CN112381458A (en) Project evaluation method, project evaluation device, equipment and storage medium
CN116707859A (en) Feature rule extraction method and device, and network intrusion detection method and device
CN113746780A (en) Abnormal host detection method, device, medium and equipment based on host image
CN108764206B (en) Target image identification method and system and computer equipment
CN111049988A (en) Intimacy prediction method, system, equipment and storage medium for mobile equipment
CN113672807B (en) Recommendation method, recommendation device, recommendation medium, recommendation device and computing equipment
CN116433899A (en) Image segmentation method, method and device for training image segmentation model
CN116152751A (en) Image processing method, device, system and storage medium
CN111242322B (en) Detection method and device for rear door sample and electronic equipment
CN112905792A (en) Text clustering method, device and equipment based on non-text scene and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant