Fast Retrieval Method and System for Personalized Web Page Ranking with Uncertainty on Graph

By calculating the possible world of uncertain graphs and using ilu decomposition, we quickly obtain personalized PageRank scores, solving the problem of low computing efficiency and low accuracy on large-scale graphs, and achieving efficient and accurate personalized web page rankings.

CN114861058BActive Publication Date: 2025-06-24NANJING UNIV OF SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210544711.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-05-19
Publication Date
2025-06-24
Estimated Expiration
2042-05-19

AI Technical Summary

Technical Problem

The existing personalized PageRank calculation method of uncertain graphs is inefficient and has low accuracy on large-scale graphs, especially when the seed nodes are close to uncertain edges, the error is large, which cannot meet the fast and high-precision query requirements.

Method used

By calculating all possible worlds of uncertain graphs, using ilu decomposition to calculate only partial rows of the system matrix inverse R, and perform small matrix inversion and vector operations during the query process to obtain personalized PageRank scores.

Benefits of technology

It realizes the calculation in a short time, and the result accuracy is high, meeting the query needs, the speed is increased by hundreds of times, and the accuracy is close to 1.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114861058B_ABST
    Figure CN114861058B_ABST
Patent Text Reader

Abstract

The present invention discloses a fast retrieval method and system for personalized web page ranking on an uncertain graph. The method includes the following steps: calculating all possible worlds of the uncertain graph through the information of uncertain edges; calculating and saving partial rows of matrix R through ilu decomposition; given a seed node as a single query of personalized PageRank (PPR), using this method to obtain the PPR scores of each node under this query; sorting the results and obtaining the top k nodes with the highest scores. The present invention provides a calculation method for personalized web page ranking on an uncertain graph, which improves the calculation method of PPR. Compared with the traditional method, it has a faster calculation speed and higher accuracy, and improves the query performance when the uncertain graph is relatively large or the uncertainty of the graph is relatively large.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of retrieval, and particularly to a fast retrieval method and system for personalized web page ranking on an uncertain graph. Background Art

[0002] A graph is a powerful general way to represent the relationships and connection patterns between objects. Many research objects in fields such as mathematics, computer science, physics, social science, and biology can be abstracted into graphs, among which the Internet is the most well-known and most studied graph.

[0003] Google proposed an algorithm for calculating node rankings, PageRank. With the popularity of the Google search engine, PageRank has also become a very popular graph node ranking algorithm and is widely applied to the research of Web pages, social networks, the connection between genes and diseases, protein reactions, traffic prediction, etc. Compared with other ranking methods, the results obtained by the PageRank algorithm are more difficult to forge.

[0004] However, in practical applications and research, the graphs encountered are often very large in scale, and due to reasons such as information loss, errors in data collection, and data privacy protection, the graph data is full of uncertainties. Recently, a new uncertain edge model - mutually exclusive edges has been proposed, that is, we are certain that there is a certain edge, but we cannot determine which of the target nodes pointed to by this edge. A graph containing uncertain edges is an uncertain graph.

[0005] Currently, there are mainly three methods for calculating the personalized PageRank of an uncertain graph: one is the enumeration method, which calculates the PPR scores for all possible worlds of the uncertain graph respectively and then takes the average value. This method is also the defined method, and the obtained results are also the most accurate; the second is the collapse method, which takes the average value of the transition matrices of all possible worlds and then performs PPR calculation; the third is the flatten method, that is, first convert the uncertain edges into certain edges and then perform PPR calculation; the fourth is the recently proposed uppr, which splits the uncertain graph into a certain part and an uncertain part and processes them respectively by means such as partitioning and calculating probabilities.

[0006] However, a mutually exclusive edge uncertain graph with only m uncertain edges, and each uncertain edge has only k target nodes, can be decomposed into k m possible worlds. Therefore, among the current methods, the enumeration method and the collapse method are very inefficient. Although the flatten method improves the speed, its accuracy is relatively low. Especially in personalized PageRank, when the seed node is near the uncertain edge, the errors of the collapse method and the flatten method are relatively large. Uppr is still time-consuming when dealing with large graphs, has a high space complexity, and its accuracy is also average. Summary of the Invention

[0007] The object of the present invention is to provide a fast retrieval method and system for personalized web page ranking on an uncertain graph, which can complete the calculation in a relatively short time, and at the same time can ensure high accuracy to meet the query requirements.

[0008] The technical solution for achieving the object of the present invention is as follows: In the first aspect, the present invention provides a fast retrieval method for personalized web page ranking on an uncertain graph, including the following steps:

[0009] Step 1, calculate all possible worlds of the uncertain graph through the information of uncertain edges, where the possible worlds are all the definite forms of the uncertain graph determined by the uncertain edges;

[0010] Step 2, calculate partial rows of the inverse R of the system matrix through ilu decomposition, where the system matrix is I - cQ, determined by the transition matrix Q of the definite part of the graph, I is the identity matrix, and c is the restart probability of random walk;

[0011] Step 3, given a seed node as a single query of personalized PageRank, obtain the PPR scores of each node under this query;

[0012] Step 4, sort the results and obtain the top k nodes with the highest scores.

[0013] In the second aspect, the present invention provides a fast retrieval system for personalized web page ranking on an uncertain graph, including:

[0014] The first module calculates all possible worlds of the uncertain graph through the information of uncertain edges, where the possible worlds are all the definite forms of the uncertain graph determined by the uncertain edges;

[0015] The second module calculates partial rows of the inverse R of the system matrix through ilu decomposition, where the system matrix is I - cQ, determined by the transition matrix Q of the definite part of the graph, I is the identity matrix, and c is the restart probability of random walk;

[0016] The third module, given a seed node as a single query of personalized PageRank, obtains the PPR scores of each node under this query;

[0017] The fourth module is used to sort the results and obtain the top k nodes with the highest scores.

[0018] In the third aspect, the present invention provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the program, it implements the steps of the method described in the first aspect.

[0019] Fourthly, the present invention provides a computer-readable storage medium, on which a computer program is stored, and when the program is executed by a processor, the steps of the method described in the first aspect are implemented.

[0020] Compared with the prior art, the significant advantages of the present invention are as follows: (1) In the preprocessing part, for the inverse R of the system matrix, only some of its rows are calculated and stored, and both the required time and space are relatively low; (2) In the query part, for each possible world, only the inverse of a small matrix, matrix-vector multiplication operations, and vector addition operations are designed, and the speed is hundreds or even nearly a thousand times faster than the original method; (3) The obtained results are basically 1 in multiple accuracy metrics, that is, the retrieval results are more accurate. Description of the Drawings

[0021] Figure 1 is a flowchart of a fast retrieval method for personalized web page ranking on an uncertain graph according to the present invention.

[0022] Figure 2 is the uncertain graph in the embodiment of the present invention. Detailed Embodiments

[0023] A fast retrieval method for personalized web page ranking on an uncertain graph according to the present invention includes the following steps:

[0024] Step 1, calculate all possible worlds of the uncertain graph through the information of the uncertain edges, where the possible worlds are all the definite form cases of the uncertain graph determined by the uncertain edges;

[0025] The uncertain edge includes a source node and multiple target nodes, representing that the target of the edge is 1 or 0 of the target nodes. When the target is 0, the edge does not exist.

[0026] Step 2, calculate some rows of the inverse R of the system matrix through ilu decomposition, where the system matrix is I - cQ and is determined by the transition matrix Q of the definite part of the graph;

[0027] The ilu decomposition is a decomposition that only selects the pivot elements, and the drop tolerance droptol is set to 0.1.

[0028] Further, the specific steps of Step 2 are as follows:

[0029] Step 2.1, perform ilu decomposition on the system matrix to obtain the L matrix and the U matrix

[0030] LU = I - cQ;

[0031] Step 2.2, find some rows of the inverse R of the system matrix

[0032] R V,* = EU-1 L -1

[0033]

[0034] Among them, I is the identity matrix, Q is the transition matrix of the deterministic part of the uncertain graph, c is the restart probability of the random walk, V is the set of source nodes, and R V,* is the row of matrix R related to the nodes in V, E is an l×n matrix composed of unit vectors related to the source nodes, l is the length of V, and n is the size of the transition matrix Q.

[0035] Step 3: Given the seed nodes as a query for personalized PageRank, obtain the PPR scores of each node under this query. The specific steps are as follows:

[0036] Step 3.1: Calculate the personalized PageRank scores of the deterministic part of the graph according to the selected set of seed nodes S

[0037] p0 = cQp0 + (1 - c)s

[0038] where s is the starting vector determined by the seed nodes, and when the node v i ∈S, otherwise s i = 0;

[0039] Step 3.2: For all other possible worlds generated, calculate the intermediate vectors h and h' for all other possible worlds according to the initial PPR scores, and sum them to obtain h sum and h' sum , and for the i-th possible world, the calculation is as follows:

[0040]

[0041] h sum = h sum + h

[0042] where D is the diagonal matrix composed of the out-degrees of the graph nodes, x i , y i are the source node and the corresponding target node of the current possible world respectively, excluding the uncertain edges with an empty target, and are l×l matrices obtained by taking values from the rows and columns of matrix R according to the node pairs in x i and y i , is the PPR score vector of the nodes in x i in the deterministic part of the graph, and h sum is the sum of the state vectors h under each possible world;

[0043]

[0044] h' sum = h' sum + h'

[0045] Wherein, is the column in the identity matrix I related to the nodes in y i , h is the state vector of each possible world with length l, and h' is the mapping of each value in the state vector h to a vector with length n;

[0046] Step 3.3, calculate the sum of the increments of the PPR scores of all possible worlds relative to p0

[0047] z0 = ch' sum - cQ *,V h sum

[0048] z k = U -1 L -1 z0

[0049] Wherein, Q *,V is the column in the transition matrix Q of the deterministic part of the graph related to the nodes in V, and z0 is the initial value of calculating the sum of increments z k ;

[0050] Step 3.4, calculate the final PPR score of the uncertain graph according to the results of all possible worlds

[0051] p = p0 + z k / n pw

[0052] Wherein, n pw is the number of possible worlds.

[0053] Step 4, sort the results and obtain the k nodes with the highest scores.

[0054] The present invention also provides a fast retrieval system for personalized web page ranking on an uncertain graph, including:

[0055] The first module, calculates all possible worlds of the uncertain graph through the information of the uncertain edges, wherein the possible worlds are all the deterministic form cases of the uncertain graph determined by the uncertain edges;

[0056] The second module, calculates partial rows of the inverse R of the system matrix through ilu decomposition, wherein the system matrix is I - cQ, determined by the transition matrix Q of the deterministic part of the graph, I is the identity matrix, and c is the restart probability of random walk;

[0057] The third module, given a seed node as a single query of personalized PageRank, obtains the PPR scores of each node under this query;

[0058] The fourth module is used to sort the results and obtain the top k nodes with the highest scores.

[0059] The specific implementation methods of the above modules are the same as those in the previous part of the fast retrieval method, and will not be elaborated here.

[0060] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.

[0061] Embodiment

[0062] Since there are many nodes in the real graph and it is not easy to observe its distribution, a small graph is used here for calculation and explanation.

[0063] As Figure 1 , an uncertain graph with 3 uncertain edges, where the solid lines represent the certain edges and the dashed lines represent the possible edges in the uncertain edges. Among them, in a possible world, only one target node exists in an uncertain edge, and the empty node ε represents the non-existence of this edge.

[0064] Combined with Figure 2 , a fast retrieval method for personalized web ranking on an uncertain graph according to the present invention is as follows:

[0065] Step 1, input Figure 1 the adjacency matrix and uncertain edge information represented, and obtain the transition matrix Q of the graph and the possible worlds. Among them, the source nodes and target nodes of its uncertain edges are V = [2, 3, 7] and W = {[3, ε], [5, 6, 8, ε], [4, 8, ε]} respectively, and the possible worlds are the Cartesian product of the three sets in the target node W. Therefore, there are 24 possible worlds in this uncertain graph.

[0066] Step 2, obtain the relevant partial rows of the inverse R of the system matrix related to the source nodes;

[0067] Step 2.1, take the restart probability c as 0.6, perform ilu decomposition on I - cQ, and save

[0068]

[0069]

[0070] Step 2.2, according to the source nodes V, for the matrix E = [e2, e3, e7] T , calculate the partial rows of the required matrix R and save

[0071]

[0072] Step 3, given the seed node S = [3, 7], the starting vector for this query is s = [0, 0, 0.5, 0, 0, 0, 0.5, 0] T , obtain the PPR scores of each node under this query;

[0073] Step 3.1, according to the personalized PageRank calculation formula p0 = cQp0 + (1 - c)s, obtain the PPR scores of the determined part of the graph

[0074] p0 = [0, 0, 0.2, 0.138, 0.06, 0.078, 0.2, 0] T

[0075] where the number of iterations is set to 15;

[0076] Step 3.2, assume that the source node and target node of the uncertain edge in the i-th possible world are x i = [2, 3, 7] and y i = [3, 5, 4], and the diagonal matrix formed by the out-degree of the source node is Then according to the formula and we can obtain

[0077] h = [0, 0.1, 0.0667] T h' = [0, 0, 0, 0.0667, 0.1, 0, 0, 0] T

[0078] Calculate the intermediate vectors h and h' of all possible worlds, and obtain their sums h sum and h' sum , where, in a certain possible world, when the target node of an uncertain edge is ε, it means that the uncertain edge does not exist;

[0079] Step 3.3, according to h sum and h' sum obtained in the above steps, according to the formula z0 = ch' sum - cQ *,V h sum and z k = U -1 L -1 z0, calculate the sum of the increments of the PPR scores of all possible worlds relative to p0

[0080] z k = [0, 0, 0, -0.7480, 0.04, 0.052, 0, 0.68] T

[0081] Step 3.4, according to the formula p = p0 + zk / n pw , obtain the final result

[0082] p = [0, 0, 0.2, 0.1068, 0.0617, 0.0802, 0.2, 0.0283] T

[0083] The obtained result is exactly the same as the result obtained by the defined method.

[0084] Step 4, sort the obtained results in descending order and take the top k nodes as needed.

[0085] The above steps show the calculation process of the personalized PageRank score for the uncertain graph of the embodiment. Similarly, the personalized PageRank calculation can be completed for the real dataset, and the accuracy of the results obtained by this method is 1 or close to 1 in multiple accuracy calculation methods such as mAP, nDCG, kendall, and spearman.

Claims

1. A fast retrieval method for personalized web page ranking on an uncertain graph, characterized in that, It includes the following steps: Step 1: Calculate all possible worlds of the uncertain graph based on the information of the uncertain edges. Here, a possible world refers to all the definite form cases of the uncertain graph determined by the uncertain edges; Step 2: Calculate partial rows of the inverse R of the system matrix through ILU decomposition. The system matrix is I - cQ, which is determined by the transition matrix Q of the definite part of the graph, I is the identity matrix, and c is the restart probability of the random walk. Specifically: Step 2.1: Perform ILU decomposition on the system matrix to obtain the L matrix and the U matrix LU = I - cQ; Step 2.2: Find partial rows of the inverse R of the system matrix R V,* = EU -1 L -1 where V is the set of source nodes, R V,* is the row of matrix R related to the nodes in V, E is an l×n matrix composed of unit vectors related to the source nodes, l is the length of V, and n is the size of the transition matrix Q; Step 3: Given a seed node as a single query for personalized PageRank, obtain the PPR scores of each node under this query. Specifically: Step 3.1: Calculate the personalized PageRank scores of the definite part of the graph according to the selected seed node set S p0 = cQp0 + (1 - c)s where s is the starting vector determined by the seed node, and when the node v i ∈ S, in other cases s i = 0; Step 3.

2. For all other possible worlds generated, calculate the intermediate vectors h and h' for all other possible worlds according to the initial PPR scores, and sum them up to obtain h sum and h' sum , and for the i-th possible world, the calculation is as follows: h sum = h sum + h where D is a diagonal matrix composed of the out-degrees of graph nodes, and x i , y i are the source node and the corresponding target node of the current possible world respectively, excluding the uncertain edges with an empty target, and are l×l matrices obtained by taking values from the rows and columns of matrix R for the node pairs in x i and y i ; is the PPR score vector of the nodes in x i in the deterministic part of the graph, and h sum is the sum of the state vectors h under each possible world; h' sum = h' sum + h' Among them, is the column in the identity matrix I related to the nodes in y i The state vector of each possible world with length l is h, and h' is the mapping of the values in the state vector h to a vector with length n; Step 3.3: Calculate the sum of the increments of the PPR scores of all possible worlds relative to p0 z0 = ch' sum -cQ *,V h sum z k = U -1 L -1 z0 where Q *,V is the column of the transition matrix Q of the determined part of the graph related to the nodes in V, and z0 is the initial value of the sum of the calculation increments z k ; Step 3.4: Calculate the final PPR scores of the uncertain graph according to the results of all possible worlds p = p0 + z k / n pw where n pw is the number of possible worlds; Step 4: Sort the results and obtain the k nodes with the highest scores.

2. The rapid retrieval method for personalized web page ranking on an uncertain graph according to claim 1, characterized in that The uncertain edge described in Step 1 includes a source node and multiple target nodes, representing that the target of this edge is one or zero of the target nodes. When the target is zero, this edge does not exist.

3. The rapid retrieval method for personalized web page ranking on an uncertain graph according to claim 1, characterized in that, The ILU decomposition described in Step 2 is a decomposition that only selects pivots, and the drop tolerance droptol is set to 0.

1.

4. A fast retrieval system for personalized web page ranking on an uncertain graph, characterized in that, It includes: The first module: Calculate all possible worlds of the uncertain graph based on the information of the uncertain edges. Here, a possible world refers to all the definite form cases of the uncertain graph determined by the uncertain edges; The second module: Calculate partial rows of the inverse R of the system matrix through ILU decomposition. The system matrix is I - cQ, which is determined by the transition matrix Q of the definite part of the graph, I is the identity matrix, and c is the restart probability of the random walk. Specifically: Perform ILU decomposition on the system matrix to obtain the L matrix and the U matrix LU = I - cQ; Find partial rows of the inverse R of the system matrix R V,* = EU -1 L -1 where V is the set of source nodes, R V,* is the row of matrix R related to the nodes in V, E is an l×n matrix composed of unit vectors related to the source nodes, l is the length of V, and n is the size of the transition matrix Q; The third module: Given a seed node as a single query for personalized PageRank, obtain the PPR scores of each node under this query. Specifically: Calculate the personalized PageRank scores of the definite part of the graph according to the selected seed node set S p0 = cQp0 + (1 - c)s where s is the starting vector determined by the seed node, and when node v i ∈ S, in other cases s i = 0; For all other possible worlds generated, according to the initial PPR scores, calculate the intermediate vectors h and h' for all other possible worlds, and sum them up to obtain h sum and h' sum , for the i-th possible world, the calculation is as follows: h sum = h sum + h where D is a diagonal matrix composed of the out-degrees of graph nodes, and x i , y i are respectively the source node and the corresponding target node of the current possible world, excluding the uncertain edges with empty targets, and are l×l matrices obtained by taking values from the rows and columns of matrix R for the node pairs in x i and y i ; is the PPR score vector of the nodes in x i in the deterministic part of the graph, and h sum is the sum of the state vectors h under each possible world; h' sum = h' sum + h' Among them, is the column in the identity matrix I related to the nodes in y i , h is the state vector of each possible world with length l, and h' is the mapping of each value in the state vector h to a vector with length n; Calculate the sum of the increments of the PPR scores of all possible worlds relative to p0 z0 = ch' sum -cQ *,V h sum z k = U -1 L -1 z0 where Q *,V is the column of the transition matrix Q of the determined part of the graph related to the nodes in V, and z0 is the initial value of the sum of the calculation increments z k ; Calculate the final PPR scores of the uncertain graph according to the results of all possible worlds p = p0 + z k / n pw where n pw is the number of possible worlds; The fourth module: Used to sort the results and obtain the k nodes with the highest scores.

5. The quick retrieval system for personalized web page ranking on an uncertain graph according to claim 4, characterized in that The described uncertain edge includes a source node and multiple target nodes, representing that the target of this edge is one or zero of the target nodes. When the target is zero, this edge does not exist.

6. The fast retrieval system for personalized web page ranking on an uncertain graph according to claim 4, wherein The ILU decomposition described in Step 2 is a decomposition that only selects pivots, and the drop tolerance droptol is set to 0.

1.

7. A computer device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the method described in any one of claims 1 - 3.

8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the program implements the steps of the method described in any one of claims 1-3.

Citation Information

Patent Citations

  • Hypergraph-based image retrieval and tagging method

    CN107145519A

  • Web crawler method and system based on improved PageRank

    CN111753161A