当前位置:网站首页>Jetson Xavier NX (3) bazel mediapipe installation
Jetson Xavier NX (3) bazel mediapipe installation
2022-04-23 08:09:00 【Nysun11】
One 、 install Bazel
1 - download
2 - Copy and unzip
3 - Installation dependency
sudo apt-get install build-essential openjdk-8-jdk
If you can't locate openjdk-8-jdk Should be apt The source of the problem , Revise it yourself , You can refer to my previous blog
4 - compile
env EXTRA_BAZEL_ARGS="--host_javabase=@local_jdk//:jdk" bash ./compile.sh
It will take longer , Wait patiently ( Turn on maximum performance mode )
5 - The generated bazel Files in PATH Directory
sudo cp output/bazel /usr/local/bin/
Check the
bazel --version
Two 、Mediapipe install
1 - download
git clone https://github.com/google/mediapipe.git
2 - Upload and unzip
3 - Installation dependency
sudo apt install -y python3-dev
sudo apt install -y cmake
4 - Delete unnecessary modules
Get into mediapipe Under the folder , Remove unnecessary modules and flags
cd mediapipe
sed -i -e "/\"imgcodecs\"/d;/\"calib3d\"/d;/\"features2d\"/d;/\"highgui\"/d;/\"video\"/d;/\"videoio\"/d" third_party/BUILD
sed -i -e "/-ljpeg/d;/-lpng/d;/-ltiff/d;/-lImath/d;/-lIlmImf/d;/-lHalf/d;/-lIex/d;/-lIlmThread/d;/-lrt/d;/-ldc1394/d;/-lavcodec/d;/-lavformat/d;/-lavutil/d;/-lswscale/d;/-lavresample/d" third_party/BUILD
5 - modify BUILD file
open /mediapipe/third_party/BUILD
# Locate the
“WITH_WEBP”: “OFF”,
# Add the following two sentences after :
“ENABLE_NEON”: “OFF”,
“WITH_TENGINE”: “OFF”,
6 - modify OpenCV and FFMpeg The compiled file of
stay mediapipe Execute the following code
sed -i "s/x86_64-linux-gnu/aarch64-linux-gnu/g" third_party/opencv_linux.BUILD
sed -i "s/x86_64-linux-gnu/aarch64-linux-gnu/g" third_party/ffmpeg_linux.BUILD
7 - Install compiler protobuf-compiler
download , Note that linux-aarch64.zip ending
And then protobuf-compilerv3.19.1 Medium “bin” and include Under the “google” Copied to the mediapipe Next And modify it mediapipe/setup.py
protoc_command = [self._protoc, ‘-I.’, ‘–python_out=.’, source]
It is amended as follows :( Pay attention to the English format of symbols )
protoc_command = [self._protoc, ‘-I.’, ‘-I/usr/local/include’,’–python_out=.’, source]
8 - gcc Is the version 8, If not, please upgrade ( Failure to upgrade will result in an error , It's all tears , Please be sure to upgrade )
sudo apt-get update
sudo apt-get install gcc-8
sudo apt-get install g++-8
cd /usr/bin
sudo rm gcc g++
sudo ln -s gcc-8 gcc
sudo ln -s g++-8 g++
If you report an error, come back and upgrade gcc, If you continue to execute the compiled file , You'll report a mistake again this rule is missing dependency declarations for the following fles Clean up the cache and continue :
sudo rm -rf ~/.cache/bazel/
9 - compile
Use science as much as possible , Otherwise, the download package will be interrupted or something , Be patient and try again …
stay mediapipe perform :
python3 setup.py gen_protos && python3 setup.py bdist_wheel
After a long time, I will be in a dist Folder generation .whl file
10 - install
Enter your virtual environment ( If there is )
pip install *****.whl
At the end :
The whole process is intermittent many times , Refer to several articles , Thank you
I try to surf the Internet scientifically on the computer and then turn on WiFi To the development board , It turns out that this won't work
I am using python36 If a friend wants mine whl You can send a private message or leave a message
版权声明
本文为[Nysun11]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204230641097759.html
边栏推荐
- [problem solving] vs2019 solves the problem that the EXE file generated by compilation cannot be opened
- C语言学习记录——삼십팔 字符串函数使用和剖析(2)
- RAID0和RAID5的创建和模拟RAID5工作原理
- Essays (updated from time to time)
- MySQL -- the secret of lock -- how to lock data
- 数据库之MySQL——基础篇
- Concours de compétences en informatique en nuage - - première partie de l'environnement cloud privé openstack
- Fibula dynamic programming
- Research on system and software security (5)
- Asynchronous learning
猜你喜欢
随机推荐
巨头押注的全屋智能,正在驱动海信、华为、小米们「自我革命」
vivo,硬件安全的爱与雷霆
Comparison of indoor positioning methods of several intelligent robots
SAP self created table log function is enabled
LeetCoed18. 四数之和
【问题解决】VS2019解决编译生成的exe文件打不开的情况
Mobile terminal layout (3D conversion, animation)
MySQL -- the secret of lock -- how to lock data
Manipulator motion planning in 3C assembly
利用sqlmap注入获取网址管理员账号密码
BUFFCTF文件中的秘密1
Intranet penetration series: ICMP of Intranet tunnel_ Tran
MySQL——第一章节(MySQL中的数据类型)
Redis -- why is the string length of string emstr the upper limit of 44 bytes?
AAAI 2022招募讲者啦!!
php高精度计算
Intranet penetration series: pingtunnel of Intranet tunnel
如何在SQL Server中导入excel数据,2019版
[极客大挑战 2019]Havefun1
User manual of Chinese version of solidity ide Remix
![[极客大挑战 2019]Havefun1](/img/8b/b15bf31771d54db25f24d630e64093.png)


![BUUCTF [极客大挑战 2019]EasySQL1](/img/ad/afca09bc1da003393319af700e90e3.png)





