|
Not always, but very often 
|
|
|
|
|
Eddy Vluggen wrote: Size!
It does matter apparently!
Eddy Vluggen wrote: Ah, just a small bug
That's what she said.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
i have a couple of image processing fns which input and output BYTEs but need to convert the input to doubles for the internals because even floats run out of precision well within reasonable parameters.
i'd love to be able to not have to use 24 bytes per pixel, but...
modified 17-Jul-14 13:24pm.
|
|
|
|
|
Chris Losinger wrote: i'd love to be able to not have to use 24 bytes per pixel, er, bits?
But, as we all know - palletized images suck when it comes to performing any real manipulation on them, since you're stuck with looking-up the 24 bit values anyway.
Alpha-blending images with a pallette? :shudder: Uhhhrgh! Please dont make me do that again. Recomputing a new pallete is more effort than the image processing itself.
|
|
|
|
|
no, BYTEs.
doubles are 8 bytes each. 3x8 = 24 bytes.
|
|
|
|
|
Chris Losinger wrote: but need to convert the input to doubles for the internals
Of course. Must be about time for bed for me...
Those images sure do get pretty big, pretty quick, at that rate of memory consumption.
|
|
|
|
|
For pallet(e)s, all you need is scrub wood and nails. Palettes on the other hand...
|
|
|
|
|
Ennis Ray Lynch, Jr. wrote: I wrote a hurricane damage simulator
I didn't know you worked on Sim City.
|
|
|
|
|
Mine isn't nearly as accurate. Wind fields in real-life are surprisingly non-deterministic and literally change with the phase of the moon.
|
|
|
|
|
Ennis Ray Lynch, Jr. wrote: and literally change with the phase of the moon. So do I! Oh no... It's a full moo OOOOOOOOOOH!!! *Howl*
It's an OO world.
public class SanderRossel : Lazy<Person>
{
public void DoWork()
{
throw new NotSupportedException();
}
}
|
|
|
|
|
|
But phases of the moon are VERY deterministic.
|
|
|
|
|
Ennis Ray Lynch, Jr. wrote: Most of my work four places is good enough and I wrote a hurricane damage simulator.
Well, how much precision do you need to say $15 billion (or whatever the number is in billions of dollar?)
Marc
|
|
|
|
|
You are not supposed to point out flaws in my argument!
|
|
|
|
|
Someone, somewhere, is thinking "I am a hurricane damage simulator".
cheers
Chris Maunder
|
|
|
|
|
Sean been at the hamsters' sunflower hooch again?
|
|
|
|
|
I work on stuff where 15 digits is marginally OK, using plenty of trickery.
CQ de W5ALT
Walt Fair, Jr., P. E.
Comport Computing
Specializing in Technical Engineering Software
|
|
|
|
|
I'll have my math float away, thank you!
It's an OO world.
public class SanderRossel : Lazy<Person>
{
public void DoWork()
{
throw new NotSupportedException();
}
}
|
|
|
|
|
Is that anything like a root beer float?
|
|
|
|
|
Depends what I need to do - for some things I don't need either, others will need precision and also accuracy in which case there's no point getting the wrong answer instantly, others I just need an estimate but I need it quickly
|
|
|
|
|
Most of my work, 4 byte floats are too inaccurate. Some of my work, doubles barely suffice. All of my work, speed matters. Conclusion: I need both, and I need it yesterday!
GOTOs are a bit like wire coat hangers: they tend to breed in the darkness, such that where there once were few, eventually there are many, and the program's architecture collapses beneath them. (Fran Poretto)
|
|
|
|
|
Sometimes you can solve/reduce floating point problems by scaling up - always recording your prices in pennies not dollars for example and your hurricane strength in metric butterflies.
|
|
|
|
|
4 base 10 digits would generally be OK if the internal representation was base 10 also. Even with all the digits an IEEE754 64bit float provides, weirdness from the inability to represent 0.1 precisely in binary has an obnoxious habit of leaking into userspace.
Did you ever see history portrayed as an old man with a wise brow and pulseless heart, waging all things in the balance of reason?
Is not rather the genius of history like an eternal, imploring maiden, full of fire, with a burning heart and flaming soul, humanly warm and humanly beautiful?
--Zachris Topelius
Training a telescope on one’s own belly button will only reveal lint. You like that? You go right on staring at it. I prefer looking at galaxies.
-- Sarah Hoyt
|
|
|
|
|
Both. In my experience, when I've needed more than just a few digits of precision, its because I'm doing a complex calculation, and that's usually when I've needed both precision and speed.
We can program with only 1's, but if all you've got are zeros, you've got nothing.
|
|
|
|
|
I would rather use strings, and convert to accurate precision using Unidex.
|
|
|
|