-
Notifications
You must be signed in to change notification settings - Fork 7
Plot live updates over time #3
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
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #3 +/- ##
===========================================
- Coverage 100.00% 94.73% -5.27%
===========================================
Files 3 3
Lines 134 152 +18
===========================================
+ Hits 134 144 +10
- Misses 0 8 +8 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution 👍
| # Using linux date | ||
| # For mac - brew install coreutils ; echo "alias date=gdate" >> ~/.bash_profile | ||
| runtime="30 minutes" | ||
| runtime="24 hours" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I were to work on it, I would put some of the value like the runtime or sleep time as variables 🤔
But I don't mind as is.
| self.data_path = data_path | ||
| self.load_data() | ||
|
|
||
| def load_data(self): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
so it's separated to be able to load the data asynchronously?
| # Leave more space for the legend | ||
| plt.subplots_adjust(right=0.7) | ||
|
|
||
| def plot_category(self, category, size=(10, 5)): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would you have an example of how you used the new methods ? (For the Readme)
Disclaimer: I'm not necessarily suggesting that this be merged as-is, but I didn't want my changes to be wasted if they might be useful to others.
So this is something I got working for my use case which is analysing long-term memory usage (e.g. over several hours) of a set of containers.
If there are parts of this which you think are useful then I'm happy to split them out / clean them up, or for you to pick and choose.
For comparison, there is some memory graphing in the Docker Desktop UI now, but it is only either per-container, or a total for all containers (rather than all containers on 1 graph) and also in my experience it is not always persistent or reliable (has gaps).
So anyway - if this just sits open as something potentially useful that's fine, or if you're interested in merging some/all then that's great too!