Public Member Functions | |
def | __init__ |
Constructs an empty graph. | |
def | setProbs |
Sets the probability with which quadrants in an adjacency matrix are chosen. | |
def | generate |
Generates a the graph. | |
def | populate |
Populate graph with edges generated after a call to DirectedPowerLawRandomGraph::generate. | |
def | writeEdges |
Write edges to file. | |
Public Attributes | |
graphSize | |
Number of vertices to be considered for generation. | |
noOfEdges | |
Number of edges to generate. | |
probA | |
Parameters of the RMAT algorithm. | |
probB | |
Probability of choosing quadrant B. | |
probC | |
Probability of choosing quadrant C. | |
probD | |
Probability of choosing quadrant D. | |
serialEdgeList | |
Temporary storage of edges. | |
debug | |
Debug flag. | |
startVertX | |
endVertX | |
startVertY | |
endVertY |
def pygel::RandomGraphs::DirectedPowerLawRandomGraph::DirectedPowerLawRandomGraph::__init__ | ( | self, | ||
size, | ||||
noOfEdges | ||||
) |
Constructs an empty graph.
size | Number of vertices to be considered for generation | |
noOfEdges | Number of edges to generate |
def pygel::RandomGraphs::DirectedPowerLawRandomGraph::DirectedPowerLawRandomGraph::setProbs | ( | self, | ||
probA, | ||||
probB, | ||||
probC, | ||||
probD | ||||
) |
Sets the probability with which quadrants in an adjacency matrix are chosen.
probA | Probability of choosing quadrant A | |
probB | Probability of choosing quadrant B | |
probC | Probability of choosing quadrant C | |
probD | Probability of choosing quadrant D |
PackageExceptions::DistError |
def pygel::RandomGraphs::DirectedPowerLawRandomGraph::DirectedPowerLawRandomGraph::generate | ( | self, | ||
noOfThreads, | ||||
noSelfLoops | ||||
) |
Generates a the graph.
Heart of web graph generation algorithm. Each thread gets an equal number of nodes to generate.
noOfThreads | Number of threads to spawn for the graph generation. More threads does not correspond to fast generation | |
noSelfLoops | If true (set to 1) self loops are discarded in the resulting graph. |
def pygel::RandomGraphs::DirectedPowerLawRandomGraph::DirectedPowerLawRandomGraph::populate | ( | self | ) |
Populate graph with edges generated after a call to DirectedPowerLawRandomGraph::generate.
You should call this method before you can use any of the non-overridden method in Graph::NumberedEdgeDirectedGraph
def pygel::RandomGraphs::DirectedPowerLawRandomGraph::DirectedPowerLawRandomGraph::writeEdges | ( | self, | ||
fileName, | ||||
format | ||||
) |
Write edges to file.
fileName | File name to store edges | |
format | Format of output file. Can take values: 'simple' = simple format 'dot' = format compatible with 'dot' command 'csv' = comma separated value format |
Reimplemented from pygel::Graph::NumberedEdgeDirectedGraph::NumberedEdgeDirectedGraph.
Parameters of the RMAT algorithm.
Decide the probability with which quadrants in an adjacency matrix are chosen
Temporary storage of edges.
Maintained for achieving performance