Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jtop crashes when no power mode is configured #567

Open
SijmenHuizenga opened this issue Aug 29, 2024 · 2 comments
Open

jtop crashes when no power mode is configured #567

SijmenHuizenga opened this issue Aug 29, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@SijmenHuizenga
Copy link

Describe the bug

The jtop service crashes with the following error: name=self._nvpmodel_now['name'] TypeError: 'NoneType' object is not subscriptable

To Reproduce

  1. Install jetson_stats sudo pip3 install -U jetson-stats
  2. sudo systemctl restsart jtop.service
  3. The service crashes

Additional context

Add any other context about the problem here.

Board

Output from jetson_release -v:

Software part of jetson-stats 4.2.9 - (c) 2024, Raffaello Bonghi
Model: NVIDIA Jetson Orin NX Engineering Reference Developer Kit - Jetpack 6.0 [L4T 36.3.0]
Traceback (most recent call last):
  File "/usr/local/bin/jetson_release", line 8, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.10/dist-packages/jtop/jetson_release.py", line 65, in main
    name=bcolors.bold(nvpmodel_now['name']),
TypeError: 'NoneType' object is not subscriptable
  • jetson-stats version: 4.2.9
  • P-Number: ?
  • Module: NVIDIA Jetson Orin NX
  • Jetpack: 6.0
  • L4T: 36.3.0

Log from jtop.service

Attach here the output from: journalctl -u jtop.service -n 100 --no-pager

Started jtop service.
[INFO] jtop.service - jetson_stats 4.2.4 - server loaded
[INFO] jtop.core.hardware - Hardware detected aarch64
[INFO] jtop.core.hardware - NVIDIA Jetson 699-level Part Number=699-13767-0001-300 R.1
[INFO] jtop.core.hardware - NVIDIA Jetson Module=NVIDIA Jetson Orin NX (8GB ram)
[INFO] jtop.core.hardware - NVIDIA Jetson detected L4T=36.3.0
[INFO] jtop.service - Running on Python: 3.10.12
[INFO] jtop.core.cpu - Found 6 CPU
[INFO] jtop.core.gpu - NVIDIA SMI exist!
[WARNING] jtop.core.gpu - No NVIDIA GPU available
[INFO] jtop.core.processes - Process service started
[INFO] jtop.core.memory - Found EMC!
[INFO] jtop.core.memory - Memory service started
[INFO] jtop.core.engine - Special Engine group found: [dlaX]
[INFO] jtop.core.engine - Special Engine group found: [pvaX]
[INFO] jtop.core.engine - Engines found: [APE DLA0 NVDEC NVENC NVJPG PVA0 SE VIC]
[INFO] jtop.core.temperature - Found thermal "cv0" in thermal_zone2
[INFO] jtop.core.temperature - Found thermal "cpu" in thermal_zone0
[INFO] jtop.core.temperature - Found thermal "soc2" in thermal_zone7
[INFO] jtop.core.temperature - Found thermal "soc0" in thermal_zone5
[INFO] jtop.core.temperature - Found thermal "cv1" in thermal_zone3
[INFO] jtop.core.temperature - Found thermal "gpu" in thermal_zone1
[INFO] jtop.core.temperature - Found thermal "tj" in thermal_zone8
[INFO] jtop.core.temperature - Found thermal "soc1" in thermal_zone6
[INFO] jtop.core.temperature - Found thermal "cv2" in thermal_zone4
[WARNING] jtop.core.power - Skipped usb-charger type=USB in=usb-charger
[WARNING] jtop.core.power - Power sensors not found!
[INFO] jtop.core.fan - Fan pwmfan(1) found in /sys/class/hwmon/hwmon1
[INFO] jtop.core.fan - RPM pwm_tach found in /sys/class/hwmon/hwmon2
[INFO] jtop.core.fan - Found nvfancontrol.service
[INFO] jtop.core.jetson_clocks - jetson_clocks found in /usr/bin/jetson_clocks
Traceback (most recent call last):
  File "/usr/local/bin/jtop", line 8, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.10/dist-packages/jtop/__main__.py", line 106, in main
    server = JtopServer(force=args.force)
  File "/usr/local/lib/python3.10/dist-packages/jtop/service.py", line 299, in __init__
    self.nvpmodel = NVPModelService(self.jetson_clocks)
  File "/usr/local/lib/python3.10/dist-packages/jtop/core/nvpmodel.py", line 439, in __init__
    name=self._nvpmodel_now['name'],
TypeError: 'NoneType' object is not subscriptable
jtop.service: Main process exited, code=exited, status=1/FAILURE
jtop.service: Failed with result 'exit-code'.

Log from jetson-stats installation

Output from: sudo -H pip3 install --no-cache-dir -v -U jetson-stats

sudo -H pip3 install --no-cache-dir -v -U jetson-stats
Using pip 22.0.2 from /usr/lib/python3/dist-packages/pip (python 3.10)
Requirement already satisfied: jetson-stats in /usr/local/lib/python3.10/dist-packages (4.2.9)
Requirement already satisfied: distro in /usr/lib/python3/dist-packages (from jetson-stats) (1.7.0)
Requirement already satisfied: smbus2 in /usr/local/lib/python3.10/dist-packages (from jetson-stats) (0.4.3)

RAW Data

File from jtop --error-log attached

at jtop-error.log
--------------------- PLATFORM -------------------------
Machine: aarch64
System: Linux
Distribution: Ubuntu 22.04 Jammy Jellyfish
Release: 5.15.136-tegra
Python: 3.10.12
-------------------- JETSON RAW OUTPUT -----------------
------------------
Path: /etc/nv_tegra_release
# R36 (release), REVISION: 3.0, GCID: 36923193, BOARD: generic, EABI: aarch64, DATE: Fri Jul 19 23:24:25 UTC 2024
------------------
Path: /sys/firmware/devicetree/base/model
NVIDIA Jetson Orin NX Engineering Reference Developer Kit
------------------
Path: /proc/device-tree/nvidia,boardids
No such file or directory
------------------
Path: /proc/device-tree/compatible
nvidia,p3768-0000+p3767-0001nvidia,p3767-0001nvidia,tegra234
------------------
Path: /proc/device-tree/nvidia,dtsfilename
No such file or directory
------------------
Path: I2C-0
FAIL
------------------
Path: I2C-1
FAIL
------------------
Path: I2C-2
FAIL
------------------
Path: I2C-7
FAIL

-------------------- IGPU OUTPUT ---------------------
------------------
Path: /sys/class/devfreq/15380000.nvjpg/device/of_node/name
nvjpg
------------------
Path: /sys/class/devfreq/17000000.gpu/device/of_node/name
gpu
------------------
Path: /sys/class/devfreq/15540000.nvjpg/device/of_node/name
nvjpg
------------------
Path: /sys/class/devfreq/15480000.nvdec/device/of_node/name
nvdec
------------------
Path: /sys/class/devfreq/154c0000.nvenc/device/of_node/name
nvenc
------------------
Path: /sys/class/devfreq/15a50000.ofa/device/of_node/name
ofa
------------------
Path: /sys/class/devfreq/15340000.vic/device/of_node/name
vic


Log from jtop 4.2.9
@SijmenHuizenga SijmenHuizenga added the bug Something isn't working label Aug 29, 2024
@dsconnol-impactai
Copy link

Hey! Just some added info. I had the same issue on a new AGX Orin. It went away after running nvpmodel -m 0 for unrelated reasons. My guess is that the nvpmodel mode isn't set, so it can't get looked up.

@SijmenHuizenga
Copy link
Author

Hi, thanks for the comment @dsconnol-impactai. We also had a misconfigured power mode (sudo nvpmodel -q --verbose gave error). After fixing that, jtop works great.

@SijmenHuizenga SijmenHuizenga changed the title jtop crashes, _nvpmodel_now['name'] NoneType object is not subscriptable jtop crashes when no power mode is configured Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants