Skip to content

Commit

Permalink
Merge pull request #992 from pytorch/anuragd/fix_aten_split
Browse files Browse the repository at this point in the history
(//core): Added a variant for aten::split
  • Loading branch information
narendasan committed May 23, 2022
2 parents 2c787ad + 99d1f32 commit 042fa2e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions core/conversion/converters/impl/select.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -350,6 +350,12 @@ auto select_registrations TORCHTRT_UNUSED =
LOG_DEBUG("Converted split op into a list of IValues");
return true;
}})
.pattern({"aten::split.sizes(Tensor(a -> *) self, int[] split_size, int dim=0) -> (Tensor[])",
[](ConversionCtx* ctx, const torch::jit::Node* n, args& args) -> bool {
add_split(ctx, n, args, true, false);
LOG_DEBUG("Converted split op into a list of IValues");
return true;
}})
.pattern({"aten::split.Tensor(Tensor(a) self, int split_size, int dim=0) -> (Tensor[])",
[](ConversionCtx* ctx, const torch::jit::Node* n, args& args) -> bool {
add_split(ctx, n, args, false, false);
Expand Down

0 comments on commit 042fa2e

Please sign in to comment.