File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ def register_op_decorator(pt_ver, op_namespace_id):
4242 """Version-dependent decorator for custom op registration."""
4343
4444 def decorator (func ):
45- if pt_ver <= Version ("2.4" ):
45+ if pt_ver < Version ("2.4" ):
4646 return torch .library .impl_abstract (op_namespace_id )(func )
4747 return torch .library .register_fake (op_namespace_id )(func )
4848
@@ -61,7 +61,7 @@ def register_aiu_gptq_op():
6161 logger .warning ("AIU op has already been registered" )
6262 return
6363 op_namespace_id = "gptq_gemm::i4f16_fxinputs_aiu"
64- if torch_version <= Version ("2.4" ):
64+ if torch_version < Version ("2.4" ):
6565 torch .library .define (
6666 op_namespace_id ,
6767 "(Tensor x, Tensor qw, Tensor qzeros, "
Original file line number Diff line number Diff line change @@ -36,7 +36,7 @@ def implement_op_decorator(pt_ver, op_namespace_id):
3636 """Version-dependent decorator for custom op implementation."""
3737
3838 def decorator (func ):
39- if pt_ver <= Version ("2.4" ):
39+ if pt_ver < Version ("2.4" ):
4040 return torch .library .impl (op_namespace_id , "default" )(func )
4141 return torch .library .custom_op (op_namespace_id , mutates_args = ())(func )
4242
@@ -47,7 +47,7 @@ def register_op_decorator(pt_ver, op_namespace_id):
4747 """Version-dependent decorator for custom op registration."""
4848
4949 def decorator (func ):
50- if pt_ver <= Version ("2.4" ):
50+ if pt_ver < Version ("2.4" ):
5151 return torch .library .impl_abstract (op_namespace_id )(func )
5252 return torch .library .register_fake (op_namespace_id )(func )
5353
You can’t perform that action at this time.
0 commit comments