All Projects → networkit → Networkit

networkit / Networkit

Licence: mit
NetworKit is a growing open-source toolkit for large-scale network analysis.

Programming Languages

python
139335 projects - #7 most used programming language
cpp
1120 projects

Projects that are alternatives of or similar to Networkit

Tidygraph
A tidy API for graph manipulation
Stars: ✭ 398 (+3.92%)
Mutual labels:  graph-algorithms, network-analysis
Sparkling Graph
SparklingGraph provides easy to use set of features that will give you ability to proces large scala graphs using Spark and GraphX.
Stars: ✭ 139 (-63.71%)
Mutual labels:  graph-algorithms, network-analysis
Pydata Networkx
A short tutorial on network analysis using Game of Thrones, US Airports and Python!
Stars: ✭ 50 (-86.95%)
Mutual labels:  graph-algorithms, network-analysis
Graphlayouts
new layout algorithms for network visualizations in R
Stars: ✭ 176 (-54.05%)
Mutual labels:  graph-algorithms, network-analysis
Depthmapx
depthmapX is a multi-platform Spatial Network Analysis Software
Stars: ✭ 120 (-68.67%)
Mutual labels:  graph-algorithms, network-analysis
edgebundle
R package implementing edge bundling algorithms
Stars: ✭ 100 (-73.89%)
Mutual labels:  graph-algorithms, network-analysis
Cyberscan
CyberScan: Network's Forensics ToolKit
Stars: ✭ 280 (-26.89%)
Mutual labels:  network-analysis
Algods
Implementation of Algorithms and Data Structures, Problems and Solutions
Stars: ✭ 3,295 (+760.31%)
Mutual labels:  graph-algorithms
Javascript Datastructures Algorithms
📚 collection of JavaScript and TypeScript data structures and algorithms for education purposes. Source code bundle of JavaScript algorithms and data structures book
Stars: ✭ 3,221 (+740.99%)
Mutual labels:  graph-algorithms
NetStalker
A network tool to control the bandwidth over your local network.
Stars: ✭ 69 (-81.98%)
Mutual labels:  network-analysis
Graph Adversarial Learning Literature
A curated list of adversarial attacks and defenses papers on graph-structured data.
Stars: ✭ 362 (-5.48%)
Mutual labels:  graph-algorithms
Suitesparse
The official SuiteSparse library: a suite of sparse matrix algorithms authored or co-authored by Tim Davis, Texas A&M University
Stars: ✭ 344 (-10.18%)
Mutual labels:  graph-algorithms
Frontendwingman
Frontend Wingman, Learn frontend faster!
Stars: ✭ 315 (-17.75%)
Mutual labels:  network-analysis
Rgl
RGL is a framework for graph data structures and algorithms in Ruby.
Stars: ✭ 279 (-27.15%)
Mutual labels:  graph-algorithms
Vivagraphjs
Graph drawing library for JavaScript
Stars: ✭ 3,442 (+798.69%)
Mutual labels:  graph-algorithms
Suzieq
A framework and application for network observability
Stars: ✭ 266 (-30.55%)
Mutual labels:  network-analysis
Communities
Library of community detection algorithms and visualization tools
Stars: ✭ 348 (-9.14%)
Mutual labels:  graph-algorithms
Lightweight Segmentation
Lightweight models for real-time semantic segmentation(include mobilenetv1-v3, shufflenetv1-v2, igcv3, efficientnet).
Stars: ✭ 261 (-31.85%)
Mutual labels:  network-analysis
Poseidon
Poseidon is a python-based application that leverages software defined networks (SDN) to acquire and then feed network traffic to a number of machine learning techniques. The machine learning algorithms classify and predict the type of device.
Stars: ✭ 310 (-19.06%)
Mutual labels:  network-analysis
Graph Fraud Detection Papers
A curated list of fraud detection papers using graph information or graph neural networks
Stars: ✭ 339 (-11.49%)
Mutual labels:  graph-algorithms

NetworKit - Lage-scale Network Analysis

NetworKit is an open-source tool suite for high-performance network analysis. Its aim is to provide tools for the analysis of large networks in the size range from thousands to billions of edges. For this purpose, it implements efficient graph algorithms, many of them parallel to utilize multicore architectures. These are meant to compute standard measures of network analysis. NetworKit is focused on scalability and comprehensiveness. NetworKit is also a testbed for algorithm engineering and contains novel algorithms from recently published research (see list of publications below).

NetworKit is a Python module. High-performance algorithms are written in C++ and exposed to Python via the Cython toolchain. Python in turn gives us the ability to work interactively and a rich environment of tools for data analysis and scientific computing. Furthermore, NetworKit's core can be built and used as a native library if needed.

Requirements

You will need the following software to install NetworKit as a python package:

  • A modern C++ compiler, e.g.: g++ (>= 5.3) or clang++ (>= 3.9)
  • OpenMP for parallelism (usually ships with the compiler)
  • Python3 (3.5 or higher is supported)
    • Development libraries for Python3. The package name depends on your distribution. Examples:
      • Debian/Ubuntu: apt-get install python3-dev
      • RHEL/CentOS: dnf install python3-devel
  • Pip
  • CMake version 3.5 or higher (e.g., pip3 install cmake)
  • Build system: Make or Ninja
  • Cython version 0.29 or higher (e.g., pip3 install cython)

Install

In order to use NetworKit, you can either install it via package managers or build the Python module from source.

Install via package manager

While the most recent version is in general available for all package managers, the number of older downloadable versions differ.

pip
pip3 install [--user] networkit
conda (channel conda-forge)
conda config --add channels conda-forge
conda install networkit [-c conda-forge]
brew
brew install networkit
spack
spack install py-networkit

Building the Python module from source

git clone https://github.com/networkit/networkit networkit
cd networkit
python3 setup.py build_ext [-jX]
pip3 install -e .

The script will call cmake and ninja (make as fallback) to compile NetworKit as a library, build the extensions and copy it to the top folder. By default, NetworKit will be built with the amount of available cores in optimized mode. It is possible the add the option -jN the number of threads used for compilation.

Usage example

To get an overview and learn about NetworKit's different functions/classes, have a look at our interactive notebooks-section, especially the Networkit UserGuide. Note: To view and edit the computed output from the notebooks, it is recommended to use Jupyter Notebook. This requires the prior installation of NetworKit. You should really check that out before start working on your network analysis.

We also provide a Binder-instance of our notebooks. To access this service, you can either click on the badge at the top or follow this link. Disclaimer: Due to rebuilds of the underlying image, it can takes some time until your Binder instance is ready for usage.

If you only want to see in short how NetworKit is used - the following example provides a climpse at that. Here we generate a random hyperbolic graph with 100k nodes and compute its communities with the PLM method:

>>> import networkit as nk
>>> g = nk.generators.HyperbolicGenerator(1e5).generate()
>>> communities = nk.community.detectCommunities(g, inspect=True)
PLM(balanced,pc,turbo) detected communities in 0.14577102661132812 [s]
solution properties:
-------------------  -----------
# communities        4536
min community size      1
max community size   2790
avg. community size    22.0459
modularity              0.987243
-------------------  -----------

Install the C++ Core only

In case you only want to work with NetworKit's C++ core, you can either install it via package managers or build it from source.

Install C++ core via package manager

conda (channel conda-forge)
conda config --add channels conda-forge
conda install libnetworkit [-c conda-forge]
brew
brew install libnetworkit
spack
spack install libnetworkit

Building the C++ core from source

We recommend CMake and your preferred build system for building the C++ part of NetworKit.

The following description shows how to use CMake in order to build the C++ Core only:

First you have to create and change to a build directory: (in this case named build)

mkdir build
cd build

Then call CMake to generate files for the make build system, specifying the directory of the root CMakeLists.txt file (e.g., ..). After this make is called to start the build process:

cmake ..
make -jX

To speed up the compilation with make a multi-core machine, you can append -jX where X denotes the number of threads to compile with.

Use NetworKit as a library

This paragraph explains how to use the NetworKit core C++ library in case it has been built from source. For how to use it when installed via package managers, best refer to the official documentation (brew, conda, spack).

In order to use the previous compiled networkit library, you need to have it installed, and link it while compiling your project. Use these instructions to compile and install NetworKit in /usr/local:

cmake ..
make -jX install

Once NetworKit has been installed, you can use include directives in your C++-application as follows:

#include <networkit/graph/Graph.hpp>

You can compile your source as follows:

g++ my_file.cpp -lnetworkit

Unit tests

Building and running NetworKit unit tests is not mandatory. However, as a developer you might want to write and run unit tests for your code, or if you experience any issues with NetworKit, you might want to check if NetworKit runs properly. The unit tests can only be run from a clone or copy of the repository and not from a pip installation. In order to run the unit tests, you need to compile them first. This is done by setting the CMake NETWORKI_BUILD_TESTS flag to ON:

cmake -DNETWORKIT_BUILD_TESTS=ON ..

Unit tests are implemented using GTest macros such as TEST_F(CentralityGTest, testBetweennessCentrality). Single tests can be executed with:

./networkit_tests --gtest_filter=CentralityGTest.testBetweennessCentrality

Additionally, one can specify the level of the logs outputs by adding --loglevel <log_level>; supported log levels are: TRACE, DEBUG, INFO, WARN, ERROR, and FATAL.

Compiling with address/leak sanitizers

Sanitizers are great tools to debug your code. NetworKit provides additional Cmake flags to enable address, leak, and undefined behavior sanitizers. To compile your code with sanitizers, set the CMake NETWORKIT_WITH_SANITIZERS to either address or leak:

cmake -DNETWORKIT_WITH_SANITIZERS=leak ..

By setting this flag to address, your code will be compiled with the address and the undefined sanitizers. Setting it to leak also adds the leak sanitizer.

Documentation

The most recent version of the documentation can be found online.

Contact

For questions regarding NetworKit, have a look at our issues-section and see if there is already an open discussion. If not feel free to open a new issue. To stay updated about this project, subscribe to our mailing list.

Contributions

We encourage contributions to the NetworKit source code. See the development guide for instructions. For support please contact the mailing list.

Credits

List of contributors can be found on the NetworKit website credits page.

External Code

The program source includes:

License

The source code of this program is released under the MIT License. We ask you to cite us if you use this code in your project (c.f. the publications section below and especially the technical report). Feedback is also welcome.

Publications

The NetworKit publications page lists the publications on NetworKit as a toolkit, on algorithms available in NetworKit, and simply using NetworKit. We ask you to cite the appropriate ones if you found NetworKit useful for your own research.

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].