The GraphList
class is a data structure to efficiently store homogeneous graph data.
What is homogeneous graph data?
In homogeneous graph datasets all nodes, edges and graph attributes are of the same shape and type across the dataset.
In a machine learning setting (e.g. graph neural networks) this is a common restriction on the data.
The GraphList
data structure expoits this restriction to store data more efficiently (less python objects, less numpy arrays).
- Importing data from
networkx
graphs - Indexing graph datasets with...
- integer indices (
graphs[42]
) - list of integer indices (
graphs[[3,5,7]]
) - slices (
graphs[3:9]
)
- integer indices (
- Persisting data to disk (with HDF5)
- Writing, appending and reading from HDF5 files
- lazily read data from disk
- Dtype Support
- All common numerical values (see numpy types)
- Strings
> git clone https://github.com/robinruff/graphlist
> cd graphlist
> pip install .
See example_code.py
This library is inspired by jraphs GraphsTuple
implementation.
Dependencies: