Initial commit
Some checks failed
Docker Build and Push / docker (push) Failing after 2m10s

This commit is contained in:
4paradigm
2026-07-24 15:17:23 +08:00
commit 780b5e1ff4
1445 changed files with 216416 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
try:
import torch as _torch
except ImportError:
_torch = None
class TorchWrapper:
"""
Helps in making torch an optional dependency
"""
def __getattr__(self, name):
if _torch is None:
raise ImportError("Triton requires PyTorch to be installed")
return getattr(_torch, name)
torch = TorchWrapper()