Skip to main content

A Python framework for relational representation learning

Project description



Welcome to Spektral

Spektral is a Python library for graph deep learning, based on the Keras API. The main goal of this project is to provide a simple but flexible framework for creating graph neural networks (GNNs).

You can use Spektral for classifying the nodes of a network, predicting molecular properties, generating new graphs with GANs, clustering nodes, predicting links, and any other task where data is described by graphs.

Spektral implements some of the most popular layers for graph deep learning, including:

You can also find pooling layers (including global readouts and graph coarsening layers), and lots of utilities to apply graph deep learning in your projects.

See how to get started with Spektral and have a look at the examples for some project templates.

The source code of the project is available on Github.
Read the documentation here.

Installation

Spektral is compatible with Python 3.5+, and is tested on Ubuntu 16.04 and 18.04. Other Linux distros and MacOS should work as well, but Windows is not supported for now.

To install the required dependencies on Ubuntu run:

$ sudo apt install graphviz libgraphviz-dev libcgraph6

Some features of Spektral also require the following optional dependencies:

  • RDKit, a library for cheminformatics and molecule manipulation (available through Anaconda);
  • dyfunconn, a library to build functional connectivity networks (available through PyPi);

The simplest way to install Spektral is from PyPi:

$ pip install spektral

To install Spektral from source, run this in a terminal:

$ git clone https://github.com/danielegrattarola/spektral.git
$ cd spektral
$ python setup.py install  # Or 'pip install .'

Note that the setup.py script will not attempt to install a backend for Keras, in order to not mess up any previous installation. It will, however, install Keras and its dependencies via PyPi (which may include the CPU version of TensorFlow).
If you are already a Keras user, this should not impact you. If you're just getting started, then you may want to install the GPU version of Tensorflow before installing Spektral.

Also note that some features of Spektral may depend explicitly on TensorFlow, although this dependency will be kept to a minimum.

Contributing

WARNING
Spektral is still a work in progress and may change significantly before the first release. The API is not mature enough to be considered stable, but we'll try to keep breaking changes to a minimum.

Spektral is an open source project available on Github, and contributions of all types are welcome. Feel free to open a pull request if you have something interesting that you want to add to the framework.

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

spektral-0.0.12.tar.gz (48.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

spektral-0.0.12-py3-none-any.whl (58.7 kB view details)

Uploaded Python 3

File details

Details for the file spektral-0.0.12.tar.gz.

File metadata

  • Download URL: spektral-0.0.12.tar.gz
  • Upload date:
  • Size: 48.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.5.2

File hashes

Hashes for spektral-0.0.12.tar.gz
Algorithm Hash digest
SHA256 4955b86b7e8e4a3df5ac125aa9c8b860f940d626305708489cda5c9ba2e6008d
MD5 f4ca2a246dc86e03a0f2ca4ce95d360b
BLAKE2b-256 7160f469cbbd54c475f62e8b668cad56b7b4900d7249d76b0f1269e525974c69

See more details on using hashes here.

File details

Details for the file spektral-0.0.12-py3-none-any.whl.

File metadata

  • Download URL: spektral-0.0.12-py3-none-any.whl
  • Upload date:
  • Size: 58.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.5.2

File hashes

Hashes for spektral-0.0.12-py3-none-any.whl
Algorithm Hash digest
SHA256 cff435dccabc9caa67376f2d6a46d55e117c9fafb60434f8a979b6310219be51
MD5 c67e94bb6446be2053830e37fd0df9a3
BLAKE2b-256 31d8c4e6c207fdcda9570be035ec1644ece3c47ad2309ea6d6c65e17c067b4a1

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