Skip to content

Remove Split op’s dependence on number of outputs #4188

@garymm

Description

@garymm

It is desirable to make the behavior of ONNX ops fully determined by its input parameters as well as attributes. The Split op is one of the rare cases where this does not hold. The split op has an optional second parameter that indicates how the split should happen, e.g., into 3 parts of sizes 10, 10, and 4, for example. However, if this parameter is omitted, the current spec says that the split axis is evenly divided among the specified outputs. The behavior is, hence, dependent on the variadic number of outputs specified. It will be cleaner if, instead, we add a specific attribute, say num_outputs, to indicate how many equal parts that the split axis should be divided into.

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic: operatorIssues related to ONNX operators

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions