pyrgg is an easy to use synthetic random graph generator written in python, that support variant graph file formats include DIMACS(.gr) pyrgg has the ability to generate graphs in different sizes and designed to provide input files for test, benchmark and performance-analysis of graph processing frameworks, but it can be used in any other research program that include graphs with these formats.
- Download Version 0.1 or Latest Source
pip install -r requirements.txt
orpip3 install -r requirements.txt
(Need root access)python3 setup.py install
orpython setup.py install
(Need root access)
- Check Python Packaging User Guide
pip install pyrgg
orpip3 install pyrgg
(Need root access)
Download Full Run Video (2.8 MB - MKV)( This video recorded by simplescreenrecorder )
python3 -m pyrgg test
or python -m pyrgg test
This test run automatically in each commit ;-)
Just fill an issue and describe it. I'll check it ASAP! or send an email to sepand@qpage.ir.
- Formats
- DIMACS
- JSON
- YAML
- Pickle
- CSV
- WEL
- ASP
- TGF
- UCINET DL
- Sizes
- Small
- Medium
- Large
- Weighted Graph
- Signed Weights
- Dense Graph
- Sparse Graph
- Directed Graph
- Self loop
- Parallel Arc
- Multithreading
- GUI
- Erdős–Rényi model
- Tree
- Sample 1-DIMACS (100 Vertices , 3KB)
- Sample 2-DIMACS (1000 Vertices , 13KB)
- Sample 3-DIMACS (1000000 Vertices , 7MB)
- Sample 4-DIMACS (5000000 Vertices , 37MB)
- Sample 1-JSON (100 Vertices , 11KB)
- Sample 2-JSON (1000 Vertices , 105KB)
- Sample 1-CSV (100 Vertices , 3KB)
- Sample 2-CSV (1000 Vertices , 51KB)
- Sample 1-WEL (100 Vertices , 5KB)
- Sample 2-WEL (1000 Vertices , 192KB)
- Sample 1-YAML (30 Vertices , 3KB)
- Sample 2-YAML (100 Vertices , 12KB)
- Sample 1-LP (100 Vertices , 7KB)
- Sample 2-LP (1000 Vertices , 76KB)
- Sample 1-Pickle (100 Vertices , 15KB)
- Sample 2-Pickle (1000 Vertices , 209KB)
- Sample 1-TGF (100 Vertices , 4KB)
- Sample 2-TGF (1000 Vertices , 61KB)
- Sample 1-UCINET DL (100 Vertices , 8KB)
- Sample 2-UCINET DL (1000 Vertices , 729KB)
- Generate synthetic data for graph processing frameworks (some of them mentioned here) performance-analysis
- Generate synthetic data for graph benchmark suite like GAP
-
p sp <number of vertices> <number of directed edge> a <head_1> <tail_1> <weight_1> . . . a <head_n> <tail_n> <weight_n>
-
<head_1>,<tail_1>,<weight_1> . . . <head_n>,<tail_n>,<weight_n>
-
{ "graph": { "nodes":[ { "id": "1" }, . . . { "id": "n" } ], "edges":[ { "source": "head_1", "target": "tail_1", "weight": "weight_1" }, . . . { "source": "head_n", "target": "tail_n", "weight": "weight_n" }, ] } }
-
graph: edges: - source: "head_1" target: "tail_1" weight: "weight_1" . . . - source: "head_n" target: "tail_n" weight: "weight_n" nodes: - id: '1' . . . - id: 'n'
-
<head_1> <tail_1> <weight_1> . . . <head_n> <tail_n> <weight_n>
-
node(1). . . . node(n). edge(head_1,tail_1,weight_1). . . . edge(head_n,tail_n,weight_n).
-
1 . . . n # 1 2 weight_1 . . . n k weight_n
-
dl format=edgelist1 n=<number of vertices> data: 1 2 weight_1 . . . n k weight_n
-
Pickle(.p) (Binary Format)
You can fork the repository, improve or fix some part of it and then send the pull requests back if you want to see them here. I really appreciate that. ❤️
Remember to write a few tests for your code before sending pull requests.
- Random Modular Network Generator Generates random graphs with tunable strength of community structure
- randomGraph very simple random graph generator in matlab
- Graph1 Random Graph Generator with Max capacity paths (C++)
If you use pyrgg in your research , please cite this ;-)
[1]Sepand Haghighi. pyrgg : Python Random Graph Generator 2017. doi:10.5281/zenodo.845502
Hey dude! Help me out for a couple of 🍻!
1XGr9qbZjBpUQJJSB6WtgBQbDTgrhPLPA