зеркало из https://github.com/microsoft/DeepSpeed.git
Revert "Revert "Fix torch check (#6402)""
This reverts commit 77f61e6771
.
This commit is contained in:
Родитель
77f61e6771
Коммит
eb37cacf22
|
@ -36,7 +36,13 @@ class GDSBuilder(AsyncIOBuilder):
|
|||
return super().extra_ldflags() + ['-lcufile']
|
||||
|
||||
def is_compatible(self, verbose=False):
|
||||
try:
|
||||
import torch.utils.cpp_extension
|
||||
except ImportError:
|
||||
if verbose:
|
||||
self.warning("Please install torch if trying to pre-compile GDS")
|
||||
return False
|
||||
|
||||
CUDA_HOME = torch.utils.cpp_extension.CUDA_HOME
|
||||
CUDA_LIB64 = os.path.join(CUDA_HOME, "lib64")
|
||||
gds_compatible = self.has_function(funcname="cuFileDriverOpen",
|
||||
|
|
Загрузка…
Ссылка в новой задаче