intel / webml-polyfill

Deprecated, the Web Neural Network Polyfill project has been moved to https://github.com/webmachinelearning/webnn-polyfill
Apache License 2.0
161 stars 46 forks source link

[test] Scale of FLOAT32 type was set with dimensions in two CTS SOFTMAX test cases. #156

Closed BruceDai closed 5 years ago

BruceDai commented 5 years ago

According to definition in https://github.com/intel/webml-polyfill/blob/master/src/nn/Enums.js#L1046

* * 1: A FLOAT32 value, specifying the positive scaling factor for the exponent, beta.

Errors happened in these two following CTS SOFTMAX test cases: https://github.com/intel/webml-polyfill/blob/master/test/cts/test/V1_0/softmax_float_1.js#L12

let type1 = {type: nn.FLOAT32, dimensions: [1e-06]};

https://github.com/intel/webml-polyfill/blob/master/test/cts/test/V1_0/softmax_float_2.js#L12

let type1 = {type: nn.FLOAT32, dimensions: [1.0]};

This error only happens on 'FLOAT32' type, not happen on 'INT32' type and 'UINT32' type.

BruceDai commented 5 years ago

Fixed by PR https://github.com/intel/webml-polyfill/pull/157

BruceDai commented 5 years ago

PR #157 has been merged, closed it.