hello youtube this is Churchill first 您好YouTube，这是丘吉尔第一
MEP case welcome to another tutorial in MEP案例欢迎阅读的其他教程
this tutorial we're going to be 在本教程中，我们将成为
installing the opencv computer vision 安装opencv计算机视觉
libraries into the Raspberry Pi and we 库加入Raspberry Pi，我们
have a long tutorial so let's get 有一个很长的教程，让我们开始吧
started the first thing you need to do I 开始了您需要做的第一件事
did this so so you're able to follow 这样做是为了让您能够跟随
also also I'm doing the commands make 我也在做命令
sure that you have SSH enable in your 确保您的服务器中启用了SSH
recipe config if you don't know how to 如果您不知道如何配置食谱
do this it's just you just enter that 这样做只是您输入
command su the recipe config and make 命令su配方配置并进行
sure the SSH is enabled and make sure 确保启用了SSH并确保
the camera is also enabled because you 相机也已启用，因为您
will be using the camera a lot and for 将大量使用相机，并且
this we need the SSH is so you can SSH 这是我们需要的SSH，因此您可以SSH
from your desktop or from another 从您的桌面或其他
computer and so you don't have to do 电脑，所以您不必做
around the pie itself and that's why 围绕馅饼本身，这就是为什么
it's so important okay so let's let's 非常重要，所以让我们
assume the URLs completely outside so 假设网址完全在外部，因此
I'm gonna get out clear so you're in 我要出去弄清楚你在
your desktop this is my desktop right 您的桌面，这是我的桌面
here okay so you're going to enter this 好的，所以您要输入这个
command with your IP address I don't 用你的IP地址命令
know what your IP address is so yours is 知道你的IP地址是什么
going to be different from mine you're 与我不同
going to do sssh dash X PI or in your 要做sssh dash X PI或在你的
case your username my username is PI and 如果您的用户名是PI，
the IP address and then it's going to IP地址，然后
ask you for your password this is the 询问您的密码，这是
password that you enter when you were 您当时输入的密码
configuring the Raspberry Pi when you 在您配置Raspberry Pi时
did the first boot so you enter your 做了第一次启动，所以你输入你的
your 你的
your password you enter and now you're 您输入的密码现在
inside your pie okay now your SSH in 在你的馅饼里面好吧，现在你的SSH在
inside the pie so what you need to do is 在馅饼内部，所以您需要做的是
make sure you enter these commands sudo 确保您输入以下命令sudo
up update and oops wrong one 向上更新并出错
I think copy so I get update and it's 我认为是副本，所以我得到了更新，它是
going to update everything making sure 要确保一切都更新
that everything is up-to-date and when 一切都是最新的，何时
this is done 这个做完了
it's going to take a little slow today 今天要慢一点
when you're dealing with the pie it's 当您处理馅饼时
going to be a little bit slower 会慢一点
depending on your how fast your 取决于您的速度
connections are on you we shouldn't take 连接在你身上，我们不应该接受
too long and too soon it's almost done 太久太快就要完成了
and then it's done so now so up get up 然后完成，所以现在起床
pray and you make sure you upgrade to 祈祷，并确保您升级到
have a clean file to work from and the 有一个干净的文件可以工作，并且
first thing I if you have the camera 第一件事，如果你有相机
installed or if you don't have it 已安装或没有安装
installed you can install it now and 已安装，您可以立即安装
after you have it installed make sure 安装后请确保
that your your operating system is 您的操作系统是
reading it as you can see my webcam is 阅读它，因为您可以看到我的网络摄像头是
right there okay so make sure that that 就在那里，所以请确保
is reading it because a lot of the 正在阅读它，因为很多
problems sometimes it doesn't read it 问题有时它不读
you might be missing a driver this is a 您可能缺少司机，这是一个
good time to check because that way you 是检查的好时机，因为这样您
don't you don't go through all of these 难道你不经历所有这些
steps and then and then oops and and 步骤，然后然后oop和
then you don't you don't have it 那你就不拥有它
properly installed and it's not reading 正确安装，它没有阅读
it okay so make sure you do that first 好的，请确保您先这样做
and let me clear this and now one way to 让我清除这个，现在是一种方法
check to make sure that everything is 检查以确保一切正常
working is by installing this this nice 工作是通过安装这个很好的
little program is free it's open source 小程序是免费的，它是开源的
it's really nice you be see you 看到你真是太好了
and you can check to make sure that is 您可以检查以确保
working as you can see it opened you can 看到它打开就可以了
record you can do this is right next 记录下您可以执行的操作就在接下来
next where I am right I have the camera 接下来我在对的地方我有相机
as you can see you can capture you can 如您所见，您可以捕捉到您可以
capture video take the images but this 捕获视频拍摄图像，但这
is a good way to check to make sure that 是检查以确保
everything is working properly and it's 一切工作正常，这是
a nice program to have you can use it 一个不错的程序让您可以使用它
for other things later this is a nice 对于其他事情，这是一个不错的选择
open source okay so let's continue so 开源好吧，让我们继续
let's clear all this stuff and now you 让我们清除所有这些东西，现在你
hear 听
you're gonna install synaptic I don't 你要安装突触，我不
use in optical smudge but some people to 用于光学涂抹，但有些人
install packages this it makes it a lot 安装软件包，这使得它很多
easier from the from the pipe you can 从管道可以轻松完成
install it here after you're done with 完成后在这里安装
that one you're going to install numpy 你要安装numpy的那个
already comes with the with the PI PI已随附
belief so you're only installing this in 信念，所以你只安装在
reality these are nice to have this one 现实这些很高兴拥有这个
is nice to have especially if you're 很高兴有，特别是如果你
going to be doing some machine learning 要做一些机器学习
and all the good stuff tracking and so 以及所有的好东西跟踪等等
you go here copy paste 你去这里复制粘贴
and it's going to install them it might 并且将要安装它们
take a while for you mine I already have 等我一会儿
a mole installed and now this is your 安装了一颗痣，现在这是你的
going to go and get the download this 要去下载这个
zip or the tar file could be at our GC zip或tar文件可以在我们的GC中
file I don't know in your what's going 文件我不知道你怎么回事
to be when you do it for you go ahead 当你为你做的时候
here paste and it's going to be a sip 在这里粘贴，这将是一个小口
file and then you hit enter and it's 文件，然后按Enter键，
going to start downloading as you can 尽可能开始下载
see saving to these and is going it's 看到保存到这些，并正在
going to take a while I'm going to stop 我要停一会儿
mine because I already have it 我的，因为我已经拥有了
downloaded so I'm going to ctrl C on it 下载了，所以我要在上面按ctrl C
and but in your case it might take a 但是在您的情况下，可能需要
little bit to download just be patient 一点点下载只是耐心点
once it's all downloaded you're going to 一旦全部下载，您将转到
enter this command right here this is 在这里输入此命令
very important here this is your C make 非常重要，这是您的C make
that you're going to need for the 您将需要的
compilation and the bill essential 汇编和基本法案
dependencies so make sure you get this 依赖关系，所以请确保您得到了
one and then it's going to take a little 一个，然后要花一点时间
bit mine I already have it installed we 我的位已经安装了
continue now we're going to do Java for 继续现在，我们将为
Java support and and the Java Java支持和Java
development kit hit enter 开发套件点击进入
and he should do it next one gtk 而且他应该在下一个gtk做
development paste and make sure you put 开发粘贴，并确保您将
the s this is no you know is pseudo and s这不是你所知道的是伪的
it's going to do it these are very 要做的这些非常
important right here I'm gonna do all of 重要的是，在这里我要做所有的事情
them on one chart bison very important 他们在一图野牛上非常重要
QT for you can do QT 5 I am doing QT for 您可以进行QT的QT 5我正在进行的QT
it's up to you 由你决定
b4l this is video for Linux this is very b4l这是Linux的视频，非常
important all of these things if you 所有这些重要的事情，如果你
don't have any of these things in a lot 这些东西很多都没有
of the errors are because you're missing 错误的原因是您丢失了
some of these so make sure you get all 其中一些，所以请确保您得到所有
of them and it's going to install vison 其中的，它将安装vison
it's already install it now it's 它已经安装了，现在
installing installing the Qt development 安装安装Qt开发
installing video for Linux and it's 为Linux安装视频，
going to install QT creator QT clear you 将要安装QT Creator QT清除您
don't really need to have it but it's a 真的不需要它，但这是一个
nice it's a nice one to have if you 不错，如果您有一个不错的选择
don't have a an ID 没有ID
I really have it installed let me clean 我真的已经安装好了让我清洁
these a little bit so you can see better 这些一点，所以你可以看到更好
so now we are really done with all of 所以现在我们真的完成了所有
these we already did all that so now 这些我们现在已经做了所有的事情
we're ready for compilation so now we're 我们已经准备好进行编译，所以现在我们
ready to compile that folder that we got 准备编译我们得到的文件夹
here this one right here we're ready to 这是这里，我们已经准备好
compile it okay so let's look for it and 编译好吧，让我们寻找它，
mine is called CD open CV regular 我的被​​称为CD Open CV Regular
because I have two versions of open CV 因为我有两个版本的CV
LS and there it is this one you're not LS，这不是你
going to have it yet because we're going 要拥有它，因为我们要
to make that one so you're going this is 做那个，所以你要去的是
what you download it from here okay when 你从这里下载的东西好吗
you download it that you got this red 您下载它得到了这个红色
zip file right here so now we're going zip文件就在这里，现在我们要开始
to unzip it you could either use on sip 解压缩它，您可以在Sip上使用
you can use if is if you got a tar GC 如果有焦油GC，可以使用if is
you could tie it with the xB I mean you 你可以把它和xB绑在一起
guys know all this stuff I mean you're 伙计们都知道我是说你
doing if you're watching these videos 如果您正在观看这些视频
you know how to open a file so once you 你知道如何打开文件，所以一旦你
unzip you're going to get this folder 解压缩您将获得此文件夹
right here and you're going to change 就在这里，您将要改变
directory into it okay 目录就可以了
open and now you're inside inside you're 打开，现在你在里面
going to list and you're going to have 将要列出，你将有
everything that I have here except that 我在这里拥有的一切，除了
build directory you're not going to have 不需要的构建目录
that yet you're going to make it now 那你现在就要做
okay so make believe that this is not 好吧，所以要相信这不是
there okay so now we're going to make it 那里好，所以现在我们要做到
you're going to go make 你要去做
directory built and for me it's telling 建立目录，对我来说
me dude you already have it so in your 我伙计，你已经拥有它了
case is not going to give me an error 案件不会给我一个错误
because it's not going to give you an 因为它不会给你一个
error because you would not have hi okay 错误，因为您不会打招呼
so now you're going to change the 所以现在您要更改
rectory into the bill directory and 进入账单目录
there's gonna be a bunch of stuff there 那里会有很多东西
not all of these stuff is going to be 并非所有这些东西都会
there yet for you okay so if you don't 那里还可以，所以如果你不这样做
see that don't panic it's not supposed 看到不要惊慌，这不应该
to be there you're going to compile it 到那里你要编译它
to you're going to do that now so you'll 你现在就要做，所以你会
make sure you do this so now we're here 确保您这样做，所以现在我们在这里
okay so now you're going to copy and 好吧，现在您要复制并
paste I'm gonna include this into the 粘贴，我要把这个包括进去
description of this video copy and paste 此视频复制和粘贴的说明
in here and you're going whoops 在这里，你会大声疾呼
and pull see I got I don't want this 拉我明白我不要
will rule it was studying to make pink 会裁定它正在研究使粉红色
it again for me I already have it made 对我来说，我已经拥有了
so I don't want to make it I don't want 所以我不想做，我不想
to build again it takes too long it's 重新建造需要很长时间
going to take a while for you let me 你要花点时间让我
clear this so it's gonna take a while 清除这个，要花一点时间
for you so these this step right here is 对您来说，这些步骤就在这里
going to take about I think about 45 大约要我想到45
minutes more or less and after you're 分钟或更少，然后
all done it's going to configure it's 全部完成，将对其进行配置
going to make sure that you have 要确保你有
everything ready 一切准备就绪
and then after you you it says to you 然后在你之后，它对你说
that everything is fine no errors you're 一切都很好，没有错误
going to do make and it's going to start 将要制造，它将开始
making 制造
and you hit enter in my case they're 在我的情况下，您按回车键
already made for me as you can see 如你所见，已经为我做了
they're already built so in your case 他们已经建成，所以在您的情况下
it's going to start building them okay 它会开始建立它们的
so don't panic if it's taking longer 所以要花更长的时间不要惊慌
than me I already have them all built so 比我，我已经把它们都建好了
in your case they're not gonna be it's 在你的情况下，他们不会是
gonna take a long time I must warn you 要花很长时间我必须警告你
it's gonna take about seven hours for 要花大约七个小时
for for for you to have all of these 为了让您拥有所有这些
done it took me about seven hours so you 花了我大约七个小时，所以你
can do it overnight make sure that you 可以在一夜之间做到这一点，确保您
you do make and then you can go to sleep 你做了，然后你可以去睡觉
and then you can do the installation the 然后您可以进行安装
next day but don't don't go to sleep 第二天，但不要睡觉
after this one after here make sure you 经过这一个之后，请确保您
go to sleep after this one okay because 睡一觉之后就去睡觉，因为
if you if there are errors here you you 如果你在这里有错误你
you won't be a way to to correct them 您将无法纠正它们
okay but once you hit make then you can 好的，但是一旦您按下make，就可以
go in and do something for seven hours 进去做一些事七个小时
because that's exactly that's more or 因为那不只是
less than what's going to take okay 少于需要的一切
after is after it's made you're going to 在完成之后，您将要
see now these are all the built targets 现在看到这些都是已建立的目标
that I already have built and at the end 我已经建立的，最后
is going to tell you a hundred percent 会告诉你百分之一百
and I shouldn't have hit make staking 我不应该打桩
longer than I wanted to but I just 比我想要的更长，但我只是
wanted you to have a clear idea of 希望您有一个清晰的主意
what's going on because this could be if 这是怎么回事，因为这可能是
you have never done this this this this 你从来没有这样做过
could be frustrating okay so now it's a 可能会令人沮丧，所以现在是
hundred percent built everything is fine 百分百地建造，一切都很好
you're ready to install so you're going 您已经准备好安装，所以您要
to do here you're going to do slow 在这里做，你会做的很慢
make install and you're going to hit 进行安装，您将受到打击
enter in my case I'm not going to hit 以我为例，我不会打
enter because I don't want to have to 输入，因为我不想
wait for it make sure you put sudo if 等待它，确保您将sudo放入
you don't put sudo and you only put 你不放须藤，你只放
making stall it's going to go through 使失速将要经历
the whole process and then at the end 整个过程，然后最后
it's going to tell you you lack 它会告诉你你缺乏
sufficient privileges so don't do that 足够的特权，所以不要那样做
make sure you put sudo so you only do it 确保你放了sudo所以你只做
once ok and after all that is done it's 一旦确定，一切都完成了
going to tell you it's all done then you 告诉你一切都完成了，然后你
get out and we're going to do one of the 出去，我们将要做其中一项
most important steps here you're going 这里最重要的步骤
to do copy and you're going to open that 进行复制，然后您将打开它
file sudo open this file right here open sudo文件在此处打开此文件
CV Kampf which is fun in the e.t.c CV Kampf等有趣
directory in the LDCs or compte 最不发达国家中的目录或compte
directory and you're going to find that 目录，您将发现
file right here ok you're going to open 文件在这里好，你要打开
it and it's yours is going to be empty 它和你的将是空的
and you're going to put these things 你将把这些东西
inside of it ok you're going to put that 在里面好吧，你要把那个
user - local - library lip ok and then 用户-本地-库，然后单击确定
you're going to go here you're going to 你要去这里，你要去
roll control X to exit and in your case 滚动控件X退出，在您的情况下
it's going to ask you do you wanna save 它会问你想要保存吗
and you say yes let me do it so you know 你说是的，让我做，所以你知道
you're going to go after you put it in 你把它放进去之后
you're going to say control 0 to control 你会说控制0控制
all to save it's going to ask you do you 一切为了节省它会问你
want to save it yes by hitting Enter 想要通过单击Enter保存它
so it tells you you saved it one line 所以它告诉您您将其保存了一行
you saw it saved one line and now you 你看到它保存了一行，现在你
want to exit so control X hang you out 想退出，所以控制X将您挂出
now you're ready for the next one now 现在您已经准备好下一个
you're going to do sudo LD config 您将执行sudo LD配置
and then hit enter I'm not going to do 然后按回车我不会做
that because I is - already configured 那是因为我-已配置
and he's going to configure okay then 然后他要配置好
you're going to do this one this is very 您将要执行此操作，这非常
important here you're going to go here 重要的是你要去这里
sudo nano sudo nano it's like a TC patch sudo nano sudo nano它就像一个TC补丁
patch RC enter and you're going to get RC补丁进入，您将获得
this huge file here you're going to go 这个巨大的文件，你要去
all the way to the end after this block 一直到该块之后的终点
right here see if NFI does that block 就在这里看看NFI是否可以阻止
after the block at the end you're going 在最后的障碍之后，你要去
to insert these two lines okay I'm going 插入这两行好吧我要
to include them and you've a in my 包括他们，你在我的
description here these two these two 这里描述这两个这两个
lines right here and you're gonna put 行在这里，你要放
them in delete 他们在删除
local control eggs to exit 本地控制鸡蛋退出
yes 是
big yes yes yep okay 大是是是好的
and now you're going to go here open 现在你要去这里开
you're going to find it see the opencv 你会发现它看到opencv
regular Alessi the open three and now 常规阿莱西公开赛三场，现在
you're going to look for the samples 您将要寻找样品
file so let's see these samples and then 文件，所以让我们看看这些样本，然后
you're going to find the C file okay 你会发现C文件没问题
because we're now we're going to try to 因为我们现在要尝试
make sure that the examples are working 确保示例正常工作
oh I forgot to tell you after here after 哦，我忘了在这里之后告诉你
you do these here well we're gonna do it 你在这里做得很好，我们要去做
now okay I went a little bit ahead of 现在好了，我提前了一点
myself so CDC LS and you're going to 我自己，所以CDC LS，您将
look for this file right here you see 在这里找到这个文件
these file right here yours is it might 这些文件在这里是您的
not be yellow because you're going to 不是黄色的，因为你要
make a yellow with this command and 用这个命令变黄
you're going to do chmod make it 你要去做chmod
executable this file that's what you're 可执行文件就是你
doing this batch file you're making this 做这个批处理文件，你正在做这个
batch file you're making an executive oh 批处理文件，您要成为主管哦
okay oops this is the last one 好的，这是最后一个
I can't type today so you go calm pitch 我今天不能打字，所以你要保持冷静
is chmod making it executable and once chmod使它可执行，并且一次
you make it executable you hit Enter in 您将其设为可执行文件，然后按Enter
my case I already it's already yellow so 我的情况我已经是黄色了
it's already executable as you can see 如您所见，它已经可执行
so I'm not going to do it again so in my 所以我不会再做一次
case I'm just going to run it built and 情况下，我只是将其构建并运行
all Sh 全部Sh
oops no Sh and you use hit enter and 哎呀没有嘘，您使用回车键和
it's going to build them okay it's going 这将建立他们，好吧
to compile oh okay and then ah it's 编译好吧，然后啊，
going to build them and then once 要建立它们，然后一次
they're built you're ready to try them 他们已经建成，您已经准备好尝试它们
so let's try one of them which one 所以让我们尝试其中之一
should we try let's try face detect this 我们应该尝试让我们尝试面部检测吗
one right here okay and in order to run 一个就可以了，为了运行
a binary in in C C++ and executable C C ++中的二进制文件并可执行
sorry all you need to do is dot slash or 对不起，您需要做的是点斜线或
forward slash and then face detect and 正斜杠，然后面部检测并
if you have your camera facing you it's 如果您的相机面对您，那是
going to detect that now my camera is a 要检测到现在我的相机是
you saw it before is somewhere else so 你之前看过的东西在别的地方
it's looking for to detect but it's kind 它正在寻找检测，但这是一种
of dark so it's coming up actually is 黑暗，所以它实际上是
trying to detect things detecting okay 试图发现事物检测还可以
so it is working and if if you seeing 所以它正在工作，如果您看到
this everything is fine if you're not 如果你不这样做，这一切都很好
seeing this something is wrong and you 看到这是错误的，你
need to get back and make sure that that 需要回来并确保
you follow all you can leave me comments 你按照所有可以留下我评论
you can ask questions you can see my 你可以问一些问题，你可以看到我的
other tutorial where I am I did one for 我在哪里的另一本教程
for Linux Ubuntu you can check in my 对于Linux Ubuntu，您可以在
other tutorials and you can check my my 其他教程，你可以检查我的
get github and and even in the github I 得到github，甚至在github我
have my email there so you can any any 有我的电子邮件在那，所以你可以任何
trouble just let me know I'm always 麻烦让我知道我永远
happy to help you if you need any help 如果您需要帮助，很高兴为您提供帮助
okay but like always thank you for 好的，但是像往常一样感谢您
watching this video if you liked this 观看此视频（如果您喜欢）
video please click the like box and 视频，请点击“喜欢”框，
subscribe to my channel 订阅我的频道
and thank you for spending these 并感谢您花费这些
20-something minutes with me take care 和我一起20分钟左右
have a great day 祝你有美好的一天