python - Getting arguments from code -


sorry if bit vague, or been asked, wasn't sure of terminology couldn't google it. i'm looking how assign arguments psutil.virtual_memory() gives different variables.
example, calling psutil.virtual_memory() gives (total=8374149120l, available=1247768576l, percent=85.1, used=8246628352l, free=127520768l, active=3208777728, inactive=1133408256, buffers=342413312l, cached=777834496)

i want percent value, , assign variable. how can this?

documentation: https://code.google.com/p/psutil/wiki/documentation#memory

it returns namedtuple (called vrem) use percent = psutil.virtual_memory().percent

>>> help(psutil.virtual_memory) on function virtual_memory in module psutil:  virtual_memory()     return statistics system memory usage namedtuple     including following fields, expressed in bytes: 

Comments

Popular posts from this blog

SPSS keyboard combination alters encoding -

Add new record to the table by click on the button in Microsoft Access -

CSS3 Transition to highlight new elements created in JQuery -