Missing VPI in Python (VPI 2 DP)

Hello,
I installed JetPack 5.0 DP via SDK-Manager in Ubuntu 18.04 (as host). SDKM said that all things are installed well, inclusive VPI2. Python environment is prepared with Python3.8 via Anaconda3. But

  1. sudo apt remove python3.8-vpi2
  2. Start to install described in VPI - Vision Programming Interface: Installation
  3. At point 3: “sudo add-apt-repository ‘deb https://repo.download.nvidia.com/jetson/x86_64 bionic r34.1’”. apt send me a warning:

W: Das Laden der konfigurierten Datei »r34.1/binary-i386/Packages« wird übersprungen, da das Depot »https://repo.download.nvidia.com/jetson/x86_64 bionic In Release« die Komponente »r34.1« nicht enthält. (Schreibfehler bei der Angabe der Komponente in sources.list?)

Means the repository dosn’t contain r.34.1.

So installation of python3.8-vpi2 not possible.

Can somewhere help?

Hi,

We also provide the packages in the following link:
https://repo.download.nvidia.com/jetson/#Jetpack%205.0

Would you mind installing the VPI python package through the download link to see if it works?

Thanks.

Hi,

Thanks for your reply!

By using your link

I took the VPI2 package under x86_64/bionic in version 2.0.14 Result was

Unpacking vpi2-dev (2.0.14) over (2.0.9) ...
vpi2-dev (2.0.14) is set up ...

Unfortunately in python3 the result is:

(jp5.0-py3.8) ~$ python3
Python 3.8.8 (default, Apr 13 2021, 19:58:26) 
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import vpi
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'vpi'

Are there some folders to copy into anaconda3 folder structure after this installation process? I assume the problem could be that I work inside an anaconda environment and the VPI installer doesn’t recognize this.

Best regards, Frank

Hi,

Do you use a virtualenv?
If yes, could you try it with the --system-site-packages to see if it works?

Ex.

$ virtualenv env --system-site-packages

Thanks.

Hi,
No, I use Anaconda3 environments.
In this case there is a directory “.conda” inside the user home. And inside this folder is only the file “environments.txt” what contains the directory of Anaconda environments. In my case the Anaconda environments are in “/opt/anaconda3”. This is not inside the user home in order to use this environment by all users. All users have access rights into “/opt/anaconda3” by using a special anaconda user group.

So, my environment for using JetPack5 with Python 3.8 is inside this Anaconda folder: /opt/anaconda3/envs/jp5.0-py3.8

The folder structure inside this environment is:

bin
compiler_compat
conda-meta
doc
etc
include
info
lib
libexec
licensing
man
mkspecs
phrasebooks
plugins
qml
resources
sbin
share
ssl
translations
var
x86_64-conda_cos6-linux-gnu

Does the VPI2 installer use such an environment configuration or is this the reason for this problem?
Best regards, Frank

Hi,

Could you try if you can import vpi outside of the Anaconda3 environment?
Thanks.

Yes I tried. I set up a normal python3-environment:

virtualenv --python=/usr/bin/python3.8 /opt/python3_environments/py3.8-jp5.0
source /opt/python3_environments/py3.8-jp5.0/bin/activate

Of course, the user has full access into /opt/python3_environments.

Now Jetpack5.0.1 DP reinstalled.

And checked:

(py3.8-jp5.0) (base) herbrand@fwfe15:~$ python3
Python 3.8.13 (default, Apr 19 2022, 00:53:22) 
[GCC 7.5.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import vpi
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'vpi'
>>> 

Hi,

When setting virtualenv, could you add --system-site-packages to see if it helps?

Thanks.

Hi and thanks!

The setup of the virtual environment with --system-site-packages is necessary.

virtualenv --system-site-packages --python=/usr/bin/python3.8 /opt/python3_environments/py3.8-jp5.0

works for me now. But in this case the installation of some Python packages are needed. For >>> import vpi we need also:

pip numpy.

So the VPI import is successfully.

Thanks, Frank

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.