Skip to content

Commit b2b650f

Browse files
authored
Fix ImageScaler bias for opset 10 (#322)
1 parent 473f220 commit b2b650f

File tree

1 file changed

+1
-1
lines changed
  • onnxmltools/convert/coreml/operator_converters/neural_network

1 file changed

+1
-1
lines changed

onnxmltools/convert/coreml/operator_converters/neural_network/ImageScaler.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def convert_preprocessing_scaler(scope, operator, container):
3737

3838
# Store the bias vector. It will be added into the input tensor.
3939
bName = scope.get_unique_variable_name(operator.full_name + '_bias')
40-
container.add_initializer(bName, onnx_proto.TensorProto.FLOAT, [len(bias), 3, 1], bias)
40+
container.add_initializer(bName, onnx_proto.TensorProto.FLOAT, [len(bias), 1, 1], bias)
4141

4242
# Compute Z = a * X.
4343
zName = scope.get_unique_variable_name(operator.full_name + '_scaled')

0 commit comments

Comments
 (0)