Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 17 additions & 2 deletions src/tilegym/ops/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,19 @@
# Import interface modules
from . import activation
from . import attn_interface
from . import cutile

# Make cutile optional - only import if backend is fully available
if is_backend_available("cutile"):
try:
from . import cutile
except (ImportError, RuntimeError):
import warnings

warnings.warn("Cutile backend import failed, cutile operations will not be available")
cutile = None # type: ignore
else:
cutile = None # type: ignore

from . import moe_interface

# Re-export key interfaces
Expand All @@ -26,7 +38,6 @@
__all__ = [
# Export all operations from ops module
# Backend implementations
"cutile",
# Interface modules
"attn_interface",
"moe_interface",
Expand All @@ -38,3 +49,7 @@
"mla_decoding_interface",
"fused_moe_kernel_interface",
]

# Add cutile to exports only if successfully imported
if cutile is not None:
__all__.append("cutile")
1 change: 1 addition & 0 deletions src/tilegym/ops/cutile/bmm.py
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,7 @@ def grid_fn(cfg):
"occupancy": cfg.occupancy,
},
search_space=_bmm_autotune_configs,
compiler_time_limit_sec=30,
)

return output
Expand Down