GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - 2kai2kai2/node-ps-data: A native C++ NodeJS addon for getting data on process resource consumption without without the need for additional processes.

BranchesTags
Open more actions menu

Latest commit

 

History

55 Commits
55 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
.vscode
.vscode
 
 
test
test
 
 
.clang-format
.clang-format
 
 
.gitattributes
.gitattributes
 
 
.gitignore
.gitignore
 
 
.npmignore
.npmignore
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
binding.gyp
binding.gyp
 
 
index.d.ts
index.d.ts
 
 
index.js
index.js
 
 
lib.h
lib.h
 
 
lib_linux.cc
lib_linux.cc
 
 
lib_mac.cc
lib_mac.cc
 
 
lib_nvidia.h
lib_nvidia.h
 
 
lib_nvidia_nvml.cc
lib_nvidia_nvml.cc
 
 
lib_nvidia_stub.cc
lib_nvidia_stub.cc
 
 
lib_win.cc
lib_win.cc
 
 
napi.cc
napi.cc
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
tsconfig.json
tsconfig.json
 
 

Repository files navigation

node-ps-data

Build Release NPM version NPM downloads License GPL-3.0

Get data about process resources without executing terminal commands

  • That's right. Unlike existing tools, this module directly retrieves data about processes without needing to open a new shell and wait for a terminal command's response.
  • Supports Windows, Linux, and MacOS
  • NodeJS module written in C++
  • Prebuilt binaries for linux-x64, win32-x64, darwin-x64, and darwin-arm64 (Darwin is the MacOS kernel)

Features

  • cpuUserTime(pid): Get user-mode CPU usage for a process in milliseconds.
  • cpuKernelTime(pid): Get kernel/system-mode CPU usage for a process in milliseconds.
  • cpuTime(pid): Get total CPU usage for a process in milliseconds (equivalent to cpuUserTime(pid) + cpuKernelTime(pid)).
  • memInfo(pid): Get current memory usage for a process in bytes.
  • memRSS(pid): Get current memory resident/working set size for a process in bytes.
  • fileRead(pid): Get total file read size for a process in bytes.
  • fileWrite(pid): Get total file write size for a process in bytes.
  • NvidiaGPU.allGPUs(): Get handles for all Nvidia GPUs (total, not process-specific data)

Installation

npm install node-ps-data

Known Issues and Future Plans

  • Build more binaries for other platforms and architectures.
  • More library functions:
    • CPU/Memory subcategories (e.g. child process time, pages info, etc.)
    • Network usage
    • Process-specific GPU memory and usage
    • More!

About

A native C++ NodeJS addon for getting data on process resource consumption without without the need for additional processes.

www.npmjs.com/package/node-ps-data

Topics

nodenode-addonnode-modulenodejs-modulespidprocessps

Resources

Readme
GPL-3.0 license
Activity

Stars

5 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.