Running same code, same Matlab version (2021b) on difference computers (8 different types) 7 produce same results only one is different.
15 次查看(过去 30 天)
显示 更早的评论
Hi,
I am running same code, same Matlab version (2021b) on difference computers (8 different types) 7 produce same results (difference about 3 digits after '.') only one is different. I can not find any consistent difference between them. All have different CPU generations (no consistency there), speed etc. All windows 10 or 11 64 bit, Matlab is 64 bit in all. I do not use parallel computing toolbox.I have checked all possible ideas raised in previousdiscussions including checking BLAS libraries.
Does anyone have any idea what other features may affect precision of results?
Any help will be much appreciated:)
2 个评论
Bruno Luong
2023-8-15
"(difference about 3 digits after '.')"
I'm not sure what kind of simulation you are doing but at the first glance this is pretty poor for a stable simulation.
That certainly doesn't help for the duck PC that is totally off.
dpb
2023-8-15
My initial reaction, too, Bruno, but that would depend on how many digits are to the left of the decimal point as well, so could well be within single precision tolerances.
And, of course, there's nothing indicated by OP that it is a 100% deterministic model -- although there's nothing that says it isn't, either.
回答(2 个)
Richard Burnside
2023-8-14
Could this be the different handling of floating point precision.? Most modern processors are compliant with IEEE 754 floating point representation but older machines may not be compliant.
dpb
2023-8-14
There may yet be differences in the supporting runtime libraries that have been loaded on various machines by different software installed on any given machine that may not be on the others or the version of Java or any number of such things including the OS update levels.
While somewhat dated now, https://hal.science/file/index/docid/281429/filename/floating-point-article.pdf gives a good overview discussion of some of the issues that can arise.
Modern CPU architecture can also affect operation order/pipelining and such seemingly trivial details can, on occasion, be sufficient as to create noticeable differences. It may be that somesuch operation also created an edge case of rounding that is unique to that particular combination of all these variables.
1 个评论
dpb
2023-8-15
Of course, there have been chipsets with issues in the past; although I'm unaware of any current ones, was just reminded that, for example, the Intel compilers are/contain optimizations specific for Intel chipsets -- if one happened to have a support library using such a toolset and running on an AMD chipset, would it be guaranteed to fail or could one silently obtain a different result? I dunno...
Any of this using video accelerators or the like...no chance of debugging this remotely; you might consider if the app isn't proprietary and can be packaged conveniently uploading a test case and let folks here try it on a "veritable plethora" of machines and releases and see if that could pinpoint any common factors amongst the results.
Failing that, only other suggestion I'd have would be to contact TMW support and see if they can provide further guidance.
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!