tag:blogger.com,1999:blog-7451086006168569993.post6601195703098919377..comments2023-02-28T05:48:54.955-05:00Comments on Arbitrary Thoughts: How to work with progress bars, part 1Andrewhttp://www.blogger.com/profile/17391659235860245424noreply@blogger.comBlogger7125tag:blogger.com,1999:blog-7451086006168569993.post-26495411015970430222009-06-11T14:01:17.270-04:002009-06-11T14:01:17.270-04:00Let's look at an example. Let's say we hav...<i>Let's look at an example. Let's say we have an overall task composed of three subtasks. The first sub task is 40% of the overall task. The second sub task is 50% of the overall task. The last task is 10% of the overall task.</i><br /><br />The bit I don't get is where you came up with the figures of 40/50/10 ? How do you know those percentages?<br /><br />Wouldn't the best/easiest way just to say each subtask is 1/3 of 100%?dalorehttps://www.blogger.com/profile/09940596014371040813noreply@blogger.comtag:blogger.com,1999:blog-7451086006168569993.post-62583484095413996592009-06-05T15:13:00.737-04:002009-06-05T15:13:00.737-04:00Andrew,
Computer people (programmers et al) often ...Andrew,<br />Computer people (programmers et al) often think/say that users are idiots. <br /><br />Programmers are often idiots too.<br /><br />Too often.Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-7451086006168569993.post-34719311464406497762009-05-31T16:22:25.322-04:002009-05-31T16:22:25.322-04:00The thing with progress bars is that you need some...The thing with progress bars is that you need some kind of general information about the process you are trying to describe.<br />When talking about network access, which might suffer from congestion, you could use a floating average always assuming you know the total size you are downloading. That naturally extends to other things that might take varying amounts of time, especially if they are accessing resources you cannot control.<br /><br />For subprocesses implementing algorithms you could also use the Big-O of that algorithm, if you know it. Obviously well-known algorithms are great fits for this.<br />Making a best guess is often good enough - if the user knows the step might take a long time to complete it's ok to say something imprecise.<br />It's even ok to err on the good side of things:<br />For example a sorting step using quicksort might be faster than what the Big-O for the expected runtime says it is (accounting for the constant factors in the calculation, of course!) but that's ok. It's a best guess.<br /><br />But I wholeheartedly agree with your main point: Progress bars should <I>never</I> jump backwards, simply because that suggests that the computer made it all worse ;)Kayhttps://www.blogger.com/profile/01666744992823024667noreply@blogger.comtag:blogger.com,1999:blog-7451086006168569993.post-89395846353946573372009-05-31T14:43:29.082-04:002009-05-31T14:43:29.082-04:00Progress modeling makes an assumption (my system a...Progress modeling makes an assumption (my system and my systems conditions are the same as yours) that may be badly flawed.<br /><br />Network data access speeds vary over a very wide range. Local File I/O performance varies - especially if file cache effects participate. GPU (if involved) capabilities really vary. CPU speeds vary to a lesser extent.Green Tractorhttps://www.blogger.com/profile/13375803297869313093noreply@blogger.comtag:blogger.com,1999:blog-7451086006168569993.post-81009713130745301232009-04-26T19:33:00.000-04:002009-04-26T19:33:00.000-04:00Yup, that would work.Yup, that would work.kevininspacehttps://www.blogger.com/profile/05697396300585904523noreply@blogger.comtag:blogger.com,1999:blog-7451086006168569993.post-13252736133033003282009-04-25T22:04:00.000-04:002009-04-25T22:04:00.000-04:00The short answer is you need to profile. Essential...The short answer is you need to profile. Essentially you run the code with some real data and measure how long each part takes. You can use this information to figure out what numbers to pass to buildSubProgressBar().Andrewhttps://www.blogger.com/profile/17391659235860245424noreply@blogger.comtag:blogger.com,1999:blog-7451086006168569993.post-72403371730967670882009-04-20T22:47:00.000-04:002009-04-20T22:47:00.000-04:00Hmmm, interesting post. Very useful too. I'd like ...Hmmm, interesting post. Very useful too. I'd like to see what you have to say in Part 2, because to me it looks like whatever you pass to buildSubProgressBar() is a guess. And I assume that, since we're smart coders, we can actually resort to some fancy handwaving to estimate what that chunck of code should represent in the overall scheme of things. In other words, "How can I guess how much of the overall processing time will this sub-task consume?" Or am I just not getting this?kevininspacehttps://www.blogger.com/profile/05697396300585904523noreply@blogger.com