ciyongch commented on a change in pull request #17318: Enable MKL-DNN FullyConnected backward URL: https://github.com/apache/incubator-mxnet/pull/17318#discussion_r380416282
########## File path: tests/cpp/include/test_mkldnn.h ########## @@ -63,24 +63,24 @@ struct TestArrayShapes { }; // Init arrays with the default layout. -inline static void InitDefaultArray(NDArray *arr, bool is_rand = false) { +inline static void InitDefaultArray(NDArray *arr, bool is_rand = false, int max = 50) { const TBlob &blob = arr->data(); mshadow::default_real_t *data = blob.dptr<mshadow::default_real_t>(); int size = blob.Size(); for (int i = 0; i < size; i++) if (is_rand) { - data[i] = (std::rand() % 100) - 50; + data[i] = (std::rand() % (max * 2)) - max; Review comment: Ok, let's keep it as is for now. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services