4094b4e6bf59cf713269097f56ebcd925ffe6e57,src/graph_transpiler/webdnn/frontend/onnx/defs/tensor.py,,_convert_split,#Any#Any#,53

Before Change


@ONNXConverter.register_handler("Split")
def _convert_split(converter: ONNXConverter, onnx_op: INodeProto):
    // FIXME: It"s possible to support in current version of webdnn
    raise NotImplementedError("[ONNXConverter] Operator \"Split\" is not supported yet.")


@ONNXConverter.register_handler("Slice")
def _convert_slice(converter: ONNXConverter, onnx_op: INodeProto):

After Change



    attrs = attribute_dict(onnx_op)

    axis = x.order.axes[attrs["axis"].i]

    if "split" not in attrs:
        raise NotImplementedError("[ONNXConverter] Operator \"Split\" without \"split\" parameter is not supported yet.")
    split = attrs["split"].ints
    sections = np.cumsum(split).tolist()[:-1]

    ys = SplitAxis(None, axis=axis, sections=sections)(x)
    for i, y in enumerate(ys):
        converter.set_variable(onnx_op.output[i], y)


@ONNXConverter.register_handler("Slice")
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 8

Instances


Project Name: mil-tokyo/webdnn
Commit Name: 4094b4e6bf59cf713269097f56ebcd925ffe6e57
Time: 2017-12-12
Author: y.kikura@gmail.com
File Name: src/graph_transpiler/webdnn/frontend/onnx/defs/tensor.py
Class Name:
Method Name: _convert_split


Project Name: thenetcircle/dino
Commit Name: 65a607ea8e24c2f66c26245f507a59a7ca316896
Time: 2016-10-19
Author: oscar.eriks@gmail.com
File Name: dino/db/rdbms/handler.py
Class Name: DatabaseRdbms
Method Name: room_allows_cross_group_messaging


Project Name: thenetcircle/dino
Commit Name: 65a607ea8e24c2f66c26245f507a59a7ca316896
Time: 2016-10-19
Author: oscar.eriks@gmail.com
File Name: dino/db/redis.py
Class Name: DatabaseRedis
Method Name: room_allows_cross_group_messaging