Skip to content

Commit

Permalink
[DistDGL] back-compatible with dgl.dataloading (#7817)
Browse files Browse the repository at this point in the history
  • Loading branch information
Rhett-Ying authored Oct 6, 2024
1 parent adbefc6 commit 0dc0d57
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions python/dgl/dataloading/dataloader.py
Original file line number Diff line number Diff line change
Expand Up @@ -1502,6 +1502,16 @@ def __new__(cls, *args, **kwargs):
return NewEdgeCollator(*args, **kwargs)


def _remove_kwargs_dist(kwargs):
"""Deprecated."""
if "num_workers" in kwargs:
del kwargs["num_workers"]
if "pin_memory" in kwargs:
del kwargs["pin_memory"]
print("Distributed DataLoaders do not support pin_memory.")
return kwargs


class DistDataLoader:
"""Deprecated. Please use :class:`~dgl.distributed.DistDataLoader` instead."""

Expand Down

0 comments on commit 0dc0d57

Please sign in to comment.