verigak / progress

Easy to use progress bars for Python
ISC License
1.41k stars 179 forks source link

More accurate progress bar #23

Closed praiskup closed 8 years ago

praiskup commented 8 years ago

As a side effect, sma_* variables may be tweaked by class user.

praiskup commented 8 years ago

Ping? Seems like silence is here for about 2 years in this repo, I'm now considering fork and release separately. Any objections?

praiskup commented 8 years ago

Please have a look.

praiskup commented 8 years ago

ptal :)

verigak commented 8 years ago

I think that if you are going to diverge from the standard moving average which is an established algorithm, you will need to make your case much better than this. Does your solution really improve on all cases, or just in the one you mention? At least you will need a few test cases that demonstrate the problem and your solution.

As an aside, doesn't _dt always contain at maximum just one item that way?

praiskup commented 8 years ago

The algorithm was not changed by this PR. The problem is that the "old" implementation works with incredibly small float numbers, doing their sum and dividing ... which makes it very inaccurate. image

The code that uses it: https://git.fedorahosted.org/cgit/copr.git/tree/cli/copr_cli/main.py?id=15116133574defe50#n165

praiskup commented 8 years ago

So PTAL.

praiskup commented 8 years ago

Unlucky, I can't reopen, I'll submit new PR.