Skip to main content

A python interface for decompressing Boldi-Vigna graphs

Project description

This library implements a decoder for a Boldi-Vigna graph structure, a highly compressed means of storing web-graphs. The library is written in pure C. It includes a Python interface, and a means to implement multi-threaded graph algorithms.

Features

  • In-memory and on-disk graph storage

  • Sequential iteration over graph edges

  • Parallel iteration over graph edges

  • random access to graph edges

Installation

1.1 Install with pip:

pip install pylibbvg

1.2 Uninstall:

pip uninstall pylibbvg

2.1. Compile from the source code(Cython is assumed to have installed):

python setup.py build_ext --inplace

2.2. To clean the library:

python setup.py clean

Synopsis

To use the library in Python code:

import bvg
G = bvg.BVGraph('wb-cs.stanford', 0) # sequential scan
print 'nodes = ' + str(G.nverts)
print 'edges = ' + str(G.nedges)
edges_and_degrees = G.edges_and_degrees()
for (src, dst, degree) in edges_and_degrees:
    print 'node ' + str(src) + ' has degree ' + str(degree)
    print 'edge: ' + str(src) + ' -> ' + str(dst)

License

GPL version 2.

Copyright by David F. Gleich, 2007-2014

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pylibbvg-2.0.25.tar.gz (148.3 kB view details)

Uploaded Source

File details

Details for the file pylibbvg-2.0.25.tar.gz.

File metadata

  • Download URL: pylibbvg-2.0.25.tar.gz
  • Upload date:
  • Size: 148.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for pylibbvg-2.0.25.tar.gz
Algorithm Hash digest
SHA256 d2036e8f1d77fbf50eaf33503af631612e7d93a25b40e696cbff955728e7632f
MD5 5740254fd5205e7fd459d963a74d2331
BLAKE2b-256 9bfcb5451e83c05fab8d37e4500fcf2bd08f8e15398858956a55ad2854151590

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page