Single vs. Double Precision

Message boards : MilkyWay@home Science : Single vs. Double Precision

Author | Message |
---|---|

Just wondering how big a % error single precision affects the project? I have two 4670s I'd like to crunch with which only do single precision. | |

ID: 17151 · Rating: 0 · rate:
/ Reply
Quote
| |

You might want to read the application code board. | |

ID: 17152 · Rating: 0 · rate:
/ Reply
Quote
| |

Just wondering how big a % error single precision affects the project? I have two 4670s I'd like to crunch with which only do single precision. Gpu's are required to use double. Single is not usable for this project. See this thread for usable Gpus: http://milkyway.cs.rpi.edu/milkyway/forum_thread.php?id=589 ____________ Doesn't expecting the unexpected make the unexpected the expected? If it makes sense, DON'T do it. | |

ID: 17164 · Rating: 0 · rate:
/ Reply
Quote
| |

Just wondering how big a % error single precision affects the project? I have two 4670s I'd like to crunch with which only do single precision. I'm already running a 4850 - I know what the current set of usable GPUs are, thank you. I've read through and through that part of the forum; to be honest I'm just asking for specifics - I'm asking just how much of a difference single precision makes to the results. In the forum, all I see is 'this science requires double precision' reiterated over and over, rather than a reason.For example: Compare a constant, take pi, as a single and a double.It's true value is 3.1415926535897932384626433832795In single-precision pi has a decimal value of 3.1415927410125In double-precision pi has a decimal value of 3.1415926535898In single, pi is correct to 6dp.In double, pi is correct to 12dp.Depending on the calculations that are involved, the base error will either compound, or grown with each successive calculation. Now, like I said, I do electrochemical simulation. This involves solving of partial differential equations via matrix manipulation. A typical simulation for a set of functions takes 5 minutes (at double precision) on a 3Ghz Core2Quad machine (single threaded), and on conversion to single precision, I barely get 0.001% discrepancy on results - and as such I can just increase the density of the matrix to make up that discrepancy at very little cost to time. The single vs. double discrepancy evens out over time due to the nature of my simulationThis I'm asking just as a 10 minute detour to compare. If it sucks, then ok. But if it isn't that big an issue, there could be a bigger set of GPUs out there willing to crunch. I don't program in C, but if it's possible to compile for single instead of double, we can run and compare. Or if I can be linked to something of that effect, please post here.Many thanks, Ian ____________ | |

ID: 17168 · Rating: 0 · rate:
/ Reply
Quote
| |

It's true value is Where did you get these numbers? Actually double precision values have about 16 significant decimal places, whereas single precision values have 7 significant decimal places. The double precision value of Pi is 3.1415926535897930, the single precision value is 3.1415927. You can count it, that are 16 and 8 correct decimal places (when rounded), respectively. For the single precision Pi value one has some luck with the binary representation. The next smaller representable value would be 3.1415925, the next larger one 3.1415930. So the resolution is worse than 8 decimal places.Btw., the "true" value of Pi has an infinite number of decimal places ;) But back to the topic. Could Milkyway make use of single precision? You have to know that MW uses quite some exponential functions. Unfortunately the numerical noise gets exponentiated by an exponential function too. Therefore one needs some more digits to start with. But I think in the early stages of a search, when one is far away from the optimum fitness, it may be possible. Most probably one can exclude some parameter ranges with single precision calculations and search for the optimum in a second pass using double precision. But that would require 2 sets of applications (or one incorporating both) and also more effort on the server side. And it is not even said, that it would be much faster considering how fast the searches converge already now. How do you decide which parameter regions you search again with double precision if not all clients have reported back their single precision results? If you wait for the results, the whole search may have already be finished if you started it with higher precision from the beginning. Milkyway really likes the results to be returned fast. As a side note, one would get real problems how to award credits in comparison to other projects. Flops counting would yield approximately 5 to 6 times as much as GPUGrid (even after their 60% credit raise) as one would get >500GFlops (single precision) on high end cards (and not only 140-150 double precision GFlops as now). Milkyway@home should change its name to Milky GPU Highway then ;) | |

ID: 17173 · Rating: 0 · rate:
/ Reply
Quote
| |

Cluster Physik, awesome answer. Many thanks, exactly what I was looking for!! By your answer, single precision works my end, as my own simulations uses few exponentials that get evened out over time. I use a load of matrix calculations which are simple operator functions. | |

ID: 17210 · Rating: 0 · rate:
/ Reply
Quote
| |

I experimented with integral steps for "mu" and "nu" which resulted to significant differences in the final fitness. | |

ID: 28363 · Rating: 0 · rate:
/ Reply
Quote
| |

Post to thread

Message boards :
MilkyWay@home Science :
Single vs. Double Precision

Copyright © 2019 AstroInformatics Group