38

TensorFlow 1.9终于对树莓派张开了怀抱:加入官方支持

 6 years ago
source link: https://www.jiqizhixin.com/articles/tensorflow-1-9-officially-supports-the-raspberry-pi?amp%3Butm_medium=referral
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

M3AFZnZ.png!web

2015 年首次推出 TensorFlow 时,我们的初衷是希望它成为一个面向所有人的「开源机器学习框架」。为此,我们想在拥有更多用户的平台上运行。一直以来,我们支持 Linux、MacOS、Windows、iOS 和安卓。然而,尽管很多贡献者不懈努力,在树莓派上运行 TensorFlow 还是很艰难。现在,由于与树莓派基金会的合作,我们很高兴地告诉大家,可以使用 Python pip 包系统从预先构建的二进制文件中在树莓派上安装 TensorFlow 1.9 了!如果正在运行 Raspbian 9(stretch),你可以通过从终端运行以下两个命令来安装它:

sudo apt install libatlas-base-dev
pip3 install tensorflow

然后就可以运行 python3,可以在任何你想用的平台上使用 TensorFlow,下面是简单的「hello world」的例子

# Python
import tensorflow as tf
tf.enable_eager_execution()
hello = tf.constant(‘Hello, TensorFlow!’)
print(hello)

如果系统输出如下,就可以开始编写 TensorFlow 程序了:

如果想了解在 TensorFlow 网站的树莓派上安装 TensorFlow 及故障解决的更多细节,请戳:https://www.tensorflow.org/install/install_raspbian

TensorFlow 支持树莓派令人感到兴奋,因为后者拥有诸多富有创造力的开发者,在编程教学方面也有广泛应用。因此,简化 TensorFlow 的安装可以帮助我们将机器学习介绍给更多的人。我们已经看到 DonkeyCar 等平台使用 TensorFlow 和树莓派创造自动驾驶玩具汽车。二者结合的难度已经降低,我们迫不及待想看到新项目的启动。

Eben Upton 是树莓派的创始人,他说:「现代计算机教育必须兼顾基础知识和前沿话题。考虑到这一点,我们很高兴能与谷歌合作,将 TensorFlow 机器学习移植到树莓派平台上。我们希望看到各个年龄的孩子们用它创造有趣的应用。」我们非常同意他的观点!

我们希望看到更多的教材和教程出现,能够帮助越来越多的人在这个经济、灵活的设备中探索机器学习的可能性。

原文链接:https://medium.com/tensorflow/tensorflow-1-9-officially-supports-the-raspberry-pi-b91669b0aa0


Recommend

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK