From: Edward W. <Edward.Wildgoose@FRMHedge.com> - 2003-08-15 10:43:28
|
Aha, perfect. So I was wrong about the 70%. From your tests here. I = would suggest doing three initial trial resizes. One low, one quite = high, and one at about 89%. Then when you do your estimate go slightly = wider than your estimate, eg if you estimate 45%, then use 40%, if you = estimate 95%, then go 97%. The point is that because of the convexity = you will slightly underestimate on the upside and overestimate on the = downside. =20 We could probably improve things even more as follows: =20 a) Do the analysis you have done here and estimate the "usual" = compression one gets from the original as quality varies, eg 10:1 at = 40%, 2:1 at 95%. The point is to use the orig filesize, as an initial = input to get a first pass estimate of the quality. b) Bracket either side of that first pass estimate (fairly widely, = unless near the 89% inflexion then narrow it.) c) use these two bracket figures to do the linear interpolation. =20 I think if you can get something reasonably accurate, but not quite spot = on then this will be good enough. In general I think you will = underestimate when the quality can be high, but over estimate when the = quality is low. This actually means you will be generous when the = quality is down at the point where 20 bytes extra starts to make a big = difference.... Which seems a slight advantage anyway. =20 If you want to drop me your excel sheet with those data points I will = see if we can't do better than linear interpolation anyway? =20 Ed -----Original Message----- From: Joan McGalliard [mailto:ga...@jo...] Sent: 15 August 2003 11:10 To: Edward Wildgoose Cc: gal...@li... Subject: Re: [Gallery-devel] A challenge! ah! no attachments!=20 http://mcgalliard.org/image001.gif=20 sorry 'bout that=20 On Friday, August 15, 2003, at 09:51 AM, Edward Wildgoose wrote:=20 #Work out what the rate should be. Basically it is a scale thing. We = now that the low rate gives us one size, the high another, so work = proportionally where we want to be in that range, eg if we want to be = smack bang in the middle of the two ranges then this is 50%=20 Interesting. But the thing is, it's not linear . . . . . . .=20 (I got that far in excel before getting confused)=20 joan=20 --=20 Joan McGalliard, UK http://www.mcgalliard.org=20 |