node-nvidia-smi

Node wrapper around nvidia-smi.

Downloads in past

Stats

StarsIssuesVersionUpdatedCreatedSize
node-nvidia-smi
701.0.06 years ago6 years agoMinified + gzip package size for node-nvidia-smi in KB

Readme

Build Status npm() npm()
node-nvidia-smi
A node wrapper around nvidia-smi. It returns the output of nvidia-smi -q -x formatted as JSON.

Installing

[sudo] npm install [-g] node-nvidia-smi

Usage

Dependency ###

const smi = require('node-nvidia-smi');

smi(function (err, data) {

  // handle errors
  if (err) {
    console.warn(err);
    process.exit(1);
  }

  // display GPU information
  console.log(JSON.stringify(data, null, ' '));
});

CLI ###

If installed globally, a node-nvidia-smi executable is installed on your system PATH.
View example output in the wikiwiki.