Skip to content
Open
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
8 changes: 0 additions & 8 deletions py/torch_tensorrt/dynamo/conversion/aten_ops_converters.py
Original file line number Diff line number Diff line change
Expand Up @@ -996,16 +996,8 @@ def aten_ops_slice(
)


def refit_validator(node: Node, settings: Optional[CompilationSettings] = None) -> bool:
# cumsum op is not refitable
if settings and not settings.immutable_weights:
return False
return True


@dynamo_tensorrt_converter(
torch.ops.aten.cumsum.default,
capability_validator=refit_validator,
supports_dynamic_shapes=True,
)
@enforce_tensor_types(
Expand Down
4 changes: 2 additions & 2 deletions tests/py/dynamo/conversion/test_cumsum_aten.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def forward(self, x):
self.run_test(
Cumsum(),
inputs,
immutable_weights=True,
immutable_weights=False,
)

@parameterized.expand(
Expand Down Expand Up @@ -97,7 +97,7 @@ def forward(self, x):
self.run_test_with_dynamic_shape(
Cumsum(),
inputs,
immutable_weights=True,
immutable_weights=False,
)


Expand Down
Loading