感谢CSDN活动提供的OrangePi AI Pro ,之前一直用的树莓派,正好体验一下新的国产设备,
1、开机体验
整个设备包装不错,链接键盘、屏幕和鼠标,整体开机体验不错,内置OS不错,这个系统内嵌了中文输入法,中文友好,
2、设备基本参数
OrangePi AIpro(8T)采用昇腾AI技术路线,可广泛适用于AI边缘计算、深度视觉学习及视频流AI分析、视频图像分析、自然语言处理、智能小车、机械臂、人工智能、无人机、云计算、AR/VR、智能安防、智能家居等领域,覆盖 AIoT各个行业。Orange Pi AIpro支持Ubuntu、openEuler操作系统,满足大多数AI算法原型验证、推理应用开发的需求。
CPU 4核64位处理器+ AI处理器(8TOPS算力)
GPU 集成图形处理器
内存 LPDDR4X:8GB,速率:3200Mbps
存储 • SPI FLASH:32MB
3、使用上手
ssh到设备上,用户名HwHiAiUser,密码Mind@123
由于没有外设,故测试一个基础的python flask内容,
(base) HwHiAiUser@orangepiaipro:~$ python
Python 3.9.2 | packaged by conda-forge | (default, Feb 21 2021, 05:02:26)
[GCC 9.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> exit()
系统中自带了python3.9,安装flask包
(base) HwHiAiUser@orangepiaipro:~$ pip install flask
Defaulting to user installation because normal site-packages is not writeable
Collecting flask
Downloading flask-3.0.3-py3-none-any.whl (101 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 101.7/101.7 kB 33.7 kB/s eta 0:00:00
Requirement already satisfied: click>=8.1.3 in /usr/local/miniconda3/lib/python3.9/site-packages (from flask) (8.1.7)
Collecting itsdangerous>=2.1.2
Downloading itsdangerous-2.2.0-py3-none-any.whl (16 kB)
Collecting blinker>=1.6.2
Downloading blinker-1.8.2-py3-none-any.whl (9.5 kB)
Requirement already satisfied: importlib-metadata>=3.6.0 in /usr/local/miniconda3/lib/python3.9/site-packages (from flask) (7.0.1)
Requirement already satisfied: Jinja2>=3.1.2 in /usr/local/miniconda3/lib/python3.9/site-packages (from flask) (3.1.3)
Collecting Werkzeug>=3.0.0
Downloading werkzeug-3.0.3-py3-none-any.whl (227 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 227.3/227.3 kB 10.4 kB/s eta 0:00:00
Requirement already satisfied: zipp>=0.5 in /usr/local/miniconda3/lib/python3.9/site-packages (from importlib-metadata>=3.6.0->flask) (3.17.0)
Requirement already satisfied: MarkupSafe>=2.0 in /usr/local/miniconda3/lib/python3.9/site-packages (from Jinja2>=3.1.2->flask) (2.1.4)
Installing collected packages: Werkzeug, itsdangerous, blinker, flask
Successfully installed Werkzeug-3.0.3 blinker-1.8.2 flask-3.0.3 itsdangerous-2.2.0
编写一个测试样例
from flask import Flask
app = Flask(__name__)
@app.route("/sctl/<name>/<int:age>")
def sctl(name,age):
return f"my name is {name}, my age is {age}"
app.run()
启动服务
(base) HwHiAiUser@orangepiaipro:~/test$ python test.py
* Serving Flask app 'test'
* Debug mode: off
WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead.
* Running on http://127.0.0.1:5000
Press CTRL+C to quit
(base) HwHiAiUser@orangepiaipro:~$ curl 127.0.0.1:5000/sctl/aa/12
my name is aa, my age is 12(