Giter Site home page Giter Site logo

martinkersner / gtop Goto Github PK

View Code? Open in Web Editor NEW
91.0 6.0 49.0 76 KB

CPU, GPU and memory viewer utilizing information provided by tegrastats

License: GNU General Public License v3.0

Makefile 2.39% C++ 93.80% Shell 3.80%
cpu-monitoring gpu-monitoring memory-monitoring tegra tegrastats jetson jetson-tk1 jetson-tx1 jetson-tx2

gtop's People

Contributors

martinkersner avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

gtop's Issues

std::out_of_range exception

$ sudo ./gtop 
terminate called after throwing an instance of 'std::out_of_range'
                                                                    what():  vector::_M_range_check: __n (which is 1) >= this->size() (which is 1)
                                                                                                                                                  Aborted (core dumped)

I built the code with $ g++ -std=c++14 gtop.cc utils.cc display.cc -o gtop -pedantic -Wall -Wextra -lncurses -lpthread -g
and gdb reveals:

(gdb) bt
#0  0x0000007fb7f0e30c in __pthread_cond_wait (cond=0x423718 <cv>, mutex=0x4236e8 <m>) at pthread_cond_wait.c:186
#1  0x0000007fb7e24e10 in std::condition_variable::wait(std::unique_lock<std::mutex>&) () from /usr/lib/aarch64-linux-gnu/libstdc++.so.6
#2  0x00000000004048dc in std::condition_variable::wait<main()::<lambda()> >(std::unique_lock<std::mutex> &, <lambda()>) (this=0x423718 <cv>, __lock=..., __p=...) at /usr/include/c++/5/condition_variable:98
#3  0x00000000004039d8 in main () at gtop.cc:45

This is on a Nvidia Jetson TX2 with ubuntu 16.04.03 and kernel 4.4.38

Core Dumped

I compiled gtop for jetson tx2 and I'm getting this output:

terminate called after throwing an instance of 'std::invalid_argument'
                                                                        what():  stoi
                                                                                     Aborted (core dumped)

Report: fork zlacelle/gtop works fine, also with Jetson Nano

Reporting success with the fork https://github.com/zlacelle/gtop on my Jetson Nano with sudo gtop --tx2

Installation steps for that fork:

  • Clone from git
  • Modify gtop.hh as follows:
const std::string TEGRASTATS_PATH     = "/usr/bin/tegrastats";
const std::string TEGRASTATSFAKE_PATH = "/usr/local/bin/tegrastats_fake";
  • Copy "fake" bin from source code to local: sudo cp tegrastats_fake /usr/local/bin
  • Compile code with make
  • Copy binary to local with sudo chown root: gtop; sudo mv gtop /usr/local/bin
  • Add alias to .bashrc: alias gt='sudo gtop --tx2'

g++ -std=c++11 gtop.cc utils.cc display.cc -o gtop -pedantic -Wall -Wextra -lncurses -lpthread gtop.cc:192:39: warning: unused parameter ‘d’ [-Wunused-parameter] void display_stats(const dimensions & d, const tegrastats & ts) {

Hi Martin,
I am trying to use your tool of GUI for Tegra TX1.
However I am getting the folling compilation warning

root@tegra-ubuntu:~/gstop/gtop-master# make
g++ -std=c++11 gtop.cc utils.cc display.cc -o gtop -pedantic -Wall -Wextra -lncurses -lpthread
gtop.cc:193:6: warning: unused parameter ‘d’ [-Wunused-parameter]
void display_stats(const dimensions & d, const tegrastats & ts) {

then when I execute the sudo ./gtop. I am getting the following error.
root@tegra-ubuntu:~/gstop/gtop-master# ./gtop
terminate called after throwing an instance of 'std::out_of_range'
what(): vector::_M_range_check
Aborted
Even I have increased the c
const int STATS_BUFFER_SIZE = 1024;

But still nothing works!

This is the output I get from the ~/tegrastats

RAM 748/3854MB (lfb 676x4MB) SWAP 0/0MB (cached 0MB) cpu [14%,43%,11%,12%]@1912 EMC 24%@1600 AVP 82%@13 VDE 0 GR3D 52%@998 EDP limit 1912
RAM 748/3854MB (lfb 676x4MB) SWAP 0/0MB (cached 0MB) cpu [25%,40%,9%,6%]@1912 EMC 19%@1600 AVP 70%@12 VDE 0 GR3D 51%@921 EDP limit 1912
RAM 748/3854MB (lfb 676x4MB) SWAP 0/0MB (cached 0MB) cpu [71%,26%,32%,20%]@1912 EMC 23%@1600 AVP 41%@12 VDE 0 GR3D 83%@921 EDP limit 1912
RAM 748/3854MB (lfb 676x4MB) SWAP 0/0MB (cached 0MB) cpu [96%,27%,38%,30%]@1912 EMC 26%@1600 AVP 13%@12 VDE 0 GR3D 51%@921 EDP limit 1912

Could you please help me fix this problem.

Thanks!

weird graph icons. what am i missing?

i have these weird graph "lines" in gtop; i use this program since 10 years now and never saw that.
this is my regular user running gtop(arch,i3,urxvt,nvidia):

and this is a xterm try.
https://i.redd.it/ledt818hl7711.png

i did export LANG=en_US.utf8 and export TERM=xterm-256color and both are reported in printenv and started xterm or how am i supose to spawn it?
if i just run xterm afterwards it looks exactly the same as before.

have a nice day sir

DLA Support

Any ideas on how to measure DLA utilization on the AGX?

Doesn't seem to be available through tegrastats

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.