nvpmodel -m X

Hello everyone,

I have been using extensively the nvpmodel command on the Jetson but it was not entirely clear what it does and how it really does it.

May I get any clarifications on it?

My many thanks.

Hi maycondouglasd, have you seen this post about nvpmodel?

http://www.jetsonhacks.com/2017/03/25/nvpmodel-nvidia-jetson-tx2-development-kit/

The tool defines profiles stored in configuration files which contain clock governor frequency settings, ect.
You can also create your own profile, or use/modify the ~/jetson_clocks.sh script which has similar settings.

Hi Dusty. Thank you very much for the link. It helped me immensely.

I have benckmarked the performance under the different models of operation and I realized that they also vary in terms of Swappiness. Is there any detailed description of these models available or any example on how to edit the jetson_clocks.sh?

These posts have some info about Max-Q and Max-P:

https://devblogs.nvidia.com/parallelforall/jetson-tx2-delivers-twice-intelligence-edge/
https://devblogs.nvidia.com/parallelforall/jetpack-doubles-jetson-inference-perf/

To customize jetson_clocks.sh, look around for the sysfs files that you are interested in. These query and control the frequency governor behaviors for various parts of the chip. Use the cat tool in a script to set them. See this wiki page for more info: https://elinux.org/Jetson/Performance

Hi Experts

Trying to run nvpmodel but I get an error message:

sudo nvpmodel -m 1
sudo: nvpmodel: command not found

Any hints?

Thanks,

sojohans

Check:

which nvpmodel
ls /usr/sbin/nvpmodel

If the base system is installed correctly you should see all “ok” from:

sha1sum -c /etc/nv_tegra_release

NOTE: See which L4T version you have (early releases didn’t have this program):

head -n 1 /etc/nv_tegra_release

Hi Linuxdev

Here is the results (The shalsum gave ok):

ubuntu@tegra-ubuntu:~ which nvpmodel ubuntu@tegra-ubuntu:~ ls /usr/sbin/nvpmodel
ls: cannot access ‘/usr/sbin/nvpmodel’: No such file or directory
ubuntu@tegra-ubuntu:~ sha1sum -c /etc/nv_tegra_release /usr/lib/xorg/modules/drivers/nvidia_drv.so: OK /usr/lib/xorg/modules/extensions/libglx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libargus_socketserver.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmedia.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvfnetstoredefog.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvdc.so: OK /usr/lib/aarch64-linux-gnu/tegra/libtegrav4l2.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite_video.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm_contentpipe.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnveglstreamproducer.so: OK /usr/lib/aarch64-linux-gnu/tegra/libargus_socketclient.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtvmr.so: OK /usr/lib/aarch64-linux-gnu/tegra/libglx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm_parser.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvfnet.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvwinsys.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvomxilclient.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvddk_vic.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite_utils.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvodm_imager.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcolorutil.so: OK /usr/lib/aarch64-linux-gnu/tegra/libscf.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvrm_graphics.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmm_utils.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcamerautils.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvparser.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvimp.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvos.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvddk_2d_v2.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite_image.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnveglstream_camconsumer.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvfnetstorehdfx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtx_helper.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvexif.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcamlog.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtnr.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvrm.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvosd.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvjpeg.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvtestresults.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvavp.so: OK /usr/lib/aarch64-linux-gnu/tegra/libargus.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcam_imageencoder.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvapputil.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvll.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvcameratools.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvomx.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvmmlite.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvrm_gpu.so: OK /usr/lib/aarch64-linux-gnu/tegra/libnvidia-egl-wayland.so: OK /usr/lib/aarch64-linux-gnu/libv4l/plugins/libv4l2_nvvideocodec.so: OK /usr/lib/aarch64-linux-gnu/libv4l/plugins/libv4l2_nvvidconv.so: OK ubuntu@tegra-ubuntu:~ head -n 1 /etc/nv_tegra_release

R28 (release), REVISION: 2.0, GCID: 10567845, BOARD: t210ref, EABI: aarch64, DATE: Fri Mar 2 04:58:16 UTC 2018

Interesting…R28.2 should have “/usr/sbin/nvpmodel”, and yet the basics are correctly in place. How did you flash the Jetson? Did anything odd occur during the flash?

Hi Linux

I got the following messages (below). After I installed cuda-toolkit-9-0 etc it continued the flash process.

dpkg-query: package ‘cuda-toolkit-9-0’ is not installed and no information is available
dpkg-query: package ‘libfreeimage-dev’ is not installed and no information is available
dpkg-query: package ‘libopenmpi-dev’ is not installed and no information is available
dpkg-query: package ‘openmpi-bin’ is not installed and no information is available
Use dpkg --info (= dpkg-deb --info) to examine archive files,
and dpkg --contents (= dpkg-deb --contents) to list their contents.
1
Error: CUDA cannot be installed on device. This may be caused by other apt-get command running on device when installing CUDA. Please use apt-get command in a terminal to make sure following packages are installed correctly on device before continuing:
cuda-toolkit-9-0 libgomp1 libfreeimage-dev libopenmpi-dev openmpi-bin
After these packages are installed on device, press Enter key to continue

Thanks,
Sojohans

As a clarification, flash never occurs without the micro-B USB cable and being in recovery mode. Flash never uses the ethernet port. When JetPack runs, if it is set to flash, this occurs first, and then the Jetson will reboot itself. Package installs are entirely over wired ethernet and the micro-B USB cable could be removed. So if installing a package flash is already long past.

The file “/usr/sbin/nvpmodel” is not part of extra package install. Actual flash preparation starts by unpacking the sample rootfs in the “Linux_for_Tegra/rootfs/” subdirectory using sudo. Still, no nvpmodel will exist, this is purely Ubuntu. Next, “apply_binaries.sh” is run with sudo…this unpacks hardware-specific drivers and files and is what makes the Jetson capable of direct hardware acceleration. This is also what unpacks nvpmodel into the rootfs. Aside from a few boot configuration edits this rootfs is then turned into a binary file system and copied into the Jetson’s mmcblk0p1 partition.

So you might have problems with CUDA install, but something went wrong prior to ever reaching that step. Problems prior to this might have a later issue when you get to installing CUDA. You need to find out why nvpmodel is missing before moving on the questions of missing CUDA packages. If we find out what went wrong with nvpmodel, then it might also fix CUDA install issues.

Also note that JetPack can install CUDA and other packages on your host. You need to not install anything on the host if you want to debug and simplify. You can always run JetPack again at a later time and install packages to host or Jetson. I will in fact recommend that since things are going wrong that you see what happens when you completely skip JetPack and use command line to flash…then see if nvpmodel exists.

Here is a description of command line flashing (JetPack essentially does this since it is a front end to command line flash and does not have its own ability to flash without the command line driver package):
https://devtalk.nvidia.com/default/topic/1031769/jetson-tx2/unable-install-any-jetpacks-jetson-tx2/post/5249710/#5249710

The URL that is given there currently points to R28.2.1 (that URL tracks the most recent release):
https://developer.nvidia.com/embedded/linux-tegra

Beware that that URL requires you to log in to see the download content. Because of how that page works you need to click on the link, log in, and then click on the link again before you’ll see what you need (the original login won’t redirect correctly to your original login target page).

Once you have nvpmodel we’ll know you have the basis to correctly get CUDA and other software running. Without that everything is suspect.

This is a Jetson-TX1, not a Jetson-TX2. nvpmodel is TX2-specific.

This is the TX2 forum…I missed that this is a TX1. One of the reasons for nvpmodel is to control the activation/deactivation of the Denver cores…and a TX1 does not have Denver cores, so it is correct that there is no nvpmodel.

Much of the install and flash information is the same between a TX1 and TX2, but device tree will differ. This invalidates a good chunk of the thread. I will suggest starting a new thread in the TX1 forum:
https://devtalk.nvidia.com/default/board/164/jetson-tx1/

Hi all,

Thanks for the clarification…

Sojohans