Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Progress bar? #23

Open
TomNicholas opened this issue Nov 29, 2018 · 1 comment
Open

[Feature] Progress bar? #23

TomNicholas opened this issue Nov 29, 2018 · 1 comment
Labels

Comments

@TomNicholas
Copy link
Contributor

TomNicholas commented Nov 29, 2018

Creating animations using matplotlib.animation.funcanimation() can take a while, especially without blitting.
It would be nice to have an optional progress bar which prints to the terminal, perhaps telling you which frame is currently being plotted.

An example use case for this is when you have a large dataset and you're not sure what a reasonable time resolution to try and display at would be. Currently if you start plotting then you have no feedback telling you whether it's going to take 5 seconds or 5 minutes to complete. With a progress bar then you could at least say "nah 5 minutes is way too long, let me downsample my data first quickly".

I guess it would be an optional argument to animatplot.Animation()?

I would be happy to add this myself if you're okay with that?

@t-makaro
Copy link
Owner

t-makaro commented Dec 7, 2018

I'm not sure why this would be needed. FuncAnimation plots one frame at a time. The first x frames should always take the same amount of time to display, and if the timeline_slider is moving slowly then decrease the resolution. I could see this being useful for saving animations to a file, but (possibily depending on the writer) may not be an accurate representation of the time it takes to save the file.

All that said. You can try making a new block that simply creates and manually updates a tqdm progress bar with the frame number. I'm assuming that tqdm supports a progress bar that can decrease in value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants