11集干货必看!在Docker上编译tensorFlow Lite MCU例子工程-《MCU嵌入式AI开发笔记》

【11集在Docker上编译tensorFlow Lite MCU例子工程-《MCU嵌入式AI开发笔记》】

这一集咱们一步一步的在doc下面编译TensorFlow Lite的例程

https://tensorflow.google.cn/lite/tutorials?hl=zh-cn

进入这个例子:

https://codelabs.developers.google.cn/codelabs/sparkfun-tensorflow#0

进入下一步:重点研究。

3. Set up your software

Download the TensorFlow repo

The code is available in the TensorFlow repository on GitHub, in the following location:

https://github.com/tensorflow/tensorflow/tree/master/tensorflow/lite/micro

cd ~ # change into your home (or any other) directory

git clone --depth 1 https://github.com/tensorflow/tensorflow.git

cd tensorflow

上面这个命令,我们需要在docker下面完成。

我们在cmd下面执行:

docker run -it --rm -p 8888:8888 registry.cn-hangzhou.aliyuncs.com/denverdino/tensorflow:latest

或者我们启动docker tesktop,直接在desktop下面启动应该也是可以的:

我们直接点击terminal

在命令行下面输入命令:

git clone --depth 1 https://github.com/tensorflow/tensorflow.git

/bin/sh: 9: git: not found

没有找到git,这样我们需要安装git。因为我们安装了ubuntu环境,所以我们用apt-get update命令更新一下

这样我们应该可以用git了。

git clone --depth 1 https://github.com/tensorflow/tensorflow.git

芭比Q了

我们用如下命令:

git clone https://github.com/tensorflow/tensorflow.git

等待下载结束。

还是出错了,最后切回之前的命令:

下载成功了。

之后

Download Python dependencies

We'll be using Python 3 to prepare our binary and flash it to the device. The Python scripts depend on certain libraries being available. Run the following command to install these dependencies:

pip3 install pycrypto pyserial --user

出错了。

我们在该文档的开始,介绍了需要安装的软件环境,

我们逐一检查一下:

之后检查make

make --version

发现版本不对。

apt-get install -y make 4.2.1

等待吧,要一段时间

pip3也要安装,ubuntu没有pip3,只能安装python3-pip

apt-get install -y python3-pip

应该安装完成。

之后我们在返回执行Download Python dependencies这一步。

pip3 install pycrypto pyserial --user


又出问题了,好像是python版本 pip版本都升不上去了,有可能是镜像的问题。

咱们继续查找原因。

下次学习:如何更改Docker 下的默认make pip python版本。

相关推荐
zm-v-1593043398638 分钟前
ArcGIS 水文分析升级:基于深度学习的流域洪水演进过程模拟
人工智能·深度学习·arcgis
拓端研究室2 小时前
视频讲解|核密度估计朴素贝叶斯:业务数据分类—从理论到实践
人工智能·分类·数据挖掘
灵智工坊LingzhiAI2 小时前
人体坐姿检测系统项目教程(YOLO11+PyTorch+可视化)
人工智能·pytorch·python
昨日之日20062 小时前
Video Background Remover V3版 - AI视频一键抠像/视频换背景 支持50系显卡 一键整合包下载
人工智能·音视频
SHIPKING3933 小时前
【机器学习&深度学习】什么是下游任务模型?
人工智能·深度学习·机器学习
Johny_Zhao5 小时前
Docker + CentOS 部署 Zookeeper 集群 + Kubernetes Operator 自动化运维方案
linux·网络安全·docker·信息安全·zookeeper·kubernetes·云计算·系统运维
zwjapple6 小时前
docker-compose一键部署全栈项目。springboot后端,react前端
前端·spring boot·docker
子燕若水7 小时前
Unreal Engine 5中的AI知识
人工智能
极限实验室8 小时前
Coco AI 实战(一):Coco Server Linux 平台部署
人工智能
代码老y8 小时前
Docker:容器化技术的基石与实践指南
运维·docker·容器