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版本。

相关推荐
chaojihaomai2 小时前
AI电商商品图生成中的材质保真问题——扩散模型重建优先级分析与锁定式方案
人工智能·材质
大模型探索者4 小时前
2026 企业智能体平台选型指南:从通用到行业深耕,怎么选?
大数据·人工智能
深圳行云创新5 小时前
北极星知识图谱平台|太空越来越“拥挤”,知识图谱如何预测空间碎片碰撞风险?
人工智能·知识图谱
Am-Chestnuts5 小时前
国产AI多轮对话归档与多格式导出实践
人工智能·word
workflower6 小时前
装备企业的 AI 路线图
人工智能·深度学习·机器学习·设计模式·机器人
AKAMAI6 小时前
Linode接口及默认防火墙现已全面开放使用
人工智能·云计算
前端开发江鸟7 小时前
RAG 回答错了,问题到底出在召回、重排,还是生成?
人工智能
美狐美颜SDK开放平台7 小时前
直播app开发如何实现主播级美颜效果?美颜sdk开发方案详解
人工智能·音视频·美颜sdk·视频美颜sdk·美颜api
东方小月7 小时前
从零开发一个 Coding Agent(四):使用状态机校验大模型事件流
前端·人工智能·后端
大龄码农有梦想7 小时前
使用大模型服务如何保证数据安全?企业 AI 安全、私有化部署与治理实践
人工智能·私有化部署·数据安全·信创·ai agent·智能体·智能体开发平台