33d3c4ca01dd3a1219275346c230006e2c24edad,src/graph_transpiler/webdnn/frontend/onnx/defs/nn.py,,_convert_global_max_pool,#Any#Any#,115

Before Change


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


@ONNXConverter.register_handler("BatchNormalization")
def _convert_batch_normalization(converter: ONNXConverter, onnx_op: INodeProto):

After Change


@ONNXConverter.register_handler("GlobalMaxPool")
def _convert_global_max_pool(converter: ONNXConverter, onnx_op: INodeProto):
    x = converter.get_variable(onnx_op.input[0])
    if x.ndim == 4:
        x.order.unify(OrderNCHW)

    reduction_size = mul(x.shape[2:])
    reduction_axis = Axis()

    x = x.reshape([x.shape[0], x.shape[1], reduction_size],
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: mil-tokyo/webdnn
Commit Name: 33d3c4ca01dd3a1219275346c230006e2c24edad
Time: 2017-12-12
Author: y.kikura@gmail.com
File Name: src/graph_transpiler/webdnn/frontend/onnx/defs/nn.py
Class Name:
Method Name: _convert_global_max_pool


Project Name: mil-tokyo/webdnn
Commit Name: 33d3c4ca01dd3a1219275346c230006e2c24edad
Time: 2017-12-12
Author: y.kikura@gmail.com
File Name: src/graph_transpiler/webdnn/frontend/onnx/defs/nn.py
Class Name:
Method Name: _convert_global_average_pool


Project Name: nilmtk/nilmtk
Commit Name: 29b1c7bcc17534b0df50914e075c98c9addcafe2
Time: 2014-07-25
Author: jack-list@xlk.org.uk
File Name: nilmtk/metergroup.py
Class Name: MeterGroup
Method Name: dropout_rate