mirror of
https://github.com/zebrajr/pytorch.git
synced 2025-12-06 12:20:52 +01:00
Revert "[c10d] Add hccl distributed backend to c10d data structures (#146478)"
This reverts commitdae3fbfe97. Reverted https://github.com/pytorch/pytorch/pull/146478 on behalf of https://github.com/malfet due to This seems to break ROCM tests, seedae3fbfe97([comment](https://github.com/pytorch/pytorch/pull/146478#issuecomment-2692913573))
This commit is contained in:
parent
1106eb0212
commit
94afb165d9
|
|
@ -331,12 +331,18 @@ class Backend(str): # noqa: SLOT000
|
|||
.. note:: This support of 3rd party backend is experimental and subject to change.
|
||||
|
||||
"""
|
||||
# This takes care of CUSTOM Out-of-tree backend types, update in backend_list indicates availability
|
||||
if not hasattr(Backend, name.upper()):
|
||||
setattr(Backend, name.upper(), name.lower())
|
||||
if name.lower() not in Backend.backend_list:
|
||||
Backend.backend_list.append(name.lower())
|
||||
# Allow UCC plugin if Pytorch is not built with native support.
|
||||
# TODO: remove this exception once UCC plugin is fully deprecated.
|
||||
if name != Backend.UCC or (name == Backend.UCC and is_ucc_available()):
|
||||
assert not hasattr(Backend, name.upper()), (
|
||||
f"{name.upper()} c10d backend already exist"
|
||||
)
|
||||
assert name.upper() not in Backend._plugins, (
|
||||
f"{name.upper()} c10d backend creator function already exist"
|
||||
)
|
||||
|
||||
setattr(Backend, name.upper(), name.lower())
|
||||
Backend.backend_list.append(name.lower())
|
||||
if devices is not None:
|
||||
for device in devices:
|
||||
if device != "cpu" and device != "cuda":
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user