(Distributed) Graph Flow (GF) is a Python toolkit to develop and deploy Graph Neural Network (GNN) models.
For more information, check the documentation at https://dgf.readthedocs.io/
This is not an officially supported Google product. This project is not eligible for the Google Open Source Software Vulnerability Rewards Program.
To install YDF from PyPI, run:
pip install dgf -UCurrently, DGF is available on Python 3.11-13, on Linux x86-64.
# Temporary fix for Keras dependency.
import os
os.environ["TF_USE_LEGACY_KERAS"] = "1"
# Import (distributed) graph flow
import dgf
# Fetch an example graph
graph, schema = dgf.io.fetch_ogb_graph("arxiv")
# Train a model
model = dgf.learning.train_node_model(graph=graph, schema=schema, target_column="labels")
# Look at the model
model.describe()
# Evaluate the model
model.evaluate()
# Make predictions
model.predict(graph, seed_node_idxs=[0, 1, 2])
# Save the model for later
model.save("/tmp/model")