-
Notifications
You must be signed in to change notification settings - Fork 282
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
Add full process info. #65
Conversation
Thanks for your contribution. After all CI tests fixed, I'll have a look to merge this. BTW I am debating what would be the best command line flag (rather than |
Thanks @wookayin
Yeah, the unicode characters aren't behaving nicely with Python 2.7. I'm trying to figure that out.
I don't have strong feelings one way or another on this |
@wookayin Let me know what you decide about the flag and I can make that change. |
Just FYI. |
That makes sense to me. That would definitely simplify these changes. |
@wookayin |
I opened an issue (#66) and can make the Python 2 changes separately before we merge these changes. |
The current master has dropped python2 -- would you want to rebase onto master and drop changesets for python2 support if necessary? |
@wookayin |
88201f7
to
e62939d
Compare
@wookayin Let me know if there's anything else you'd like me to change. |
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.
I love this feature, and thanks for your contribution.
Other than the line-by-line comments, there is one more thing we need to resolve: it's slow. cpu_percent()
needs 0.1 seconds of blocking sampling per process; in a case where we have 64+ processes it will take many seconds. If we can cache and reuse the Process instances then it can be non-blocking via interval=0
(for gpustat -i
cases), but not sure for one-time run without loops. Perhaps we can also parallelize using async/await features.
e62939d
to
42ec955
Compare
I will spend some time figuring out the best way to do this. |
@wookayin |
Looks cool. Two comments:
|
@wookayin |
Looks good to me, thanks! |
Let's get this merged. I'll add a bit of follow-up commits and cleanups. Thanks a lot for your hard work! |
I made a small changes in a9c27f3. |
Fixes #50
I added
-f
,--show-full-cmd
that show the full process info as discussed in #50.Right now it shows the percent of CPU usage and the percent of system memory in use, but that can be changed.
Let me know what you think.
Example: