Simulation software model recommendation method, system and medium based on knowledge graph

Through a knowledge graph-based method, the target scene graph and graph database are constructed, and the simulation software model in the industrial field is recommended using the graph matching algorithm, which solves the problem of limited model recommendation effect in the existing technology, and realizes multi-dimensional comprehensive computing and intelligent construction Simulation scenarios improve designers' work efficiency.

CN119026199BActive Publication Date: 2025-02-18HANGZHOU CORE CONTROL INTELLIGENT TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411513931.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-29
Publication Date
2025-02-18
Estimated Expiration
2044-10-29

AI Technical Summary

Technical Problem

The existing simulation software model recommendation method has limited effect in the industrial field, and it is impossible to effectively recommend model relationships between multi-dimensional (positional relationship, rotational relationship, machine connection relationship).

Method used

Using a knowledge graph-based method, by constructing a target scene graph and a pre-constructed graph database, a pre-selected scene model matching the target scene is selected using the graph matching algorithm, and the recommended weights of each model are calculated, and the model with the highest weight is finally recommended.

Benefits of technology

Multi-dimensional comprehensive computing is realized, simulation scenarios are intelligently built to improve designers' work efficiency, and the recommended model is more in line with actual needs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119026199B_ABST
    Figure CN119026199B_ABST
Patent Text Reader

Abstract

The present application provides a simulation software model recommendation method, system and medium based on a knowledge graph, the method comprising: constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph comprises: at least one model node, each model node corresponds to an object in the target scene; screening out one or more pre-selected scene models matching the target scene graph from a pre-constructed graph database based on a graph matching algorithm; calculating the recommendation weight of each pre-selected scene model, and determining a recommended model according to the recommendation weight of each pre-selected scene model; acquiring model data based on the recommended model, transmitting the model data to the simulation software, and obtaining a recommendation result; performing multi-dimensional comprehensive calculation based on a database of a large number of simulation solution scenarios, recommending the model with the highest weight, calculating its spatial attributes, intelligently building a simulation scene, and improving the work efficiency of designers.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of simulation software technology, and more specifically, to a method, system and medium for recommending simulation software models based on a knowledge graph. Background Art

[0002] Recently, artificial intelligence technology has shown good application capabilities and great potential in many fields, and more and more artificial intelligence researchers have joined various fields of social production. In recent years, with the vigorous promotion of industrial automation, more and more artificial intelligence researchers have gradually participated in the design and application of artificial intelligence in the industrial field.

[0003] In 3D simulation software (such as Siemens' pdps, plan, and domestic core factory software), designers need to know the model and position, rotation, scaling, and connection of machines to build scenes. There are currently few machine learning solutions for simulation software in the field of digital manufacturing on the market, especially for the model recommendation function. The existing intelligent recommendation method is based on the frequency of model use. It has few dimensions and cannot automatically calculate the position of the model, so the recommendation effect is limited. Similar algorithms that other industries can refer to are game 3D scene AI modeling, such as the open source projects ProcTHOR and GAPartNet. Most of the existing model recommendation methods are diffusion algorithms based on neural networks, which have poor logical relationship effects between models and are not applicable to industrial modeling. Effective technical solutions are urgently needed for the above problems. Summary of the invention

[0004] The purpose of the embodiments of the present application is to provide a method, system and medium for recommending simulation software models based on a knowledge graph, which performs multi-dimensional (position relationship, rotation relationship, machine connection relationship) comprehensive calculations through a database of a large number of simulation solution scenarios, recommends the model with the highest weight, calculates its spatial properties, intelligently builds simulation scenes, and improves the work efficiency of designers.

[0005] The present application also provides a method for recommending a simulation software model based on a knowledge graph, including:

[0006] Constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph comprises: at least one model node, each model node corresponding to an object in the target scene;

[0007] Filtering one or more pre-selected scene models matching the target scene graph from a pre-built graph database based on a graph matching algorithm;

[0008] Calculate the recommendation weights of each pre-selected scenario model, and determine the recommended model according to the recommendation weights of each pre-selected scenario model;

[0009] The model data is obtained based on the recommended model, and the model data is transmitted to the simulation software to obtain the recommended results.

[0010] Optionally, in the simulation software model recommendation method based on knowledge graph described in the embodiment of the present application, the graph database construction step includes:

[0011] Obtain several scene engineering files, obtain multiple 3D scenes based on the scene engineering files, and analyze the duplication between different 3D scenes;

[0012] Merge 3D scenes whose repetition is greater than or equal to the set repetition threshold;

[0013] Classifying 3D scenes whose repetition is less than a set repetition threshold to obtain multiple types of 3D scenes, wherein the 3D scenes include multiple machine model objects, model objects, and text objects;

[0014] Acquire attribute information of machine model objects, model objects and text objects in each 3D scene, and establish relative spatial relationship information between two pre-selected scene models based on the attribute information, wherein the spatial relationship information includes machine connection information or relative transformation matrix;

[0015] Construct a graph database based on relative spatial relationship information.

[0016] Optionally, in the simulation software model recommendation method based on knowledge graph described in the embodiment of the present application, one or more pre-selected scene models matching the target scene graph are screened out from a pre-built graph database based on a graph matching algorithm, specifically including:

[0017] Get the input scene, and obtain all the objects in the input scene based on the knowledge graph analysis. Take each object as a model node, and the relationship between model nodes as edges.

[0018] Obtain the type of the model node, establish a target graph based on the type of the model node, perform matching retrieval in the database based on the target graph, and find a matching subgraph;

[0019] Calculate the node matching degree and edge matching degree of the matched subgraph and model node, perform weighted calculation based on the node matching degree and edge matching degree, and find the subgraph with the largest weight based on the sorting weight;

[0020] A pre-selected scene model matching the scene is obtained based on the sub-graph with the largest weight.

[0021] Optionally, in the simulation software model recommendation method based on knowledge graph described in the embodiment of the present application, the matching subgraph is found to satisfy the following conditions:

[0022] The number of nodes in the matching graph is not greater than the number of nodes in the target graph;

[0023] All matching nodes belong to the same scene.

[0024] Optionally, in the simulation software model recommendation method based on knowledge graph described in the embodiment of the present application, relative spatial relationship information between two pre-selected scene models is established based on attribute information, specifically including:

[0025] Establish a relative spatial relationship between any two pre-selected scene models of each scene;

[0026] Convert the positions and Euler angles of two pre-selected scene models into corresponding first translation matrix and second translation matrix;

[0027] Multiply the inverse matrix of the first translation matrix by the second translation matrix to obtain a relative transformation matrix;

[0028] A relative spatial relationship between two pre-selected scene models is established based on the relative change matrix to obtain spatial relationship information.

[0029] Optionally, in the simulation software model recommendation method based on knowledge graph described in the embodiment of the present application, the recommendation weights of multiple pre-selected scenario models are calculated based on the recommendation algorithm, and the pre-selected scenario models are analyzed based on the recommendation weights to obtain the recommendation model, which specifically includes:

[0030] Obtain the best matching subgraph, and calculate the recommendation weights for all nodes in the set area outside the best matching subgraph;

[0031] Recommend multiple models with the highest weights based on the recommendation weights;

[0032] According to the spatial relationship and connection relationship, the recommended model is automatically generated to the correct connection position and the correct model is connected.

[0033] In a second aspect, an embodiment of the present application provides a simulation software model recommendation system based on a knowledge graph, the system comprising: a memory and a processor, the memory comprising a program of a simulation software model recommendation method based on a knowledge graph, and the program of the simulation software model recommendation method based on the knowledge graph is executed by the processor to implement the following steps:

[0034] Constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph comprises: at least one model node, each model node corresponding to an object in the target scene;

[0035] Filtering one or more pre-selected scene models matching the target scene graph from a pre-built graph database based on a graph matching algorithm;

[0036] Calculate the recommendation weights of each pre-selected scenario model, and determine the recommended model according to the recommendation weights of each pre-selected scenario model;

[0037] The model data is obtained based on the recommended model, and the model data is transmitted to the simulation software to obtain the recommended results.

[0038] Optionally, in the simulation software model recommendation system based on knowledge graph described in the embodiment of the present application, the graph database construction step includes:

[0039] Obtain several scene engineering files, obtain multiple 3D scenes based on the scene engineering files, and analyze the duplication between different 3D scenes;

[0040] Merge 3D scenes whose repetition is greater than or equal to the set repetition threshold;

[0041] Classifying 3D scenes whose repetition is less than a set repetition threshold to obtain multiple types of 3D scenes, wherein the 3D scenes include multiple machine model objects, model objects, and text objects;

[0042] Acquire attribute information of machine model objects, model objects and text objects in each 3D scene, and establish relative spatial relationship information between two pre-selected scene models based on the attribute information, wherein the spatial relationship information includes machine connection information or relative transformation matrix;

[0043] Construct a graph database based on relative spatial relationship information.

[0044] Optionally, in the simulation software model recommendation system based on the knowledge graph described in the embodiment of the present application, one or more pre-selected scene models matching the target scene graph are screened out from a pre-built graph database based on a graph matching algorithm, specifically including:

[0045] Get the input scene, and obtain all the objects in the input scene based on the knowledge graph analysis. Take each object as a model node, and the relationship between model nodes as edges.

[0046] Obtain the type of the model node, establish a target graph based on the type of the model node, perform matching retrieval in the database based on the target graph, and find a matching subgraph;

[0047] Calculate the node matching degree and edge matching degree of the matched subgraph and model node, perform weighted calculation based on the node matching degree and edge matching degree, and find the subgraph with the largest weight based on the sorting weight;

[0048] A pre-selected scene model matching the scene is obtained based on the sub-graph with the largest weight.

[0049] In the third aspect, an embodiment of the present application also provides a computer-readable storage medium, which includes a simulation software model recommendation method program based on a knowledge graph. When the simulation software model recommendation method program based on the knowledge graph is executed by a processor, the steps of the simulation software model recommendation method based on the knowledge graph as described in any one of the above items are implemented.

[0050] As can be seen from the above, the embodiment of the present application provides a simulation software model recommendation method, system and medium based on knowledge graph, which obtains scene engineering files, pre-processes the scene engineering files, and constructs a graph database; based on the graph matching algorithm, screens out one or more pre-selected scene models that match the target scene graph from the pre-constructed graph database; calculates the recommendation weights of multiple pre-selected scene models based on the recommendation algorithm, analyzes the pre-selected scene models based on the recommendation weights, and obtains the recommended model; obtains model data based on the recommended model, transmits the model data to the simulation software, and obtains the recommended result; based on a database of a large number of simulation solution scenarios, performs multi-dimensional (position relationship, rotation relationship, machine connection relationship) comprehensive calculations, recommends the model with the highest weight, calculates its spatial properties, intelligently builds simulation scenes, and improves the work efficiency of designers. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments of the present application will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0052] Figure 1 A flowchart of a simulation software model recommendation method based on a knowledge graph provided in an embodiment of the present application;

[0053] Figure 2 A flowchart of a graph database construction method for a simulation software model recommendation method based on a knowledge graph provided in an embodiment of the present application;

[0054] Figure 3 A flow chart of a method for obtaining a pre-selected scenario model for a simulation software model recommendation method based on a knowledge graph provided in an embodiment of the present application. DETAILED DESCRIPTION

[0055] The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments. The components of the embodiments of the present application described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the application claimed for protection, but merely represents the selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without making creative work belong to the scope of protection of the present application.

[0056] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.

[0057] Please refer to Figure 1 , Figure 1 This is a flowchart of a simulation software model recommendation method based on a knowledge graph in some embodiments of the present application. The simulation software model recommendation method based on a knowledge graph is used in a terminal device, and the simulation software model recommendation method based on a knowledge graph includes the following steps:

[0058] S101, constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph includes: at least one model node, each model node corresponding to an object in the target scene;

[0059] Filtering one or more pre-selected scene models matching the target scene graph from a pre-built graph database based on a graph matching algorithm;

[0060] Calculate the recommendation weights of each pre-selected scenario model, and determine the recommended model according to the recommendation weights of each pre-selected scenario model;

[0061] The model data is obtained based on the recommended model, and the model data is transmitted to the simulation software to obtain the recommended results.

[0062] It should be noted that the graph database neo4j is used to store scene data, calculate and store the relative transformation matrix between every two pre-selected scene model nodes, optimize the efficiency of the subsequent matching algorithm, convert the user input scene into a graph data structure, perform matching calculations in the database, find the subgraph with the highest matching degree, and finally recommend models based on the nodes near the subgraph. The spatial position of the final generated model is calculated based on the spatial relationship between the node and the matching graph, and the optimal model is recommended for connection based on the spatial position.

[0063] Please refer to Figure 2 , Figure 2 This is a flow chart of a graph database construction method for a simulation software model recommendation method based on a knowledge graph in some embodiments of the present application. According to an embodiment of the present invention, the graph database construction step includes:

[0064] S201, obtaining a plurality of scene engineering files, obtaining a plurality of 3D scenes based on the scene engineering files, and analyzing the repetition between different 3D scenes;

[0065] S202, merging 3D scenes whose repetition is greater than or equal to a set repetition threshold;

[0066] S203, classifying the 3D scenes whose repetition is less than a set repetition threshold to obtain multiple types of 3D scenes, where the 3D scenes include multiple robot model objects, model objects, and text objects;

[0067] S204, acquiring attribute information of machine model objects, model objects and text objects in each 3D scene, and establishing relative spatial relationship information between two pre-selected scene models based on the attribute information, wherein the spatial relationship information includes machine connection information or a relative transformation matrix;

[0068] S205: construct a graph database based on the relative spatial relationship information.

[0069] It should be noted that the graph database contains multiple industrial solutions, each of which is one or more 3D scenes, and each scene contains multiple machine model objects, model objects, and text objects. Each object has attributes: spatial coordinates, Euler angles, child Guid, parent Guid, Guid, model, name, program, scale parameters, io parameters, ID, scene Guid, resource type ResourceGuid, binding object Guid, bound object Guid. Each model in the scene is a data node, and the label is ObjectEntity. The robot model is RobotEntity, and the text object is TextEntity. Each scene has two attributes, id and name. The scene and other nodes have a belonging relationship. The other three nodes are subordinate to a scene node. The relationship between the models is the edge data of the node, mainly the child-parent relationship, as well as the binding and bound relationship.

[0070] Specifically, Guid is the unique identifier of the model in the scene. There are multiple models of the same type in a scene, but their Guids are different. The parent Guid is the unique identifier of the parent object; the child Guid is the unique identifier of the child object; the resource type ResourceGuid is the unique identifier of the model type; the ResourceGuid of models of the same type is the same, otherwise they are different.

[0071] Please refer to Figure 3 , Figure 3 This is a flow chart of a method for obtaining a pre-selected scene model of a simulation software model recommendation method based on a knowledge graph in some embodiments of the present application. According to an embodiment of the present invention, one or more pre-selected scene models matching the target scene graph are screened out from a pre-built graph database based on a graph matching algorithm, specifically including:

[0072] S301, obtaining an input scene, obtaining all objects in the input scene based on knowledge graph analysis, taking each object as a model node, and the relationship between model nodes as edges;

[0073] S302, obtaining the type of the model node, establishing a target graph based on the type of the model node, performing a matching search in the database according to the target graph, and finding a matching subgraph;

[0074] S303, calculating the node matching degree and edge matching degree of the matched subgraph and the model node, performing weighted calculation based on the node matching degree and the edge matching degree, and finding the subgraph with the largest weight based on the sorting weight;

[0075] S304, obtaining a pre-selected scene model matching the scene based on the sub-graph with the largest weight.

[0076] It should be noted that the knowledge graph technology is used to more accurately obtain the spatial connection logical relationship of the model. The user selects part of the scene and lets the software make recommendations. All objects in the scene entered by the user are used as nodes. Assuming there are m model nodes, of which the Z type model has TC_z (the model type is determined by ResourceGuid, and models with the same attribute belong to the same type). The relationship between the models is used as an edge to form a graph data G1={N1,V1,M1}; N1_i represents the i-th node, V1_ij represents the edge from node i to node j, M1_ij represents the transformation matrix of N1_j relative to N1_i, and M1_i represents the transformation matrix of N1_i, where M1_ij=M1_i^-1*M1_j; according to the target graph, matching retrieval is performed in the database to find the matching subgraph G2={N2,V2,M2}, and the node matching degree and edge matching degree are weightedly calculated, and finally the optimal matching subgraph is found by sorting the weights. N1 and N2 both represent sets of nodes; V1 and V2 both represent sets of edges; M1 and M2 both represent sets of matrices.

[0077] According to an embodiment of the present invention, the matching subgraph is found to satisfy the following conditions:

[0078] The number of nodes in the matching graph is not greater than the number of nodes in the target graph;

[0079] All matching nodes belong to the same scene.

[0080] It should be noted that Count(N2) <= Count(N1), the number of nodes in the matching graph is not greater than the number of nodes in the target graph, and Count(N2) refers to the number of elements in the set N2. N2 is the set of nodes in the subgraph G2.

[0081] N2_i->Scene_k, all matching nodes belong to the same scene, and Scene_k refers to the kth scene.

[0082] N2_i->Scene_k means that all N2 nodes belong to the same scene k.

[0083] f:i->j, :N2_i.ResourceGuid=N1_j.ResourceGuid, any N2 node i can be mapped to a different N1 node j, and the ResourceGuid of N1_i and N2_j nodes are the same, that is, the model type is the same. N2_i is actually the assumed matching node of N1_j.

[0084] This design ensures that when the matching subgraph cannot find a completely matching structure, it can also partially match the model nodes of the same type. Then, the relative transformation matrix between each pair and the difference value of the relative transformation matrix between each pair of user input nodes are calculated respectively.

[0085] Wf_N2i=Norm(w1*(M1_ip-M2_jq)), f:i->j,f:p->q;

[0086] Among them, Norm is a function of the norm, which takes the square root of each element of the matrix and then sums it up.

[0087] Where w1 is the weight matrix of position rotation, which can be adjusted or learned through a neural network. Wf_N2i represents the matching weight of node N2_i.

[0088] According to an embodiment of the present invention, establishing relative spatial relationship information between two pre-selected scene models based on attribute information specifically includes:

[0089] Establish a relative spatial relationship between any two pre-selected scene models of each scene;

[0090] Convert the positions and Euler angles of two pre-selected scene models into corresponding first translation matrix and second translation matrix;

[0091] Multiply the inverse matrix of the first translation matrix by the second translation matrix to obtain a relative transformation matrix;

[0092] The calculation formula is R=A^-1*B. R is the relative transformation matrix of B relative to A.

[0093] A relative spatial relationship between two pre-selected scene models is established based on the relative change matrix to obtain spatial relationship information.

[0094] It should be noted that in the process of spatial relationship analysis, the ground height needs to be processed. For example, if the user inputs a model of a robot and the algorithm recommends a base, the height of the base will be lower than the ground because the algorithm is based on the result of relative space transformation. In this case, the entire scene model needs to be automatically raised to keep the lowest point at the ground.

[0095] According to an embodiment of the present invention, the recommendation weights of a plurality of pre-selected scene models are calculated based on a recommendation algorithm, and the pre-selected scene models are analyzed based on the recommendation weights to obtain a recommendation model, which specifically includes:

[0096] Obtain the best matching subgraph, and calculate the recommendation weights for all nodes in the set area outside the best matching subgraph;

[0097] Recommend multiple models with the highest weights based on the recommendation weights;

[0098] According to the spatial relationship and connection relationship, the recommended model is automatically generated to the correct connection position and the correct model is connected.

[0099] It should be noted that in different scenarios, the stability of the relative matrix between nearby nodes and matching nodes is similar, so that some models with fixed spatial collocation can be screened out. For example, the conveyor belt and the source of goods always have a fixed relative position and rotation relationship; the robot arm and the base also always have a fixed up and down position relationship. The correct connection position is matched according to the spatial relationship and connection relationship, and the correct model is recommended for connection according to the connection position, which improves the accuracy of intelligent recommendation.

[0100] According to an embodiment of the present invention, the algorithm efficiency optimization method is as follows:

[0101] Randomly select 60% of the scene data for the next stage;

[0102] Calculate the number of saved scenes s with type type, the calculation formula is as follows; Ct=Count(n),n.ResourceGuid=type.ResourceGuid, n is the model node in scene s.

[0103] Calculate the selected weight Wsel_Si=sum((w1*log(Ct*w2)+1)*H(Ct)), where H is the step function; w1 is the weight matrix of position rotation;

[0104] Select the top 20% of the candidate weights to continue the subsequent calculations.

[0105] It should be noted that the algorithm's search space is very large, so pruning must be performed. In the matching algorithm, the matching calculations of some scenes are abandoned. When the recommendation algorithm is calculated, only the first 10% of nearby nodes closest to all matching nodes are selected for subsequent calculations to reduce the amount of calculation.

[0106] In a second aspect, an embodiment of the present application provides a simulation software model recommendation system based on a knowledge graph, the system comprising: a memory and a processor, the memory comprising a program of a simulation software model recommendation method based on a knowledge graph, and the program of the simulation software model recommendation method based on the knowledge graph is executed by the processor to implement the following steps:

[0107] Constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph comprises: at least one model node, each model node corresponding to an object in the target scene;

[0108] Filtering one or more pre-selected scene models matching the target scene graph from a pre-built graph database based on a graph matching algorithm;

[0109] Calculate the recommendation weights of each pre-selected scenario model, and determine the recommended model according to the recommendation weights of each pre-selected scenario model;

[0110] The model data is obtained based on the recommended model, and the model data is transmitted to the simulation software to obtain the recommended results.

[0111] It should be noted that the graph database neo4j is used to store scene data, calculate and store the relative transformation matrix between every two pre-selected scene model nodes, optimize the efficiency of the subsequent matching algorithm, convert the user input scene into a graph data structure, perform matching calculations in the database, find the subgraph with the highest matching degree, and finally recommend models based on the nodes near the subgraph. The spatial position of the final generated model is calculated based on the spatial relationship between the node and the matching graph, and the optimal model is recommended for connection based on the spatial position.

[0112] According to an embodiment of the present invention, the graph database construction step includes:

[0113] Obtain several scene engineering files, obtain multiple 3D scenes based on the scene engineering files, and analyze the duplication between different 3D scenes;

[0114] Merge 3D scenes whose repetition is greater than or equal to the set repetition threshold;

[0115] Classifying 3D scenes whose repetition is less than a set repetition threshold to obtain multiple types of 3D scenes, wherein the 3D scenes include multiple machine model objects, model objects, and text objects;

[0116] Acquire attribute information of machine model objects, model objects and text objects in each 3D scene, and establish relative spatial relationship information between two pre-selected scene models based on the attribute information, wherein the spatial relationship information includes machine connection information or relative transformation matrix;

[0117] Construct a graph database based on relative spatial relationship information.

[0118] It should be noted that the graph database contains multiple industrial solutions, each of which is one or more 3D scenes, and each scene contains multiple machine model objects, model objects, and text objects. Each object has attributes: spatial coordinates, Euler angles, child Guid, parent Guid, Guid, model, name, program, scale parameters, io parameters, ID, scene Guid, resource type ResourceGuid, binding object Guid, bound object Guid. Each model in the scene is a data node, and the label is ObjectEntity. The robot model is RobotEntity, and the text object is TextEntity. Each scene has two attributes, id and name. The scene and other nodes have a belonging relationship. The other three nodes are subordinate to a scene node. The relationship between the models is the edge data of the node, mainly the child-parent relationship, as well as the binding and bound relationship.

[0119] According to an embodiment of the present invention, one or more pre-selected scene models matching the target scene graph are screened out from a pre-built graph database based on a graph matching algorithm, specifically including:

[0120] Get the input scene, and obtain all the objects in the input scene based on the knowledge graph analysis. Take each object as a model node, and the relationship between model nodes as edges.

[0121] Obtain the type of the model node, establish a target graph based on the type of the model node, perform matching retrieval in the database based on the target graph, and find a matching subgraph;

[0122] Calculate the node matching degree and edge matching degree of the matched subgraph and model node, perform weighted calculation based on the node matching degree and edge matching degree, and find the subgraph with the largest weight based on the sorting weight;

[0123] A pre-selected scene model matching the scene is obtained based on the sub-graph with the largest weight.

[0124] It should be noted that the knowledge graph technology is used to more accurately obtain the spatial connection logical relationship of the model. The user selects some scenes and asks the software to make recommendations. All objects in the scene entered by the user are used as nodes. Assume that there are m model nodes, of which the Z type model has TC_z (the model type is determined by ResourceGuid, and models with the same attribute belong to the same type). The relationship between models is used as an edge to form a graph data G1={N1,V1,M1}; N1_i represents the i-th node, V1_ij represents the edge from node i to node j, M1_ij represents the transformation matrix of N1_j relative to N1_i, and M1_i represents the transformation matrix of N1_i, where M1_ij=M1_i^-1*M1_j; match and search in the database according to the target graph to find the matching subgraph G2={N2,V2,M2}, perform weighted calculations on the node matching degree and edge matching degree, and finally sort the weights to find the optimal matching subgraph.

[0125] According to an embodiment of the present invention, the matching subgraph is found to satisfy the following conditions:

[0126] The number of nodes in the matching graph is not greater than the number of nodes in the target graph;

[0127] All matching nodes belong to the same scene.

[0128] It should be noted that Count(N2)<=Count(N1), and the number of nodes in the matching graph is not greater than the number of nodes in the target graph.

[0129] N2_i->Scene_k, all matching nodes belong to the same scene.

[0130] f:i->j, :N2_i.ResourceGuid=N1_j.ResourceGuid, any N2 node i can be mapped to a different N1 node j, and the ResourceGuid of N1_i and N2_j nodes are the same, that is, the model type is the same. N2_i is actually the assumed matching node of N1_j.

[0131] This design ensures that when the matching subgraph cannot find a completely matching structure, it can also partially match the model nodes of the same type. Then, the relative transformation matrix between each pair and the difference value of the relative transformation matrix between each pair of user input nodes are calculated respectively.

[0132] Wf_N2i=Norm(w1*(M1_ip-M2_jq)), f:i->j,f:p->q;

[0133] Where w1 is the weight matrix of position rotation, which can be adjusted or learned through neural network. Wf_N2i represents the matching weight of node N2_i; Norm is the matrix generalization.

[0134] According to an embodiment of the present invention, establishing relative spatial relationship information between two pre-selected scene models based on attribute information specifically includes:

[0135] Establish a relative spatial relationship between any two pre-selected scene models of each scene;

[0136] Convert the positions and Euler angles of two pre-selected scene models into corresponding first translation matrix and second translation matrix;

[0137] Multiply the inverse matrix of the first translation matrix by the second translation matrix to obtain a relative transformation matrix;

[0138] The calculation formula is R=A^-1*B. R is the relative transformation matrix of B relative to A.

[0139] A relative spatial relationship between two pre-selected scene models is established based on the relative change matrix to obtain spatial relationship information.

[0140] It should be noted that in the process of spatial relationship analysis, the ground height needs to be processed. For example, if the user inputs a model of a robot and the algorithm recommends a base, the height of the base will be lower than the ground because the algorithm is based on the result of relative space transformation. In this case, the entire scene model needs to be automatically raised to keep the lowest point at the ground.

[0141] According to an embodiment of the present invention, the recommendation weights of a plurality of pre-selected scene models are calculated based on a recommendation algorithm, and the pre-selected scene models are analyzed based on the recommendation weights to obtain a recommendation model, which specifically includes:

[0142] Obtain the best matching subgraph, and calculate the recommendation weights for all nodes in the set area outside the best matching subgraph;

[0143] Recommend multiple models with the highest weights based on the recommendation weights;

[0144] According to the spatial relationship and connection relationship, the recommended model is automatically generated to the correct connection position and the correct model is connected.

[0145] It should be noted that in different scenarios, nearby nodes and matching nodes maintain similar relative matrix stability, which can screen out some models with fixed spatial collocations. For example, the conveyor belt and the source of goods always have a fixed relative position and rotation relationship; the robotic arm and the base also always have a fixed up and down position relationship. The correct connection position is matched according to the spatial relationship and the connection relationship, and the correct model is recommended for connection based on the connection position to improve the accuracy of intelligent recommendation.

[0146] According to an embodiment of the present invention, the algorithm efficiency optimization method is as follows:

[0147] Randomly select 60% of the scene data for the next stage;

[0148] Calculate the number of saved scenes s with type type, the calculation formula is as follows; Ct=Count(n),n.ResourceGuid=type.ResourceGuid; n is the model node in scene s;

[0149] Calculate the weight to be selected Wsel_Si=sum((w1*log(Ct*w2)+1)*H(Ct)), where H is a step function;

[0150] Select the top 20% of the candidate weights to continue the subsequent calculations.

[0151] It should be noted that the algorithm's search space is very large, so pruning must be performed. In the matching algorithm, the matching calculations of some scenes are abandoned. When the recommendation algorithm is calculated, only the first 10% of nearby nodes closest to all matching nodes are selected for subsequent calculations to reduce the amount of calculation.

[0152] The third aspect of the present invention provides a computer-readable storage medium, which includes a simulation software model recommendation method program based on a knowledge graph. When the simulation software model recommendation method program based on a knowledge graph is executed by a processor, the steps of the simulation software model recommendation method based on the knowledge graph as described above are implemented.

[0153] The present invention discloses a simulation software model recommendation method, system and medium based on knowledge graph, which obtains scene engineering files, pre-processes the scene engineering files and constructs a graph database; based on a graph matching algorithm, screens out one or more pre-selected scene models that match the target scene graph from the pre-constructed graph database; calculates recommendation weights of multiple pre-selected scene models based on the recommendation algorithm, analyzes the pre-selected scene models based on the recommendation weights and obtains recommendation models; obtains model data based on the recommendation model, transmits the model data to the simulation software and obtains recommendation results; based on a database of a large number of simulation solution scenarios, performs multi-dimensional (position relationship, rotation relationship, machine connection relationship) comprehensive calculations, recommends the model with the highest weight, calculates its spatial attributes, intelligently builds simulation scenes, and improves the work efficiency of designers.

[0154] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of devices or units can be electrical, mechanical or other forms.

[0155] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units; they may be located in one place or distributed on multiple network units; some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0156] In addition, all functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may be separately used as a unit, or two or more units may be integrated into one unit; the above-mentioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0157] Those skilled in the art can understand that: all or part of the steps of implementing the above method embodiments can be completed by hardware related to program instructions, the aforementioned program can be stored in a readable storage medium, and when the program is executed, it executes the steps of the above method embodiments; and the aforementioned storage medium includes: mobile storage devices, read-only memories (ROM, Read-Only Memory), random access memories (RAM, Random Access Memory), disks or optical disks, and other media that can store program codes.

[0158] Alternatively, if the above-mentioned integrated unit of the present invention is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present invention can be essentially or partly reflected in the form of a software product that contributes to the prior art. The software product is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the methods described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROM, RAM, magnetic disks or optical disks.

Claims

1. A simulation software model recommendation method based on knowledge graph, characterized in that: include: Constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph comprises: at least one model node, each model node corresponding to an object in the target scene; Filtering one or more pre-selected scene models matching the target scene graph from a pre-built graph database based on a graph matching algorithm; Calculate the recommendation weights of each pre-selected scenario model, and determine the recommended model according to the recommendation weights of each pre-selected scenario model; Acquire model data based on the recommended model, transfer the model data to the simulation software, and obtain the recommended results; The steps to build a graph database include: Obtain several scene engineering files, obtain multiple 3D scenes based on the scene engineering files, and analyze the duplication between different 3D scenes; Merge 3D scenes whose repetition is greater than or equal to the set repetition threshold; Classifying 3D scenes whose repetition is less than a set repetition threshold to obtain multiple types of 3D scenes, wherein the 3D scenes include multiple machine model objects, model objects, and text objects; Acquire attribute information of machine model objects, model objects and text objects in each 3D scene, and establish relative spatial relationship information between two pre-selected scene models based on the attribute information; Construct a graph database based on relative spatial relationship information.

2. The method for recommending simulation software models based on knowledge graph according to claim 1, characterized in that: One or more pre-selected scene models matching the target scene graph are selected from a pre-built graph database based on a graph matching algorithm, specifically including: Get the input scene, and obtain all the objects in the input scene based on the knowledge graph analysis. Take each object as a model node, and the relationship between model nodes as edges. Obtain the type of the model node, establish a target graph based on the type of the model node, perform matching retrieval in the database based on the target graph, and find a matching subgraph; Calculate the node matching degree and edge matching degree of the matched subgraph and model node, perform weighted calculation based on the node matching degree and edge matching degree, and find the subgraph with the largest weight based on the sorting weight; A pre-selected scene model matching the scene is obtained based on the sub-graph with the largest weight.

3. The method for recommending simulation software models based on knowledge graph according to claim 2, characterized in that: Find matching subgraphs that satisfy the following conditions: The number of nodes in the matching graph is not greater than the number of nodes in the target graph; All matching nodes belong to the same scene.

4. The method for recommending simulation software models based on knowledge graph according to claim 3, characterized in that: The relative spatial relationship information between the two pre-selected scene models is established based on the attribute information, specifically including: Establish a relative spatial relationship between any two pre-selected scene models of each scene; Convert the positions and Euler angles of two pre-selected scene models into corresponding first translation matrix and second translation matrix; Multiply the inverse matrix of the first translation matrix by the second translation matrix to obtain a relative transformation matrix; A relative spatial relationship between two pre-selected scene models is established based on the relative change matrix to obtain spatial relationship information.

5. The method for recommending simulation software models based on knowledge graph according to claim 4, characterized in that: The recommendation weights of multiple pre-selected scene models are calculated based on the recommendation algorithm, and the pre-selected scene models are analyzed based on the recommendation weights to obtain a recommendation model, which specifically includes: Obtain the best matching subgraph, and calculate the recommendation weights for all nodes in the set area outside the best matching subgraph; Recommend multiple models with the highest weights based on the recommendation weights; According to the spatial relationship and connection relationship, the recommended model is automatically generated to the correct connection position and the correct model is connected.

6. A simulation software model recommendation system based on knowledge graph, characterized in that: The system includes: a memory and a processor, wherein the memory includes a program of a simulation software model recommendation method based on a knowledge graph, and when the program of the simulation software model recommendation method based on a knowledge graph is executed by the processor, the following steps are implemented: Constructing a target scene graph of the target scene according to at least one object contained in the target scene, wherein the target scene graph comprises: at least one model node, each model node corresponding to an object in the target scene; Filtering one or more pre-selected scene models matching the target scene graph from a pre-built graph database based on a graph matching algorithm; Calculate the recommendation weights of each pre-selected scenario model, and determine the recommended model according to the recommendation weights of each pre-selected scenario model; Acquire model data based on the recommended model, transfer the model data to the simulation software, and obtain the recommended results; The steps to build a graph database include: Obtain several scene engineering files, obtain multiple 3D scenes based on the scene engineering files, and analyze the duplication between different 3D scenes; Merge 3D scenes whose repetition is greater than or equal to the set repetition threshold; Classifying 3D scenes whose repetition is less than a set repetition threshold to obtain multiple types of 3D scenes, wherein the 3D scenes include multiple machine model objects, model objects, and text objects; Acquire attribute information of machine model objects, model objects and text objects in each 3D scene, and establish relative spatial relationship information between two pre-selected scene models based on the attribute information, wherein the spatial relationship information includes machine connection information or relative transformation matrix; Construct a graph database based on relative spatial relationship information.

7. The simulation software model recommendation system based on knowledge graph according to claim 6, characterized in that: One or more pre-selected scene models matching the target scene graph are selected from a pre-built graph database based on a graph matching algorithm, specifically including: Get the input scene, and obtain all the objects in the input scene based on the knowledge graph analysis. Take each object as a model node, and the relationship between model nodes as edges. Obtain the type of the model node, establish a target graph based on the type of the model node, perform matching retrieval in the database based on the target graph, and find a matching subgraph; Calculate the node matching degree and edge matching degree of the matched subgraph and model node, perform weighted calculation based on the node matching degree and edge matching degree, and find the subgraph with the largest weight based on the sorting weight; A pre-selected scene model matching the scene is obtained based on the sub-graph with the largest weight.

8. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a simulation software model recommendation method program based on a knowledge graph. When the simulation software model recommendation method program based on a knowledge graph is executed by a processor, the steps of the simulation software model recommendation method based on a knowledge graph as described in any one of claims 1 to 5 are implemented.

Citation Information

Patent Citations

  • Intelligent recommendation method of models in servitization GNSS simulation platform

    CN106055577A

  • Recommendation method and device for simulation scene in automatic driving and electronic equipment

    CN115393619A