"docs/source/api/python/dgl.data.rst" did not exist on "967ecb8064aa4058820fae430a824e164f086204"
Unverified Commit 894ae31f authored by Rhett Ying's avatar Rhett Ying Committed by GitHub
Browse files

[DistDGL] keep net_type in public API even it is deprecated (#5875)

parent add152bf
...@@ -12,7 +12,7 @@ import traceback ...@@ -12,7 +12,7 @@ import traceback
from enum import Enum from enum import Enum
from .. import utils from .. import utils
from ..base import DGLError from ..base import dgl_warning, DGLError
from . import rpc from . import rpc
from .constants import MAX_QUEUE_SIZE from .constants import MAX_QUEUE_SIZE
from .kvstore import close_kvstore, init_kvstore from .kvstore import close_kvstore, init_kvstore
...@@ -208,6 +208,7 @@ class CustomPool: ...@@ -208,6 +208,7 @@ class CustomPool:
def initialize( def initialize(
ip_config, ip_config,
max_queue_size=MAX_QUEUE_SIZE, max_queue_size=MAX_QUEUE_SIZE,
net_type=None,
num_worker_threads=1, num_worker_threads=1,
): ):
"""Initialize DGL's distributed module """Initialize DGL's distributed module
...@@ -226,6 +227,8 @@ def initialize( ...@@ -226,6 +227,8 @@ def initialize(
Note that the 20 GB is just an upper-bound and DGL uses zero-copy and Note that the 20 GB is just an upper-bound and DGL uses zero-copy and
it will not allocate 20GB memory at once. it will not allocate 20GB memory at once.
net_type : str, optional
[Deprecated] Networking type, can be 'socket' only.
num_worker_threads: int num_worker_threads: int
The number of OMP threads in each sampler process. The number of OMP threads in each sampler process.
...@@ -235,6 +238,10 @@ def initialize( ...@@ -235,6 +238,10 @@ def initialize(
distributed API. For example, when used with Pytorch, users have to invoke this function distributed API. For example, when used with Pytorch, users have to invoke this function
before Pytorch's `pytorch.distributed.init_process_group`. before Pytorch's `pytorch.distributed.init_process_group`.
""" """
if net_type is not None:
dgl_warning(
"net_type is deprecated and will be removed in future release."
)
if os.environ.get("DGL_ROLE", "client") == "server": if os.environ.get("DGL_ROLE", "client") == "server":
from .dist_graph import DistGraphServer from .dist_graph import DistGraphServer
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment