mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-21 21:49:24 +08:00
Summary: Implementing #10540. Pull Request resolved: https://github.com/pytorch/pytorch/pull/11515 Reviewed By: apaszke Differential Revision: D9771045 Pulled By: jeffreyksmithjr fbshipit-source-id: 85ea39abaa9b465805a969f122b626b11fc85ef6
9 lines
164 B
Python
9 lines
164 B
Python
from six import PY2, PY3
|
|
|
|
if PY2:
|
|
import collections
|
|
container_abcs = collections
|
|
elif PY3:
|
|
import collections.abc
|
|
container_abcs = collections.abc
|