When you run Microsoft R Server 9.0, 9.1, 9.2, 9.3.x, or Microsoft Machine Learning Server as part of Microsoft SQL Server 2017, you experience inconsistent results in Intel Math Kernel Library (MKL) computations. This issue occurs because of a missing MKL_CBWR environment variable.
This issue occurs because a new feature was added to the Intel MKL library that's included together with Microsoft R Server and SQL Server 2017. For more information about this feature, go to the following Intel website:
To fix this issue, configure conditional numeric reproducibility in Microsoft R Server or Machine Learning Server by setting the MKL_CBWR=AUTO system environment variable. To do this, follow these steps:
In Control Panel, select System and Security > System > Advanced System Settings > Environment Variables.
Create a new User or System variable, and specify the following values:
Set the variable name to MKL_CBWR.
Set the variable value to AUTO.
Restart Microsoft R Server.
In future versions of Microsoft R Server, the MKL_CBWR=AUTO setting will be the default setting.
The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, about the performance or reliability of these products.