Skip to Content
移动端AI与ML应用开发:基于iOS和Android
book

移动端AI与ML应用开发:基于iOS和Android

by Laurence Moroney
January 2023
Intermediate to advanced
288 pages
6h 6m
Chinese
China Machine Press
Content preview from 移动端AI与ML应用开发:基于iOS和Android
98
|
6
MLKitObjectDetector
,而 pod 应该是
GoogleMLKit/ObjectDetection
完成后,运行
pod install
来下载所需的依赖库,你将创建一个新的
.xcworkspace
件。打开这个继续操作。
6.2.2
2
步:在故事板上创建
UI
这个应用程序比标记图像的应用程序更简单,因为你只有两个 UI 元素
一张你想要
执行物体检测的图像(你将在上面绘制边界框),以及一个用户要按下以触发物体检测的
按钮。因此,向故事板添加一个 UIImageView 和一个按钮。编辑按钮将其文本更改为
“物体检测”Detect Objects。完成后,你的故事板应如图 6-7 所示。
物体检测
6-7
:物体检测应用程序的故事板
你需要为图像视图创建一个输出并为按钮创建一个动作。如果你不熟悉这些,我建议你
返回到第 3 章并完成那里的示例,以及在本章前面进行图像标记。
完成后,你的
ViewController.swift
文件将定义输出和动作,应如下所示:
import UIKit
class ViewController: UIViewController {
@IBOutlet weak var imageView: UIImageView!
正文.indd 98正文.indd 98 2023-4-30 9:08:352023-4-30 9:08:35
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

人工智能驱动的商业智能

人工智能驱动的商业智能

Tobias Zwingmann
Lua游戏AI开发指南

Lua游戏AI开发指南

Posts & Telecom Press, David Young
人工智能技术与大数据

人工智能技术与大数据

Posts & Telecom Press, Anand Deshpande, Manish Kumar

Publisher Resources

ISBN: 9787111713081