CN115221211B - Graph calculation processing method and device, electronic equipment and storage medium - Google Patents

Graph calculation processing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN115221211B
CN115221211B CN202211148928.5A CN202211148928A CN115221211B CN 115221211 B CN115221211 B CN 115221211B CN 202211148928 A CN202211148928 A CN 202211148928A CN 115221211 B CN115221211 B CN 115221211B
Authority
CN
China
Prior art keywords
task
graph
graph calculation
current
calculation task
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
CN202211148928.5A
Other languages
Chinese (zh)
Other versions
CN115221211A (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.)
Fangtu Data Beijing Software Co ltd
State Grid Smart Grid Research Institute Co ltd
Original Assignee
Fangtu Data Beijing Software Co ltd
State Grid Smart Grid Research Institute Co ltd
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 Fangtu Data Beijing Software Co ltd, State Grid Smart Grid Research Institute Co ltd filed Critical Fangtu Data Beijing Software Co ltd
Priority to CN202211148928.5A priority Critical patent/CN115221211B/en
Publication of CN115221211A publication Critical patent/CN115221211A/en
Application granted granted Critical
Publication of CN115221211B publication Critical patent/CN115221211B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2457Query processing with adaptation to user needs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/28Databases characterised by their database models, e.g. relational or object models
    • G06F16/284Relational databases

Landscapes

  • Engineering & Computer Science (AREA)
  • Databases & Information Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application provides a graph calculation processing method, a graph calculation processing device, electronic equipment and a storage medium, wherein the method comprises the following steps: acquiring demand information of a current graph calculation task; in a preset relational database, according to the demand information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task; and determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task. According to the method provided by the scheme, when a new graph calculation task exists, the task execution data of the corresponding historical graph calculation task is reused, the task execution result of the current graph calculation task is obtained, and the current graph calculation task is executed without consuming calculation resources, so that the consumption of the graph calculation on the calculation resources is reduced, and a foundation is laid for improving the graph calculation efficiency.

Description

Graph calculation processing method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of graph database technologies, and in particular, to a graph calculation processing method and apparatus, an electronic device, and a storage medium.
Background
With the explosive development of the internet, the mobile internet, the social network, the internet of things and the associated network in the industrial field, such as the power network, the storage of the relational graph and the application of the network topology analysis and the function analysis based on the relational graph have great requirements, and the development of graph databases is also promoted.
Graph computation is a process of expressing and solving problems by taking graphs as data models, and graph computation in the prior art generally executes corresponding graph computation algorithms according to the current graph computation requirements of users.
However, one graph database may be accessed by multiple users at the same time, and in the case of a large graph calculation demand, consumption of the computation resources by the graph calculation is seriously increased, and it is not beneficial to ensure the graph calculation efficiency.
Disclosure of Invention
The application provides a graph calculation processing method, a graph calculation processing device, an electronic device and a storage medium, so as to overcome the defects that in the prior art, under the condition of large graph calculation demand, the consumption of graph calculation on calculation resources is seriously increased, and the like.
A first aspect of the present application provides a graph computation processing method, including:
acquiring demand information of a current graph calculation task;
in a preset relational database, according to the demand information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task;
and determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task.
Optionally, in the preset relational database, the task execution data is stored according to a preset compound index, an index item included in the preset compound index corresponds to a requirement index included in the requirement information, and the requirement information includes a plurality of requirement indexes, such as point filtering information, edge filtering information, an algorithm name during graph computation operation, a graph computation parameter, a graph instance name, and a graph data version number.
Optionally, the determining a current task execution result of the current graph computation task according to the task execution data of the target history graph computation task includes:
determining storage position information of a historical task execution result of the target historical graph calculation task according to task execution data of the target historical graph calculation task;
reading the historical task execution result according to the storage position information of the historical task execution result;
and determining the historical task execution result as the current task execution result of the current graph calculation task.
Optionally, the invoking, in the preset relational database, task execution data of a target historical graph calculation task similar to the current graph calculation task according to the requirement information includes:
acquiring running condition information of each historical map calculation task in the preset relational database;
screening target historical map calculation tasks similar to the current map calculation tasks in the preset relational database according to the matching degree between the running condition information and the requirement information of each historical map calculation task;
and calling task execution data of the target historical graph calculation task in the preset relational database.
Optionally, the method further includes:
when the matching degree between the running condition information and the requirement information of each historical graph calculation task represents that no target historical graph calculation task exists in the preset relational database, executing the current graph calculation task according to the requirement information of the current graph calculation task to obtain task execution data of the current graph calculation task;
taking the current graph calculation task as a new historical graph calculation task;
determining the running condition information of the new historical map computing task according to the requirement information of the current map computing task;
and adding task execution data and corresponding operating condition information of the new historical map calculation task into the preset relational database.
Optionally, the method further includes:
and calculating the task type of the task according to the current graph, and storing the current task execution result to a corresponding storage position.
Optionally, before invoking task execution data of the target history graph computation task in the preset relational database, the method further includes:
acquiring state information of the target historical graph calculation task;
judging whether the target historical graph calculation task can be reused or not according to the state information of the target historical graph calculation task;
if the target historical graph calculation task is determined to be reusable, executing the step of calling task execution data of the target historical graph calculation task in the preset relational database;
otherwise, executing the current graph calculation task according to the requirement information of the current graph calculation task.
A second aspect of the present application provides a graph calculation processing apparatus including:
the acquisition module is used for acquiring the demand information of the current graph calculation task;
the calling module is used for calling task execution data of a target historical graph calculation task similar to the current graph calculation task in a preset relational database according to the requirement information;
and the processing module is used for determining the current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task.
Optionally, in the preset relational database, the task execution data is stored according to a preset compound index, an index item included in the preset compound index corresponds to a requirement index included in the requirement information, and the requirement information includes a plurality of requirement indexes, such as point filtering information, side filtering information, an algorithm name during graph computation operation, a graph computation parameter, a graph instance name, and a graph data version number.
Optionally, the processing module is specifically configured to:
determining storage position information of a historical task execution result of the target historical graph calculation task according to task execution data of the target historical graph calculation task;
reading the historical task execution result according to the storage position information of the historical task execution result;
and determining the historical task execution result as the current task execution result of the current graph calculation task.
Optionally, the calling module is specifically configured to:
obtaining the operating condition information of each historical graph calculation task in the preset relational database;
screening target historical map calculation tasks similar to the current map calculation tasks in the preset relational database according to the matching degree between the running condition information and the requirement information of each historical map calculation task;
and calling task execution data of the target historical graph calculation task in the preset relational database.
Optionally, the processing module is further configured to:
when the matching degree between the running condition information and the requirement information of each historical graph calculation task represents that no target historical graph calculation task exists in the preset relational database, executing the current graph calculation task according to the requirement information of the current graph calculation task to obtain task execution data of the current graph calculation task;
taking the current graph calculation task as a new historical graph calculation task;
determining the running condition information of the new historical map computing task according to the requirement information of the current map computing task;
and adding task execution data and corresponding operating condition information of the new historical map calculation task into the preset relational database.
Optionally, the processing module is further configured to:
and calculating the task type of the task according to the current graph, and storing the current task execution result to a corresponding storage position.
Optionally, the invoking module is further configured to:
acquiring state information of the target historical graph calculation task;
judging whether the target historical graph calculation task can be reused or not according to the state information of the target historical graph calculation task;
if the target historical graph calculation task is determined to be reusable, executing the step of calling task execution data of the target historical graph calculation task in the preset relational database;
otherwise, executing the current graph calculation task according to the requirement information of the current graph calculation task.
A third aspect of the present application provides an electronic device, comprising: at least one processor and a memory;
the memory stores computer execution instructions;
execution of the computer-executable instructions stored by the memory by the at least one processor causes the at least one processor to perform the method as set forth in the first aspect above and in various possible designs of the first aspect.
A fourth aspect of the present application provides a computer-readable storage medium having stored thereon computer-executable instructions that, when executed by a processor, implement a method as set forth in the first aspect and various possible designs of the first aspect.
This application technical scheme has following advantage:
the application provides a graph calculation processing method, a graph calculation processing device, electronic equipment and a storage medium, wherein the method comprises the following steps: acquiring demand information of a current graph calculation task; in a preset relational database, according to the demand information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task; and determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task. According to the method provided by the scheme, when a new graph calculation task exists, the task execution data of the corresponding historical graph calculation task is reused, the task execution result of the current graph calculation task is obtained, and the current graph calculation task is executed without consuming calculation resources, so that the consumption of the graph calculation on the calculation resources is reduced, and a foundation is laid for improving the graph calculation efficiency.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the embodiments or the prior art descriptions will be briefly described below, it is obvious that the drawings in the following descriptions are some embodiments of the present application, and other drawings can be obtained by those skilled in the art according to these drawings.
FIG. 1 is a schematic diagram of a graph computation processing system based on an embodiment of the present application;
fig. 2 is a schematic flowchart of a graph calculation processing method according to an embodiment of the present application;
FIG. 3 is a schematic structural diagram of a graph calculation processing apparatus according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Specific embodiments of the present application have been shown by way of example in the drawings and will be described in more detail below. These drawings and written description are not intended to limit the scope of the disclosed concepts in any way, but rather to illustrate the concepts of the disclosure to those skilled in the art by reference to specific embodiments.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Furthermore, the terms "first", "second", etc. are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. In the description of the following examples, "plurality" means two or more unless specifically limited otherwise.
Graph computation is a process of expressing and solving problems by using a graph as a data model, namely, some characteristics, such as importance, similarity and the like, of a series of vertexes of all or a specified range in the graph are computed in a graph traversal mode, and the results are generally obtained by carrying out full-scale scanning analysis on the whole data. The core of graph computation is computation based on the correlation between vertices. The graph computation application scenario includes: social network analysis, cyber attack analysis, knowledge graphs, industrial fields, and the like. Common algorithms for graph computation include pagerank, KCore, short Path, connected Component, triangle Count, etc., and are applicable to different scenes and meet different computation algorithm requirements.
Generally, graph computation introduces an asynchronous computation model, and in the practical field of graph database and graph computation engineering, for example, an overall Synchronous Parallel computation model (BSP), a Gather-application-Scatter (GAS-Scatter) model or a data flow (dataflow) model is applied, wherein the BSP model is most widely applied. However, a graph database may be accessed by multiple users at the same time, and in any graph computation model, under the condition of large graph computation demand, the consumption of computation resources in graph computation is seriously increased, and the graph computation efficiency is not ensured.
In order to solve the above problem, in the graph calculation processing method and apparatus, the electronic device, and the storage medium provided by the embodiment of the application, the requirement information of the current graph calculation task is acquired; in a preset relational database, according to the demand information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task; and determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task. According to the method provided by the scheme, when a new graph calculation task exists, the task execution data of the corresponding historical graph calculation task is reused, the task execution result of the current graph calculation task is obtained, and the current graph calculation task is executed without consuming calculation resources, so that the consumption of the graph calculation on the calculation resources is reduced, and a foundation is laid for improving the graph calculation efficiency.
The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments. Embodiments of the present invention will be described below with reference to the accompanying drawings.
First, a configuration of a graph calculation processing system based on the present application will be explained:
the graph computation processing method and device, the electronic device and the storage medium provided by the embodiment of the application are suitable for reducing the consumption of computation resources by graph computation tasks. Fig. 1 is a schematic structural diagram of a graph calculation processing system according to an embodiment of the present application, which mainly includes a graph database, a data acquisition device, and a graph calculation processing device. Specifically, the demand information of the current graph calculation task may be acquired based on the data acquisition device, and the information is sent to the graph calculation processing device, and the graph calculation processing device determines the graph calculation result corresponding to the graph database according to the acquired information, that is, determines the current task execution result of the current graph calculation task.
The embodiment of the application provides a graph computation processing method, which is used for reducing the consumption of computation resources by a graph computation task. The execution subject of the embodiment of the present application is an electronic device, such as a server, a desktop computer, a notebook computer, a tablet computer, and other electronic devices that can be used for performing graph computation.
As shown in fig. 2, a schematic flowchart of a graph calculation processing method provided in an embodiment of the present application is shown, where the method includes:
step 201, obtaining the requirement information of the current graph calculation task.
The demand information comprises a plurality of demand indexes including point filtering information, side filtering information, an algorithm name when the graph is calculated, a graph calculation parameter, a graph instance name and a graph data version number.
It should be noted that the point filtering information includes a type condition of a point, an attribute condition of the point, a degree condition of the point, and the like, the edge filtering information includes a type condition of an edge, an attribute condition of the edge, a direction condition of the edge, and the like, an algorithm name during graph calculation running represents which algorithm needs to be run by a current graph calculation task, the graph calculation parameter is a parameter of the algorithm that needs to be run, for example, parameters such as alpha, epsilon, and maximum iteration number during pagerank algorithm running, and the graph instance name is used to determine which graph instance the current graph calculation task acts on to determine an execution range corresponding to the current graph calculation task, and a graph data version number represents a snapshot version number of a graph database during execution of the current graph calculation task.
Step 202, in the preset relational database, according to the requirement information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task.
In order to increase the call speed of the task execution data, the task execution data may be stored in the preset relational database according to a preset compound index, where an index item included in the preset compound index corresponds to a requirement index included in the requirement information, that is, an index item included in the compound index of the preset relational database includes point filtering information, edge filtering information, an algorithm name during graph calculation, a graph calculation parameter, a graph instance name, and a graph data version number.
Specifically, based on the composite index of the preset relational database, according to the requirement information of the current computation task, task execution data of a target historical map computation task capable of meeting the requirement information is called in the preset relational database, where the target historical map computation task capable of meeting the requirement information is a target historical map computation task similar to the current map computation task, and the task execution data is task execution context data.
And step 203, determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task.
Specifically, in the case where the task execution data includes a task execution result, the current task execution result of the previous graph calculation task may be determined by analyzing the task execution data of the target history graph calculation task.
Specifically, in an embodiment, the storage location information of the historical task execution result of the target history map computing task may be determined according to the task execution data of the target history map computing task; reading the historical task execution result according to the storage position information of the historical task execution result; and determining the historical task execution result as the current task execution result of the current graph calculation task.
The storage position information of the historical task execution result at least comprises a specific storage path.
On the basis of the foregoing embodiment, as an implementable manner, in an embodiment, invoking task execution data of a target history graph calculation task similar to the current graph calculation task in a preset relational database according to the requirement information includes:
step 2021, obtaining operation condition information of each historical map calculation task in a preset relational database;
step 2022, according to the matching degree between the operation condition information and the requirement information of each historical map calculation task, screening a target historical map calculation task similar to the current map calculation task in a preset relational database;
step 2023, invoking task execution data of the target historical map computing task in the preset relational database.
The operation condition information of the history map calculation task may include requirement information of the history map calculation task during execution, that is, the operation condition information of the history map calculation task may include point filtering information, edge filtering information, an algorithm name during map calculation, a map calculation parameter, a map instance name, and a map data version number. The operation condition information of the historical map calculation task completely represents a combination of a program, data and parameters, and can uniquely determine the environment of multiple operations and the environment during data query, so that the method can be used for determining which historical map calculation task is the target historical map calculation task.
Specifically, the point filtering information, the edge filtering information, the algorithm name during graph computation, the graph computation parameter, the graph instance name, and the graph data version number represented by the requirement information of the current graph computation task may be used as a composite index, a target historical graph computation task whose operation condition information matches the requirement information is screened from the preset relational database, and further, the task execution data of the target historical graph computation task is called from the preset relational database.
On the basis of the foregoing embodiment, as an implementable manner, in an embodiment, the method further includes:
step 301, when the matching degree between the operation condition information and the requirement information of each historical graph calculation task represents that no target historical graph calculation task exists in the preset relational database, executing the current graph calculation task according to the requirement information of the current graph calculation task to obtain task execution data of the current graph calculation task;
step 302, taking the current graph calculation task as a new historical graph calculation task;
step 303, determining the operation condition information of a new historical map calculation task according to the requirement information of the current map calculation task;
and step 304, adding task execution data of the new historical graph calculation task and corresponding running condition information into a preset relational database.
Specifically, if there is no target historical graph calculation task similar to the current calculation task in the preset relational database, the current graph calculation task needs to be executed according to the requirement information of the current graph calculation task and the corresponding graph calculation task execution logic, so as to obtain task execution data of the current graph calculation task. And then, the executed current graph calculation task is used as a new historical graph calculation task, and the new historical graph calculation task, together with the operation condition information represented by the requirement information and the task execution data generated in the execution process, is stored in a preset relational database so as to realize the data expansion of the preset relational database and provide a data basis for the subsequent graph processing calculation task.
Specifically, in an embodiment, if the preset relational database has point filtering information, edge filtering information, algorithm names during graph computation, graph computation parameters, and graph instance names represented by the operating condition information of a plurality of historical graph computation tasks matching the requirement information of the current graph computation task, the unique graph data version number does not match, and is not the current latest version of the graph database, that is, after the historical graph computation task is executed, the graph database is updated with data. In this case, of the plurality of history map calculation tasks, the history map calculation task with the latest map data version number may be selected as the target history map calculation task, that is, the most recently executed history map calculation task may be determined as the target history map calculation task.
Specifically, in an embodiment, a distance calculation mode may also be adopted, and according to the operation condition information of each historical map calculation task and the requirement information of the current map calculation task, the similarity between the current map calculation task and each historical map calculation task is determined, and then the historical map calculation task having the highest similarity and meeting the minimum similarity standard is determined as the target historical map calculation task.
Specifically, in an embodiment, in order to ensure reliability of a finally obtained current task execution result, before task execution data of a target history graph computation task is called in a preset relational database, state information of the target history graph computation task may be acquired; according to the state information of the target historical graph calculation task, judging whether the target historical graph calculation task can be reused or not; if the target historical graph calculation task is determined to be reusable, executing the step of calling task execution data of the target historical graph calculation task in a preset relational database; otherwise, executing the step of executing the current graph calculation task according to the requirement information of the current graph calculation task.
It should be noted that the status information of the target history graph calculation task can be classified into committed, running, cancelled, running successful and running failed. If the state information of the target historical graph calculation task is submitted, running or running successfully, the historical graph calculation task is characterized to be reusable, and if the state information of the target historical graph calculation task is cancelled or running fails, the historical graph calculation task is characterized to be not reusable, namely the current graph calculation task needs to be executed.
The state information of the historical map calculation task can be updated in real time along with the running condition of a map calculation algorithm of the historical map calculation task.
On the basis of the foregoing embodiment, as an implementable manner, in an embodiment, the method further includes:
step 401, according to the task type of the current graph calculation task, storing the current task execution result to a corresponding storage location.
Specifically, in the case that the current task execution result of the current graph calculation task includes a graph database or related data of each point in the graph instance, the current task execution result may be stored in an attribute manner, facilitating subsequent data query.
Accordingly, in the case that the task type of the current graph calculation task is the path calculation, the current task execution result is not associated with a single point, for example, the result data calculated by the global shortest path algorithm includes two vertex pairs having shortest paths and their shortest path information, so that the data is not associated with a single vertex and cannot correspond to the stored data of a specific vertex, and therefore the execution result of the task type may be stored in an integral manner in a designated storage location of the preset relational database or other databases and is not associated with a single specific vertex.
According to the graph calculation processing method provided by the embodiment of the application, the demand information of the current graph calculation task is acquired; in a preset relational database, according to the demand information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task; and determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task. According to the method provided by the scheme, when a new graph calculation task exists, the task execution data of the corresponding historical graph calculation task is reused, the task execution result of the current graph calculation task is obtained, and the current graph calculation task is executed without consuming calculation resources, so that the consumption of the graph calculation on the calculation resources is reduced, and a foundation is laid for improving the graph calculation efficiency. And moreover, by means of management of the relational database and introduction of the compound index, the screening speed of the target historical graph calculation task is increased, and a foundation is laid for further increasing the graph calculation efficiency.
The embodiment of the application provides a graph calculation processing device, which is used for executing the graph calculation processing method provided by the embodiment.
Fig. 3 is a schematic structural diagram of a graph calculation processing apparatus according to an embodiment of the present application. The map calculation processing device 30 includes: an acquisition module 301, a calling module 302 and a processing module 303.
The acquisition module is used for acquiring the demand information of the current graph calculation task; the calling module is used for calling task execution data of a target historical graph calculation task similar to the current graph calculation task in a preset relational database according to the requirement information; and the processing module is used for determining the current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task.
Specifically, in an embodiment, in the preset relational database, the task execution data is stored according to a preset compound index, an index item included in the preset compound index corresponds to a requirement index included in the requirement information, and the requirement information includes a plurality of requirement indexes, such as point filtering information, edge filtering information, an algorithm name during graph calculation, a graph calculation parameter, a graph instance name, and a graph data version number.
Specifically, in an embodiment, the processing module is specifically configured to:
determining storage position information of a historical task execution result of the target historical graph calculation task according to task execution data of the target historical graph calculation task;
reading the historical task execution result according to the storage position information of the historical task execution result;
and determining the historical task execution result as the current task execution result of the current graph calculation task.
Specifically, in an embodiment, the calling module is specifically configured to:
acquiring running condition information of each historical map calculation task in a preset relational database;
screening target historical map calculation tasks similar to the current map calculation tasks in a preset relational database according to the matching degree between the operation condition information and the requirement information of each historical map calculation task;
and calling task execution data of the target historical graph calculation task in a preset relational database.
Specifically, in an embodiment, the processing module is further configured to:
when the matching degree between the running condition information and the requirement information of each historical graph calculation task represents that no target historical graph calculation task exists in the preset relational database, executing the current graph calculation task according to the requirement information of the current graph calculation task to obtain task execution data of the current graph calculation task;
taking the current graph calculation task as a new historical graph calculation task;
determining the operation condition information of a new historical graph calculation task according to the requirement information of the current graph calculation task;
and adding task execution data and corresponding operating condition information of a new historical map calculation task into a preset relational database.
Specifically, in an embodiment, the processing module is further configured to:
and calculating the task type of the task according to the current graph, and storing the current task execution result to a corresponding storage position.
Specifically, in an embodiment, the invoking module is further configured to:
acquiring state information of a target historical graph calculation task;
according to the state information of the target historical graph calculation task, judging whether the target historical graph calculation task can be reused or not;
if the target historical graph calculation task is determined to be reusable, executing the step of calling task execution data of the target historical graph calculation task in a preset relational database;
otherwise, executing the step of executing the current graph calculation task according to the requirement information of the current graph calculation task.
With regard to the graph calculation processing apparatus in the present embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment related to the method, and will not be described in detail here.
The graph calculation processing device provided in the embodiment of the present application is configured to execute the graph calculation processing method provided in the above embodiment, and an implementation manner and a principle of the graph calculation processing device are the same and are not described again.
The embodiment of the application provides electronic equipment for executing the graph calculation processing method provided by the embodiment.
Fig. 4 is a schematic structural diagram of an electronic device according to an embodiment of the present application. The electronic device 40 includes: at least one processor 41 and a memory 42.
The memory stores computer execution instructions; the at least one processor executes computer-executable instructions stored by the memory, causing the at least one processor to perform the graph computation processing method provided by the above embodiments.
The electronic device provided in the embodiment of the present application is configured to execute the graph calculation processing method provided in the above embodiment, and an implementation manner and a principle of the method are the same, and are not described again.
The embodiment of the present application provides a computer-readable storage medium, where a computer execution instruction is stored in the computer-readable storage medium, and when a processor executes the computer execution instruction, the graph calculation processing method provided in any embodiment above is implemented.
The storage medium containing the computer-executable instructions of the embodiment of the present application may be used to store the computer-executable instructions of the graph calculation processing method provided in the foregoing embodiment, and the implementation manner and principle thereof are the same and are not described again.
In the several embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium and includes several instructions to enable a computer device (which may be a personal computer, a server, or a network device) or a processor (processor) to execute some steps of the methods according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
It is obvious to those skilled in the art that, for convenience and simplicity of description, the foregoing division of the functional modules is merely used as an example, and in practical applications, the above function distribution may be performed by different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to perform all or part of the above described functions. For the specific working process of the device described above, reference may be made to the corresponding process in the foregoing method embodiment, which is not described herein again.
Finally, it should be noted that: the above embodiments are only used for illustrating the technical solutions of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art will understand that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present application.

Claims (7)

1. A graph computation processing method, comprising:
acquiring demand information of a current graph calculation task;
in a preset relational database, according to the requirement information, calling task execution data of a target historical graph calculation task similar to the current graph calculation task;
determining a current task execution result of the current graph calculation task according to task execution data of the target historical graph calculation task;
the calling task execution data of a target historical graph calculation task similar to the current graph calculation task in the preset relational database according to the requirement information comprises the following steps:
acquiring running condition information of each historical map calculation task in the preset relational database;
screening target historical map calculation tasks similar to the current map calculation tasks in the preset relational database according to the matching degree between the running condition information and the requirement information of each historical map calculation task;
in the preset relational database, calling task execution data of the target historical graph calculation task;
the determining a current task execution result of the current graph computation task according to the task execution data of the target historical graph computation task includes:
determining storage position information of a historical task execution result of the target historical graph calculation task according to task execution data of the target historical graph calculation task;
reading the historical task execution result according to the storage position information of the historical task execution result;
determining the historical task execution result as the current task execution result of the current graph calculation task;
in the preset relational database, the task execution data is stored according to a preset compound index, an index item included in the preset compound index corresponds to a requirement index included in the requirement information, and the requirement information includes a plurality of requirement indexes, such as point filtering information, side filtering information, an algorithm name during graph calculation operation, a graph calculation parameter, a graph instance name and a graph data version number.
2. The method of claim 1, further comprising:
when the matching degree between the running condition information and the requirement information of each historical graph calculation task represents that no target historical graph calculation task exists in the preset relational database, executing the current graph calculation task according to the requirement information of the current graph calculation task to obtain task execution data of the current graph calculation task;
taking the current graph calculation task as a new historical graph calculation task;
determining the operation condition information of the new historical graph calculation task according to the requirement information of the current graph calculation task;
and adding task execution data and corresponding operating condition information of the new historical map calculation task into the preset relational database.
3. The method of claim 2, further comprising:
and calculating the task type of the task according to the current graph, and storing the current task execution result to a corresponding storage position.
4. The method according to claim 2, wherein before invoking task execution data of the target history graph computation task in the preset relational database, the method further comprises:
acquiring state information of the target historical graph calculation task;
judging whether the target historical graph calculation task can be reused or not according to the state information of the target historical graph calculation task;
if the target historical graph calculation task is determined to be reusable, executing the step of calling task execution data of the target historical graph calculation task in the preset relational database;
otherwise, executing the current graph calculation task according to the requirement information of the current graph calculation task.
5. A map calculation processing apparatus characterized by comprising:
the acquisition module is used for acquiring the demand information of the current graph calculation task;
the calling module is used for calling task execution data of a target historical graph calculation task similar to the current graph calculation task in a preset relational database according to the requirement information;
the processing module is used for determining a current task execution result of the current graph calculation task according to the task execution data of the target historical graph calculation task;
the calling module is specifically configured to:
obtaining the operating condition information of each historical graph calculation task in the preset relational database;
screening target historical map calculation tasks similar to the current map calculation tasks in the preset relational database according to the matching degree between the running condition information and the requirement information of each historical map calculation task;
in the preset relational database, calling task execution data of the target historical graph calculation task;
the processing module is specifically configured to:
determining storage position information of a historical task execution result of the target historical graph calculation task according to task execution data of the target historical graph calculation task;
reading the historical task execution result according to the storage position information of the historical task execution result;
determining the historical task execution result as the current task execution result of the current graph calculation task;
in the preset relational database, the task execution data is stored according to a preset compound index, index items included in the preset compound index correspond to requirement indexes included in the requirement information, and the requirement information includes point filtering information, side filtering information, algorithm names during graph calculation, graph calculation parameters, graph instance names and multiple requirement indexes of graph data version numbers.
6. An electronic device, comprising: at least one processor and a memory;
the memory stores computer execution instructions;
the at least one processor executing the computer-executable instructions stored by the memory causes the at least one processor to perform the method of any of claims 1 to 4.
7. A computer-readable storage medium having stored thereon computer-executable instructions which, when executed by a processor, implement the method of any one of claims 1 to 4.
CN202211148928.5A 2022-09-21 2022-09-21 Graph calculation processing method and device, electronic equipment and storage medium Active CN115221211B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211148928.5A CN115221211B (en) 2022-09-21 2022-09-21 Graph calculation processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211148928.5A CN115221211B (en) 2022-09-21 2022-09-21 Graph calculation processing method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN115221211A CN115221211A (en) 2022-10-21
CN115221211B true CN115221211B (en) 2023-02-28

Family

ID=83617500

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211148928.5A Active CN115221211B (en) 2022-09-21 2022-09-21 Graph calculation processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115221211B (en)

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112182387B (en) * 2020-09-29 2023-08-25 中国人民大学 Personalized search method with time information enhancement
CN112162878B (en) * 2020-09-30 2021-09-28 深圳前海微众银行股份有限公司 Database fault discovery method and device, electronic equipment and storage medium
CN112579304A (en) * 2020-12-30 2021-03-30 成都佳华物链云科技有限公司 Resource scheduling method, device, equipment and medium based on distributed platform
CN113220542B (en) * 2021-04-01 2022-10-28 深圳市云网万店科技有限公司 Early warning method and device for computing task, computer equipment and storage medium
CN113434702A (en) * 2021-07-27 2021-09-24 支付宝(杭州)信息技术有限公司 Self-adaptive control method and system for graph calculation
CN114944209A (en) * 2022-03-11 2022-08-26 青岛百洋智能科技股份有限公司 Integrated computing method and system for medical similar medical records

Also Published As

Publication number Publication date
CN115221211A (en) 2022-10-21

Similar Documents

Publication Publication Date Title
CN106980623B (en) Data model determination method and device
CN110162637B (en) Information map construction method, device and equipment
CN112800197A (en) Method and device for determining target fault information
CN112528067A (en) Graph database storage method, graph database reading method, graph database storage device, graph database reading device and graph database reading equipment
CN114461644A (en) Data acquisition method and device, electronic equipment and storage medium
US8650180B2 (en) Efficient optimization over uncertain data
CN114880742A (en) Revit model lightweight method for webgl engine
CN107977504A (en) A kind of asymmetric in-core fuel management computational methods, device and terminal device
CN110245074A (en) A kind of generation method of log recording, device, storage medium and server
CN113342647A (en) Test data generation method and device
CN115221211B (en) Graph calculation processing method and device, electronic equipment and storage medium
CN117155772A (en) Alarm information enrichment method, device, equipment and storage medium
US12061585B2 (en) Systems and methods of modeling and querying dynamic temporal graph on massive parallel graph processing and storage engine
CN115409070A (en) Method, device and equipment for determining critical point of discrete data sequence
CN114896418A (en) Knowledge graph construction method and device, electronic equipment and storage medium
CN113824583B (en) Root element positioning method and device, computer equipment and storage medium
CN115269654A (en) Data cache supplementing method, device, equipment and medium
CN114897666A (en) Graph data storage, access, processing method, training method, device and medium
CN115168509A (en) Processing method and device of wind control data, storage medium and computer equipment
CN112181825A (en) Test case library construction method and device, electronic equipment and medium
CN113792170A (en) Graph data dividing method and device and computer equipment
CN113742116A (en) Abnormity positioning method, abnormity positioning device, abnormity positioning equipment and storage medium
CN117494539B (en) Method and device for searching particle nearest neighbor in object plane fluid simulation and electronic equipment
CN115250231B (en) Application configuration method and device
CN116383454B (en) Data query method of graph database, electronic equipment 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
GR01 Patent grant