Skip to content

Commit 16b1e8e

Browse files
committed
Fix broken cutlass version comparison
Signed-off-by: Santi Villalba <[email protected]>
1 parent 0155a9b commit 16b1e8e

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

op_builder/evoformer_attn.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55

66
from .builder import CUDAOpBuilder, installed_cuda_version
77
import os
8+
from packaging.version import Version
89

910

1011
class EvoformerAttnBuilder(CUDAOpBuilder):
@@ -54,9 +55,7 @@ def is_compatible(self, verbose=False):
5455
if verbose:
5556
self.warning("Please pip install nvidia-cutlass if trying to pre-compile kernels")
5657
return False
57-
cutlass_major, cutlass_minor = cutlass.__version__.split('.')[:2]
58-
cutlass_compatible = (int(cutlass_major) >= 3 and int(cutlass_minor) >= 1)
59-
if not cutlass_compatible:
58+
if Version(cutlass.__version__) < Version('3.1.0'):
6059
if verbose:
6160
self.warning("Please use CUTLASS version >= 3.1.0")
6261
return False

0 commit comments

Comments
 (0)