Skip to content

Instantly share code, notes, and snippets.

@AlessioGiambrone
Last active December 22, 2016 20:39
Show Gist options
  • Save AlessioGiambrone/e21cdaf807fc226585f1a4fae274851c to your computer and use it in GitHub Desktop.
Save AlessioGiambrone/e21cdaf807fc226585f1a4fae274851c to your computer and use it in GitHub Desktop.
Nvidia graphic memory
# This is useful for get memory data to use, for example, with conky.
# this is ok, at least, for my graphic card.
free_graphic_memory=`nvidia-smi | sed -n "9p" | cut -d '|' -f 3 | cut -d '/' -f 1 | xargs`
total_graphic_memory=`nvidia-smi | sed -n "9p" | cut -d '|' -f 3 | cut -d '/' -f 2 | xargs`
@AlessioGiambrone
Copy link
Author

Well, this is deprecated; with the support to the XNVCtrl library, Conky is able to display graphic memory on its own.
A simple example could be the one contained in my own conkyrc.
Please see the conky's manpage for further info.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment