Comments (2)
Thank you for the detailed report. It is that your system python is broken, in particular the curses
standard library. You can also reproduce this with
$ python
>>> import curses
so this wouldn't be a problem of gpustat nor any other third-party packages.
I think it's because the minimal EC2 image does not have ncurses installed on the system. Most UNIX system should have ncurses installed by default, but the minimal AMI image does not.
Please try installing ncurses:
sudo apt-get update
sudo apt-get install -y libncurses5-dev libncursesw5-dev
See also https://bugs.python.org/issue43728
from gpustat.
ubuntu@..$ sudo apt-get update
Hit:1 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal InRelease
Get:2 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Get:3 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-backports InRelease [108 kB]
Hit:4 https://nvidia.github.io/libnvidia-container/stable/ubuntu18.04/amd64 InRelease
Hit:5 https://nvidia.github.io/nvidia-container-runtime/stable/ubuntu18.04/amd64 InRelease
Hit:6 https://nvidia.github.io/nvidia-docker/ubuntu18.04/amd64 InRelease
Get:7 http://security.ubuntu.com/ubuntu focal-security InRelease [114 kB]
Get:8 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages [2611 kB]
Get:9 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/main amd64 c-n-f Metadata [16.8 kB]
Get:10 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/universe amd64 Packages [1067 kB]
Get:11 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/universe amd64 c-n-f Metadata [24.9 kB]
Get:12 http://security.ubuntu.com/ubuntu focal-security/main amd64 Packages [2229 kB]
Get:13 http://security.ubuntu.com/ubuntu focal-security/main Translation-en [358 kB]
Get:14 http://security.ubuntu.com/ubuntu focal-security/main amd64 c-n-f Metadata [13.0 kB]
Get:15 http://security.ubuntu.com/ubuntu focal-security/restricted amd64 Packages [1833 kB]
Get:16 http://security.ubuntu.com/ubuntu focal-security/restricted Translation-en [256 kB]
Get:17 http://security.ubuntu.com/ubuntu focal-security/universe amd64 Packages [842 kB]
Get:18 http://security.ubuntu.com/ubuntu focal-security/universe amd64 c-n-f Metadata [18.4 kB]
Fetched 9605 kB in 2s (5386 kB/s)
Reading package lists... Done
ubuntu@..$ sudo apt-get install -y libncurses5-dev libncursesw5-dev
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
libncurses-dev
Suggested packages:
ncurses-doc
The following NEW packages will be installed:
libncurses-dev libncurses5-dev libncursesw5-dev
0 upgraded, 3 newly installed, 0 to remove and 38 not upgraded.
Need to get 342 kB of archives.
After this operation, 2410 kB of additional disk space will be used.
Get:1 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/main amd64 libncurses-dev amd64 6.2-0ubuntu2.1 [340 kB]
Get:2 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/main amd64 libncurses5-dev amd64 6.2-0ubuntu2.1 [984 B]
Get:3 http://eu-west-1.ec2.archive.ubuntu.com/ubuntu focal-updates/main amd64 libncursesw5-dev amd64 6.2-0ubuntu2.1 [988 B]
Fetched 342 kB in 0s (15.1 MB/s)
Selecting previously unselected package libncurses-dev:amd64.
(Reading database ... 147493 files and directories currently installed.)
Preparing to unpack .../libncurses-dev_6.2-0ubuntu2.1_amd64.deb ...
Unpacking libncurses-dev:amd64 (6.2-0ubuntu2.1) ...
Selecting previously unselected package libncurses5-dev:amd64.
Preparing to unpack .../libncurses5-dev_6.2-0ubuntu2.1_amd64.deb ...
Unpacking libncurses5-dev:amd64 (6.2-0ubuntu2.1) ...
Selecting previously unselected package libncursesw5-dev:amd64.
Preparing to unpack .../libncursesw5-dev_6.2-0ubuntu2.1_amd64.deb ...
Unpacking libncursesw5-dev:amd64 (6.2-0ubuntu2.1) ...
Setting up libncurses-dev:amd64 (6.2-0ubuntu2.1) ...
Setting up libncursesw5-dev:amd64 (6.2-0ubuntu2.1) ...
Setting up libncurses5-dev:amd64 (6.2-0ubuntu2.1) ...
Processing triggers for man-db (2.9.1-1) ...
ubuntu@..$
ubuntu@..$
ubuntu@..$ gpustat -i
Traceback (most recent call last):
File "/opt/tensorflow/bin/gpustat", line 5, in <module>
from gpustat import main
File "/opt/tensorflow/lib/python3.10/site-packages/gpustat/__init__.py", line 16, in <module>
from .core import GPUStat, GPUStatCollection
File "/opt/tensorflow/lib/python3.10/site-packages/gpustat/core.py", line 31, in <module>
from blessed import Terminal
File "/opt/tensorflow/lib/python3.10/site-packages/blessed/__init__.py", line 14, in <module>
from blessed.terminal import Terminal # type: ignore
File "/opt/tensorflow/lib/python3.10/site-packages/blessed/terminal.py", line 21, in <module>
from .keyboard import (_time_left,
File "/opt/tensorflow/lib/python3.10/site-packages/blessed/keyboard.py", line 19, in <module>
import curses
File "/usr/local/lib/python3.10/curses/__init__.py", line 13, in <module>
from _curses import *
ModuleNotFoundError: No module named '_curses'
ubuntu@..$
from gpustat.
Related Issues (20)
- Some low-level errors (like `pynvml.nvml.NVMLError_LibRmVersionMismatch`) result in nothing printed (std or diagnostic) HOT 1
- UserWarning: Failed to setupterm(kind='xterm'): setupterm: could not find terminfo database HOT 1
- Support anaconda's legacy pynvml package HOT 7
- How to obtain RPM value for the fans ? HOT 2
- Plugin Architecture
- module 'pynvml' has no attribute '_nvmlGetFunctionPointer' HOT 17
- Truncate the "command" when use "-f" HOT 1
- ModuleNotFoundError: No module named '_curses' HOT 2
- Process not displayed HOT 3
- make appimage format or binary file οΌit can run everywhere HOT 1
- make appimage format HOT 1
- Error on querying NVIDIA devices | OverflowError: Python int too large to convert to C long HOT 9
- gpustat reports only the first program on nv driver 535 HOT 4
- Include GDDR6(X) VRAM temperatures HOT 2
- Show CUDA Driver Version in the output HOT 2
- Enhance gpustat to Display Latest CUDA Version Compatible with Current NVIDIA Driver HOT 4
- Even more compact (single-line) output for statusline use HOT 2
- Misreported used memory with the driver 535.129.03 HOT 3
- /usr/bin/gpustat:6: DeprecationWarning: pkg_resources is deprecated as an API. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google β€οΈ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gpustat.