Python package built to ease deep learning on graph, on top of existing DL frameworks.
v0.9.1 is a minor release with the following update:
DGL now supports partitioning and preprocessing graph data using multiple machines. At its core is a new data format called Chunked Graph Data Format (CGDF) which stores graph data by chunks. The new pipeline processes data chunks in parallel which not only reduces the memory requirement of each machine but also significantly accelerates the entire procedure. For the same random graph with 1B nodes/5B edges, using a cluster of 8 AWS EC2 x1e.4xlarge (16 vCPU, 488GB RAM each), the new pipeline can reduce the running time to 2.7 hours and cut down the money cost by 3.7x. Read the feature highlight blog for more details.
To get started with this new feature, check out the new user guide chapter.
dgl/examples/pytorch/multigpu/
. With a new example of multi-GPU graph property prediction that can achieve 9.5x speedup on 8 GPUs. (#4385)dgl.use_libxsmm
and dgl.is_libxsmm_enabled
to enable/disable Intel LibXSMM. (#4455)exclude_self
to exclude self-loop edges for dgl.knn_graph
. The API now supports creating a batch of KNN graphs. (#4389)AsyncTransferer
class. The functionality has been incorporated to DGL DataLoader. (#4505)num_servers
and num_workers
arguments of dgl.distributed.initialize
. (#4284)Starting from this release, we will drop support for CUDA 10.1 and 11.0. On windows, we will further drop support for CUDA 10.2.
Linux: CentOS 7+ / Ubuntu 18.04+
PyTorch ver. \ CUDA ver. | 10.2 | 11.1 | 11.3 | 11.5 | 11.6 |
---|---|---|---|---|---|
1.9 | ✅ | ✅ | |||
1.10 | ✅ | ✅ | ✅ | ||
1.11 | ✅ | ✅ | ✅ | ✅ | |
1.12 | ✅ | ✅ | ✅ |
Windows: Windows 10+/Windows server 2016+
PyTorch ver. \ CUDA ver. | 11.1 | 11.3 | 11.5 | 11.6 |
---|---|---|---|---|
1.9 | ✅ | |||
1.10 | ✅ | ✅ | ||
1.11 | ✅ | ✅ | ✅ | |
1.12 | ✅ | ✅ |
num_bases
in RelGraphConv module (#4321)This is a major update with several new features including graph prediction pipeline in DGL-Go, cuGraph support, mixed precision support, and more.
Starting from 0.9 we also ship arm64 builds for Linux and OSX.
DGL-Go now supports training GNNs for graph property prediction tasks. It includes two popular GNN models – Graph Isomorphism Network (GIN) and Principal Neighborhood Aggregation (PNA). For example, to train a GIN model on the ogbg-molpcba dataset, first generate a YAML configuration file using command:
dgl configure graphpred --data ogbg-molpcba --model gin
which generates the following configuration file. Users can then manually adjust the configuration file.
version: 0.0.2
pipeline_name: graphpred
pipeline_mode: train
device: cpu # Torch device name, e.g., cpu or cuda or cuda:0
data:
name: ogbg-molpcba
split_ratio: # Ratio to generate data split, for example set to [0.8, 0.1, 0.1] for 80% train/10% val/10% test. Leave blank to use builtin split in original dataset
model:
name: gin
embed_size: 300 # Embedding size
num_layers: 5 # Number of layers
dropout: 0.5 # Dropout rate
virtual_node: false # Whether to use virtual node
general_pipeline:
num_runs: 1 # Number of experiments to run
train_batch_size: 32 # Graph batch size when training
eval_batch_size: 32 # Graph batch size when evaluating
num_workers: 4 # Number of workers for data loading
optimizer:
name: Adam
lr: 0.001
weight_decay: 0
lr_scheduler:
name: StepLR
step_size: 100
gamma: 1
loss: BCEWithLogitsLoss
metric: roc_auc_score
num_epochs: 100 # Number of training epochs
save_path: results # Directory to save the experiment results
Alternatively, users can fetch model recipes of pre-defined hyperparameters for the original experiments.
dgl recipe get graphpred_pcba_gin.yaml
To launch training:
dgl train --cfg graphpred_ogbg-molpcba_gin.yaml
Another addition is a new command to conduct inference of a trained model on some other dataset. For example, the following shows how to apply the GIN model trained on ogbg-molpcba
to ogbg-molhiv
.
# Generate an inference configuration file from a saved experiment checkpoint
dgl configure-apply graphpred --data ogbg-molhiv --cpt results/run_0.pth
# Apply the trained model for inference
dgl apply --cfg apply_graphpred_ogbg-molhiv_pna.yaml
It will save the model prediction in a CSV file like below
DGL is compatible with the PyTorch Automatic Mixed Precision (AMP) package for mixed precision training, thus saving both training time and GPU memory consumption. This feature requires PyTorch 1.6+ and Python 3.7+.
By wrapping the forward pass with torch.cuda.amp.autocast()
, PyTorch automatically selects the appropriate data type for each op and tensor. Half precision tensors are memory efficient, most operators on half precision tensors are faster as they leverage GPU tensorcores.
import torch.nn.functional as F
from torch.cuda.amp import autocast
def forward(g, feat, label, mask, model):
with autocast(enabled=True):
logit = model(g, feat)
loss = F.cross_entropy(logit[mask], label[mask])
return loss
Small gradients in float16
format have underflow problems (flush to zero). PyTorch provides a GradScaler
module to address this issue. It multiplies the loss by a factor and invokes backward pass on the scaled loss to prevent the underflow problem. It then unscales the computed gradients before the optimizer updates the parameters. The scale factor is determined automatically.
from torch.cuda.amp import GradScaler
scaler = GradScaler()
def backward(scaler, loss, optimizer):
scaler.scale(loss).backward()
scaler.step(optimizer)
scaler.update()
Putting everything together, we have the example below.
import torch
import torch.nn as nn
from dgl.data import RedditDataset
from dgl.nn import GATConv
from dgl.transforms import AddSelfLoop
class GAT(nn.Module):
def __init__(self, in_feats, num_classes, num_hidden=256, num_heads=2):
super().__init__()
self.conv1 = GATConv(in_feats, num_hidden, num_heads, activation=F.elu)
self.conv2 = GATConv(num_hidden * num_heads, num_hidden, num_heads)
def forward(self, g, h):
h = self.conv1(g, h).flatten(1)
h = self.conv2(g, h).mean(1)
return h
device = torch.device('cuda')
transform = AddSelfLoop()
data = RedditDataset(transform)
g = data[0]
g = g.int().to(device)
train_mask = g.ndata['train_mask']
feat = g.ndata['feat']
label = g.ndata['label']
in_feats = feat.shape[1]
model = GAT(in_feats, data.num_classes).to(device)
model.train()
optimizer = torch.optim.Adam(model.parameters(), lr=1e-3, weight_decay=5e-4)
for epoch in range(100):
optimizer.zero_grad()
loss = forward(g, feat, label, train_mask, model)
backward(scaler, loss, optimizer)
Thanks @nv-dlasalle @ndickson-nvidia @yaox12 etc. for support!
The RAPIDS cuGraph library provides a collection of GPU accelerated algorithms for graph analytics, such as centrality computation and community detection. According to its documentation, “the latest NVIDIA GPUs (RAPIDS supports Pascal and later GPU architectures) make graph analytics 1000x faster on average over NetworkX”.
To install cuGraph, we recommend following the practice below.
conda install mamba -n base -c conda-forge
mamba create -n dgl_and_cugraph -c dglteam -c rapidsai-nightly -c nvidia -c pytorch -c conda-forge cugraph pytorch torchvision torchaudio cudatoolkit=11.3 dgl-cuda11.3 tqdm
conda activate dgl_and_cugraph
DGL now supports compatibility with cuGraph by allowing conversion between a DGLGraph object and a cuGraph graph object, making it possible for DGL users to access efficient graph analytics implementations in cuGraph. For example, users can perform community detection on a graph with the Louvain method available in cuGraph.
import cugraph
from dgl.data import CoraGraphDataset
dataset = CoraGraphDataset()
g = dataset[0].to('cuda')
cugraph_g = g.to_cugraph()
cugraph_g = cugraph_g.to_undirected()
parts, modularity_score = cugraph.louvain(cugraph_g)
The community membership of nodes from parts['partition']
can then be used as auxiliary node labels or node features.
If you have modified the structure of a cuGraph graph object or loaded graph data with cuGraph, you can also convert it to a DGLGraph object.
import dgl
g = dgl.from_cugraph(cugraph_g)
Credits to @VibhuJawa!
Linux AArch64 and OSX M1 (arm64) are now supported. One can install them as usual with pip
and conda
:
pip install dgl-cuXX -f https://data.dgl.ai/wheels/repo.html
conda install -c dglteam dgl-cudaXX.X # currently not available for OSX M1
deferred_dtype
missing error (#4174, @nv-dlasalle )graph
attribute missing in DataLoader when device is not specified (#4245)retain_graph
being set (#4078) (#4249)This is a minor release with the following updates.
A 0.8.2 test build for AArch64 is available in
pip install dgl -f https://data.dgl.ai/wheels-test/repo.html # or dgl-cuXX for CUDA
dgl.transforms.FeatMask
for randomly dropping out dimensions of all node/edge features (#3968, @RecLusIve-F)dgl.transforms.RowFeatNormalizer
for normalization of all node/edge features (#3968, @RecLusIve-F)dgl.transforms.SIGNDiffusion
for augmenting input node features (#3982)HeteroLinear
with/without bias (#3970, @ksadowski13)dgl.transforms.functional
(#3890, @ndickson-nvidia)in_edges
/out_edges
on empty graphs (#4050)curandState
and launch dimension of GPU neighbor sampling kernel (#3990, @paoxiaode)This is a minor release that includes the following model updates, optimizations, new features and bug fixes.
nn.GroupRevRes
from Training Graph Neural Networks with 1000 layers [#3842]transforms.LaplacianPositionalEncoding
from Graph Neural Networks with Learnable Structural and Positional Representations [#3869]transforms.RWPositionalEncoding
from Graph Neural Networks with Learnable Structural and Positional Representations [#3869]dataloading.SAINTSampler
from GraphSAINT [#3879]nn.EGNNConv
from E(n) Equivariant Graph Neural Networks [#3901]nn.PNAConv
from the baselines of E(n) Equivariant Graph Neural Networks [#3901]torch.cdist
so the space complexity is O(N^2).get_attention
parameter in GlobalAttentionPooling
. [#3837 @decoherencer]stacklevel=2
for DGL-raised warnings. [#3816]shuffle=False
[#3892]This is a bugfix release including the following bugfixes:
pip install dgl-cu115 -f https://data.dgl.ai/wheels/repo.html # if using pip
conda install dgl-cuda11.5 -c dglteam # if using conda
torch.distributed.algorithms.join.Join
to deal with uneven training sets in distributed training (#3870)This is a quick post-release with critical bug fixes:
v0.8.0 is a major release with many new features, system improvement and fixes. Read the blog for the highlighted features.
Enabled CUDA UVA-based optimization and feature prefetching for all built-in graph samplers (up to 4x speedup compared to v0.7). Users can now specify the features to prefetch and turn on UVA optimization in dgl.dataloading.Sampler
and dgl.dataloading.DataLoader
.
g = ... # some DGLGraph data
train_nids = ... # training node IDs
sampler = dgl.dataloading.MultiLayerNeighborSampler(
fanout=[10, 15],
prefetch_node_feats=['feat'], # prefetch node feature 'feat'
prefetch_labels=['label'], # prefetch node label 'label'
)
dataloader = dgl.dataloading.DataLoader(
g, train_nids, sampler,
device='cuda:0', # perform sampling on GPU 0
batch_size=1024,
shuffle=True,
use_uva=True # turn on UVA optimization
)
We have done a major refactor on the sampling components to make it easier to implement new graph samplers. Added a new base class dgl.dataloading.Sampler
with one abstract method sample for overriding. Added new APIs dgl.set_src_lazy_features
, dgl.set_dst_lazy_features
, dgl.set_node_lazy_features
, dgl.set_edge_lazy_features
for customizing prefetching rules. The code below shows the new user experience.
class NeighborSampler(dgl.dataloading.Sampler):
def __init__(self,
fanouts : list[int],
prefetch_node_feats: list[str] = None,
prefetch_edge_feats: list[str] = None,
prefetch_labels: list[str] = None):
super().__init__()
self.fanouts = fanouts
self.prefetch_node_feats = prefetch_node_feats
self.prefetch_edge_feats = prefetch_edge_feats
self.prefetch_labels = prefetch_labels
def sample(self, g, seed_nodes):
output_nodes = seed_nodes
subgs = []
for fanout in reversed(self.fanouts):
# Sample a fixed number of neighbors of the current seed nodes.
sg = g.sample_neighbors(seed_nodes, fanout)
# Convert this subgraph to a message flow graph.
sg = dgl.to_block(sg, seed_nodes)
seed_nodes = sg.srcdata[NID]
subgs.insert(0, sg)
input_nodes = seed_nodes
# handle prefetching
dgl.set_src_lazy_features(subgs[0], self.prefetch_node_feats)
dgl.set_dst_lazy_features(subgs[-1], self.prefetch_labels)
for subg in subgs:
dgl.set_edge_lazy_features(subg, self.prefetch_edge_feats)
return input_nodes, output_nodes, subgs
Related documentations:
We thank Xin Yao (@yaox12 ) and Dominique LaSalle (@nv-dlasalle ) from NVIDIA and David Min (@davidmin7 ) from UIUC for their contributions.
DGL-Go is a new command line tool for users to get started with training, using and studying Graph Neural Networks (GNNs). Data scientists can quickly apply GNNs to their problems, whereas researchers will find it useful to customize their experiments.
The initial release include
dgl train
, dgl recipe
, dgl configure
and dgl export
.We have accelerated dgl.nn.RelGraphConv
and dgl.nn.HGTConv
by up to 36x and 12x compared with the baselines from v0.7 and PyG. Shortened the implementation of dgl.nn.RelGraphConv
by 3x (from 200L → 64L).
Breaking change: dgl.nn.RelGraphConv
no longer accepts 1-D integer tensor representing node IDs during forward. Please switch to torch.nn.Embedding
to explicitly represent trainable node embeddings.
Below are the new NN modules added to v0.8:
GATv2Conv
: GATv2 from How Attentive are Graph Attention Networks?
EGATConv
: Graph attention layer that handles edge features from Rossmann-Toolbox
EdgePredictor
: Predictor/score function for pairs of node representationsTransE
: Similarity measure from Translating Embeddings for Modeling Multi-relational Data
TransR
: Similarity measure from Learning entity and relation embeddings for knowledge graph completion
HeteroLinear
: Apply linear transformations on heterogeneous inputs.HeteroEmbedding
: Create a heterogeneous embedding table.HGTConv
: Heterogeneous graph transformer convolution from Heterogeneous Graph Transformer
TypedLinear
: Linear transformation according to types.JumpingKnowledge
: The Jumping Knowledge aggregation module from Representation Learning on Graphs with Jumping Knowledge Networks
GNNExplainer
: GNNExplainer model from GNNExplainer: Generating Explanations for Graph Neural Networks
A new edge_weight
argument is added to several GNN modules to support training on weighted graph. Added a new user guide chapter 5.5 about how to use edge weights in your GNN model.
Rename the old dgl.transform
package to dgl.transforms
to follow PyTorch’s namespace convention. All DGL’s datasets now accept an extra transforms keyword argument for data augmentation and transformation:
import dgl
import dgl.transforms as T
t = T.Compose([
T.AddSelfLoop(),
T.GCNNorm(),
])
dataset = dgl.data.CoraGraphDataset(transform=t)
g = dataset[0] # graph and features will be transformed automatically
Added 16 graph data transforms module:
Compose
: Create a transform composed of multiple transforms in sequence.AddSelfLoop
: Add self-loops for each node in the graph and return a new graph.RemoveSelfLoop
: Remove self-loops for each node in the graph and return a new graph.AddReverse
: Add a reverse edge (i,j) for each edge (j,i) in the input graph and return a new graph.ToSimple
: Convert a graph to a simple graph without parallel edges and return a new graph.LineGraph
: Return the line graph of the input graph.KHopGraph
: Return the graph whose edges connect the k-hop neighbors of the original graph.AddMetaPaths
: Add new edges to an input graph based on given metapaths, as described in Heterogeneous Graph Attention Network.GCNNorm
: Apply symmetric adjacency normalization to an input graph and save the result edge weights, as described in Semi-Supervised Classification with Graph Convolutional Networks.PPR
: Apply personalized PageRank (PPR) to an input graph for diffusion, as introduced in The pagerank citation ranking: Bringing order to the web.HeatKernel
: Apply heat kernel to an input graph for diffusion, as introduced in Diffusion kernels on graphs and other discrete structures.GDC
: Apply graph diffusion convolution (GDC) to an input graph, as introduced in Diffusion Improves Graph Learning.NodeShuffle
: Randomly shuffle the nodes.DropNode
: Randomly drop nodes, as described in Graph Contrastive Learning with Augmentations.DropEdge
: Randomly drop edges, as described in DropEdge: Towards Deep Graph Convolutional Networks on Node Classification and Graph Contrastive Learning with Augmentations.AddEdge
: Randomly add edges, as described in Graph Contrastive Learning with Augmentations.Added several dataset utilities:
dgl.data.CSVDataset
: A new dataset for loading and parsing graph data stored in CSV format. Added a new user guide chapter about how to prepare CSV data and use this dataset.dgl.data.AsNodePredDataset
: Repurpose a dataset for a standard semi-supervised transductive node prediction task.dgl.data.AsLinkPredDataset
: Repurpose a dataset for link prediction task.dgl.data.utils.add_nodepred_split
: Split the given dataset into training, validation and test sets for transductive node prediction task.A major rework of two classical examples:
7 new examples:
GNNLens is an interactive visualization tool for graph neural networks (GNN). It integrates GNN explanation model to analyze and understand graph data. See the repository here: https://github.com/dmlc/gnnlens2
DistGraph
to dgl.dataloading.NodeDataLoader
will cause an error. Please use dgl.dataloading.DistNodeDataLoader
instead.dgl.sample_etype_neighbors
now works for DistGraph
. #3558dgl.ops.segment_mm
: An operator to perform matrix multiplication according to segments.dgl.ops.gather_mm
: An operator to perform matrix multiplication according to look-up indices.dgl.merge
: Merge a sequence of graphs together into a single one. @noncomputable #3522dgl.dataloading.GlobalUniform
: A negative sampler that draws negative samples uniformly from all nodes. #3599dgl.DGLGraph.pin_memory_
, dgl.DGLGraph.unpin_memory_
and dgl.DGLGraph.is_pinned
to pin, unpin and check a DGLGraph
to page-locked memory.dgl.edge_softmax
. @ranzhejiang #3650dgl.node_subgraph
, dgl.in_subgraph
, dgl.in_edges
by several orders of magnitudes. @ayasar70, #3745dgl.reorder_graph
supports reordering edges according to user-provided permutation.This is a patch release targeting CUDA 11.3 and PyTorch 1.10. It contains (1) distributed training on heterogeneous graphs, and (2) bug fixes and code reorganization commits. The performance impact should be minimal.
To install with CUDA 11.3 support, run either
pip install dgl-cu113 -f https://data.dgl.ai/wheels/repo.html
or
conda install -c dglteam dgl-cuda11.3
We have made the interface of distributed sampling on heterogeneous graph consistent with single-machine code. Please refer to https://github.com/dmlc/dgl/blob/0.7.x/examples/pytorch/rgcn/experimental/entity_classify_dist.py for the new code.
dgl.broadcast_nodes
(#3351, @jwyyy)0.7.1 is a minor release with multiple fixes and a few new models/features/optimizations included as follows.
Note: We noticed that 0.7.1 for Linux is unavailable on our anaconda repository. We are currently working on this issue. For now, please use pip installation instead.
tools/launch.py
(#3202, @erickim555)tools/launch.py
(#3205, @erickim555)DGLDEFAULTDIR
(#3277, @konstantino)dgl.DGLGraph
and dgl.graph
(#3198)DGL_LOADALL
in doc builds (#3150, @lululxvi)random_walk
documentation inconsistency (#3188)curand_init()
calls in rowwise sampling leading to not-so-random results (#3196, @nv-dlasalle)force_reload
parameter of FraudDataset
(#3210, @Orion-wyc)num_workers
for using ScalarDataBatcher
(#3219, @nv-dlasalle)DotGatConv
attention bug when computing edge_softmax
(#3272, @Flawless1202)RelGraphConv
reshape argument is incorrect (#3256, @minchenGrab)This is a new major release with various system optimizations, new features and enhancements, new models and bugfixes.
DGL pip wheels are no longer shipped on PyPI. Use the following command to install DGL with pip:
pip install dgl -f https://data.dgl.ai/wheels/repo.html
for CPU.pip install dgl-cuXX -f https://data.dgl.ai/wheels/repo.html
for CUDA.pip install --pre dgl -f https://data.dgl.ai/wheels-test/repo.html
for CPU nightly builds.pip install --pre dgl-cuXX -f https://data.dgl.ai/wheels-test/repo.html
for CUDA nightly builds.This does not impact conda installation.
DGL now supports uniform neighbor sampling and MFG conversion on GPU, contributed by @nv-dlasalle from NVIDIA. Experiment for GraphSAGE on the ogbn-product graph gets a >10x speedup (reduced from 113s to 11s per epoch) on a g3.16x instance. The following docs have been updated accordingly:
The release brings two new tutorials about multi-GPU training for node classification and graph classification, respectively. There is also a new tutorial about distributed training across multiple machines. All of them are available at https://docs.dgl.ai/.
The update includes a new CPU implementation of the core GSpMM kernel for GNN message passing, thanks to @sanchit-misra from Intel. The new kernel performs tiling on the sparse CSR matrix and leverages Intel’s LibXSMM for kernel generation, which gives an up to 4.4x speedup over the old kernel. Please read their paper https://arxiv.org/abs/2104.06700 for details.
DGL now utilizes NCCL to synchronize the gradients of sparse node embeddings (dgl.nn.NodeEmbedding
) during training (credits to @nv-dlasalle from NVIDIA). The NCCL feature is available in both dgl.optim.SparseAdam
and dgl.optim.SparseAdagrad
. Experiments show a 20% speedup (reduced from 47.2s to 39.5s per epoch) on a g4dn.12xlarge (4 T4 GPU) instance for training RGCN on ogbn-mag graph. The optimization is automatically turned on when NCCL backend support is detected.
The sparse optimizers for dgl.distributed.DistEmbedding
now use a synchronized gradient update strategy. We add a new optimizer dgl.distributed.optim.SparseAdam
. The dgl.distributed.SparseAdagrad
has been moved to dgl.distributed.optim.SparseAdagrad
.
We add two new APIs dgl.adj_product_graph
and dgl.adj_sum_graph
that perform sparse-sparse matrix multiplications and additions as graph operations respectively. They can run with both CPU and GPU with autograd support. An example usage of these functions is Graph Transformer Networks.
DGL is now compatible with PyTorch Lightning for single-GPU training or training with DistributedDataParallel. See this example of training GraphSAGE with PyTorch Lightning.
We thank @justusschock for making DGL DataLoaders compatible with PyTorch Lightning (#2886).
A batch of 19 new model examples are added to DGL in 0.7 bringing the total number to be 90+. Users can now use the search bar on https://www.dgl.ai/ to quickly locate the examples with tagged keywords. Below is the list of new models added.
dgl.sample_neighbors_biased
for biased neighbor sampling where each node has a tag, and each tag has its own (unnormalized) probability (#1665, #2987, @soodoshll). We also provide two helper functions sort_csr_by_tag
and sort_csc_by_tag
to sort the internal storage of a graph based on tags to allow such kind of neighbor sampling (#1664, @soodoshll).multi_update_all
now supports user-defined cross-type reducers (#2891, @Secbone)in_degrees
and out_degrees
supports to dgl.DistGraph
(#2918)dgl.sampling.node2vec_random_walk
for Node2vec random walks (#2992, @Smilexuhc)dgl.node_subgraph
, dgl.edge_subgraph
, dgl.in_subgraph
and dgl.out_subgraph
all have a relabel_nodes
argument to allow graph compaction (i.e. removing the nodes with no edges). (#2929)NodeEmbedding.all_set_embedding()
(#3047)dgl.graph
for more details.dgl.reorder
API to permute a graph according to RCMK, METIS or custom strategy (#3063)dgl.nn.GraphConv
now has a left normalization which divides the outgoing messages by out-degrees, equivalent to random-walk normalization (#3114)exclude='self'
to EdgeDataLoader to exclude the edges sampled in the current minibatch alone during neighbor sampling when reverse edges are not available (#3122)IsNullArray
overheads in random walks (#2990, @AjayBrahmakshatriya)node_split
and edge_split
during partitioning (#3132, @JingchengYu94)idx_list
out of bound (#2848)dgl.multiprocessing
namespace for multiprocess training with fork and OpenMP (#2905)to_heterogeneous(to_homogeneous(hg))
now returns the same hg
. (#2958)remove_nodes
and remove_edges
now preserves batch information. (#3119)__len__
method to stop polluting PyCharm outputs (#2902)load_partition
(#2742, @chwan-rice)NodeDataLoader
and EdgeDataLoader
now supports DistributedDataParallel
with proper shuffling and batching (#2539, #2911)bipartite_from_networkx()
(#2808, #2917)dgl.to_homogenous
doesn't work correctly on graphs with 0 nodes of a given type (#2870, #3011)num_layers
equals 1 for GraphSAGE (#3066, @Wang-Yu-Qing)preserve_nodes
argument in dgl.edge_subgraph
is deprecated and renamed to relabel_nodes
.