mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Add "xpu" to __all__ for torch/version.py (#149695)
As the title stated. Pull Request resolved: https://github.com/pytorch/pytorch/pull/149695 Approved by: https://github.com/desertfire, https://github.com/guangyey
This commit is contained in:
@ -97,7 +97,9 @@ if __name__ == "__main__":
|
||||
|
||||
with open(version_path, "w") as f:
|
||||
f.write("from typing import Optional\n\n")
|
||||
f.write("__all__ = ['__version__', 'debug', 'cuda', 'git_version', 'hip']\n")
|
||||
f.write(
|
||||
"__all__ = ['__version__', 'debug', 'cuda', 'git_version', 'hip', 'xpu']\n"
|
||||
)
|
||||
f.write(f"__version__ = '{version}'\n")
|
||||
# NB: This is not 100% accurate, because you could have built the
|
||||
# library code with DEBUG, but csrc without DEBUG (in which case
|
||||
|
Reference in New Issue
Block a user