GithubHelp home page GithubHelp logo

sauna_'s Introduction

Sauna

A tool to measure energy the consumption of CPUs, GPUs and XeonPhi.

It performs a sequence of power measurements on the different devices during the execution of a given program. Output is produced in tabular form, convenient for graphing.

Prerequisites

The energy measurement of the CPUs is done through the Running Average Power Limit (RAPL). Support for these was added to the Linux kernel since version 3.14.

To access the Nvidia GPUs and XeonPhi, Sauna uses two libraries provided by both manufacturers. From Nvidia, Sauna requires the GDK. And for the XeonPhi, the library is included in the device drivers package.

Building

The Makefile easies the building process. To build the complete Sauna, simply type:

$ make

Building of the Nvidia or XeonPhi modules can be disabled on the command line by setting the value of the corresponding variables, NVIDIA and XEONPHI. These changes can be made permanent by modifying the Makefile directly.

$ make XEONPHI=1 NVIDIA=0

Installation is done by simply copying the 'sauna' binary to a directory in the PATH.

Running

At the very minimum Sauna takes one argument. It is the program to run while it performs the measurements. Without any arguments it shows a brief usage guide. A more detalied user guide can be obtained with '-h'.

Since Sauna requires access to protected devices, it must run with root privileges. This should show the power consumpition for 5 seconds.

$ sudo sauna sleep 5

The default sampling interval is 500ms. Other values can be set with '-i'. However be aware that using short intervals can impose a significant overhead. This is particularly noticeable in Nvidia devices. Evaluation of the overhead is recommended if the interval is lower than 100ms.

By default Sauna takes measurements throughout the execution, but this can be restricted to a \emph{Region Of Interest(ROI)} with '-r'. The ROI is determined by the program itself by special strings written to standard output. Care must be taken in this case to flush the output after printing these strings so that the monitor can read them as soon as possible.

Authors

License

This project is licensed under GNU GPLv3 - see the LICENSE file for details.

Acknowledgments

sauna_'s People

Contributors

esteban-stafford avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.