All Projects → rafguns → Linkpred

rafguns / Linkpred

Licence: other
Easy link prediction tool

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Linkpred

stripnet
STriP Net: Semantic Similarity of Scientific Papers (S3P) Network
Stars: ✭ 82 (-23.36%)
Mutual labels:  research, network-analysis
EstimNetDirected
Equilibrium Expectation for ERGM parameter estimation for large directed networks
Stars: ✭ 18 (-83.18%)
Mutual labels:  research, network-analysis
Network Threats Taxonomy
Machine Learning based Intrusion Detection Systems are difficult to evaluate due to a shortage of datasets representing accurately network traffic and their associated threats. In this project we attempt at solving this problem by presenting two taxonomies
Stars: ✭ 79 (-26.17%)
Mutual labels:  research, network-analysis
Networkanalysis
Java package that provides data structures and algorithms for network analysis.
Stars: ✭ 86 (-19.63%)
Mutual labels:  network-analysis
Morphogenesis Resources
Comprehensive list of resources on the topic of digital morphogenesis (the creation of form through code). Includes links to major articles, code repos, creative projects, books, software, and more.
Stars: ✭ 1,278 (+1094.39%)
Mutual labels:  research
Ariba
Antimicrobial Resistance Identification By Assembly
Stars: ✭ 96 (-10.28%)
Mutual labels:  research
Research Advice List
A compilation of research advice.
Stars: ✭ 103 (-3.74%)
Mutual labels:  research
Noxim
Network on Chip Simulator
Stars: ✭ 83 (-22.43%)
Mutual labels:  network-analysis
Graph sampling
Graph Sampling is a python package containing various approaches which samples the original graph according to different sample sizes.
Stars: ✭ 99 (-7.48%)
Mutual labels:  network-analysis
App
free software application for social network analysis and visualization
Stars: ✭ 94 (-12.15%)
Mutual labels:  network-analysis
Ffxivmon
A FFXIV Network Analysis Tool
Stars: ✭ 92 (-14.02%)
Mutual labels:  network-analysis
K8s Fah
⛑ Run [email protected] on Kubernetes
Stars: ✭ 90 (-15.89%)
Mutual labels:  research
Bruteshark
Network Analysis Tool
Stars: ✭ 1,335 (+1147.66%)
Mutual labels:  network-analysis
Theseus
A modern experimental OS written from scratch in Rust to explore novel OS structure, state management techniques, and how to maximally leverage the power of language by shifting OS responsibilities into the compiler.
Stars: ✭ 1,273 (+1089.72%)
Mutual labels:  research
Rasalit
Visualizations and helpers to improve and debug machine learning models for Rasa Open Source
Stars: ✭ 101 (-5.61%)
Mutual labels:  research
Pyndri
pyndri is a Python interface to the Indri search engine.
Stars: ✭ 85 (-20.56%)
Mutual labels:  research
Research And Coding
研究资源列表 A curated list of research resources
Stars: ✭ 100 (-6.54%)
Mutual labels:  research
Dynamite Nsm
DynamiteNSM is a free Network Security Monitor developed by Dynamite Analytics to enable network visibility and advanced cyber threat detection
Stars: ✭ 92 (-14.02%)
Mutual labels:  network-analysis
Daggy
Daggy - Data Aggregation Utility. Open source, free, cross-platform, server-less, useful utility for remote or local data aggregation and streaming
Stars: ✭ 91 (-14.95%)
Mutual labels:  network-analysis
Msnoise
A Python Package for Monitoring Seismic Velocity Changes using Ambient Seismic Noise | http://www.msnoise.org
Stars: ✭ 94 (-12.15%)
Mutual labels:  research

linkpred

linkpred is a Python package for link prediction: given a network, linkpred provides a number of heuristics (known as predictors) that assess the likelihood of potential links in a future snapshot of the network.

While some predictors are fairly straightforward (e.g., if two people have a large number of mutual friends, it seems likely that eventually they will meet and become friends), others are more involved.

.. image:: https://travis-ci.org/rafguns/linkpred.svg?branch=master :target: https://travis-ci.org/rafguns/linkpred

.. image:: https://coveralls.io/repos/rafguns/linkpred/badge.svg?branch=master :target: https://coveralls.io/r/rafguns/linkpred?branch=master

linkpred can both be used as a command-line tool and as a Python library in your own code.

Installation

linkpred (v0.5 and later) works under Python 3.6, 3.7, and 3.8. Version 0.4.1 was the last to support versions 3.4 and 3.5. It depends on:

  • matplotlib
  • networkx
  • numpy
  • pyyaml
  • scipy
  • smokesignal

You should be able to install linkpred and its dependencies using pip (pip install linkpred or python -m pip install linkpred). If you do not yet have Python installed, I recommend starting with Anaconda <https://www.continuum.io/downloads>, which includes optimized versions of packages like numpy. If you want to use the Community predictor, which relies on community structure of the network, make sure you also have the python-louvain <https://github.com/taynaud/python-louvain> package by installing with pip install linkpred[all].

Example usage as command-line tool

A good starting point is linkpred --help, which lists all the available options. To save the predictions of the CommonNeighbours predictor, for instance, run::

$ linkpred examples/inf1990-2004.net -p CommonNeighbours --output cache-predictions

where examples/inf1990-2004.net is a network file in Pajek format. Other supported formats include GML and GraphML. The full output looks like this:

.. code:: console

$ linkpred examples/inf1990-2004.net -p CommonNeighbours --output cache-predictions
16:43:13 - INFO - Reading file 'examples/inf1990-2004.net'...
16:43:13 - INFO - Successfully read file.
16:43:13 - INFO - Starting preprocessing...
16:43:13 - INFO - Removed 35 nodes (degree < 1)
16:43:13 - INFO - Finished preprocessing.
16:43:13 - INFO - Executing CommonNeighbours...
16:43:14 - INFO - Finished executing CommonNeighbours.
16:43:14 - INFO - Prediction run finished

$ head examples/inf1990-2004-CommonNeighbours-predictions_2016-04-22_16.43.txt
"Ikogami, K"    "Ikegami, K"    5.0
"Durand, T"     "Abd El Kader, M"       5.0
"Sharma, L"     "Kumar, S"      4.0
"Paul, A"       "Durand, T"     4.0
"Paul, A"       "Dudognon, G"   4.0
"Paul, A"       "Abd El Kader, M"       4.0
"Karisiddippa, CR"      "Garg, KC"      4.0
"Wu, YS"        "Kretschmer, H" 3.0
"Veugelers, R"  "Deleus, F"     3.0
"Veugelers, R"  "Andries, P"    3.0

Example usage within Python

.. code:: pycon

>>> import linkpred
>>> G = linkpred.read_network("examples/training.net")
11:49:00 - INFO - Reading file 'examples/training.net'...
11:49:00 - INFO - Successfully read file.
>>> len(G)   # number of nodes
632
>>> # We exclude edges already present, to predict only new links
>>> simrank = linkpred.predictors.SimRank(G, excluded=G.edges())
>>> simrank_results = simrank.predict(c=0.5)
>>> top = simrank_results.top(5)
>>> for authors, score in top.items():
...    print(authors, score)
...
Tomizawa, H - Fujigaki, Y 0.188686630053
Shirabe, M - Hayashi, T 0.143866427916
Garfield, E - Fuseler, EA 0.148097050146
Persson, O - Larsen, IM 0.138516589957
Vanleeuwen, TN - Noyons, ECM 0.185040358711
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].