Skip to content

monit_sys

bchate edited this page Jul 27, 2018 · 1 revision

As a single DC algorithm quite easily monopolize all harware resources, the function monit_sys allows a user to monitor briefly CPU and memory (RAM) activity. Then the user can estimate the level or available resources before to run (or run later) its own script. The function takes only one argument:

  • proc_time: monitoring time (in seconds, 10 by default)

You may have to install psutil library:

source /home/sdcuser/Datacube/datacube_env/bin/activate
pip install psutil

The function will first display live used percentage bars, and finally display average values.

If you have credentials for the Swiss Data Cube, you can play with a demo script at http://sdc.unepgrid.ch:8080/notebooks/demo_FUN_monit_sys.ipynb

The code and the demo jupyter notebook script can be found here

Clone this wiki locally