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
68
|
4
调用代码来在位图上设置矩形的位置之后:
getLabels(bitmap, detectedObjects, txtOutput)
运行此代码时,你进行了许多异步调用,首先是物体检测器,然后是图像标记
器。因此,你很可能会在按下按钮后看到延迟行为。你可能会首先看到边界框
被绘制出来,稍后标签列表将被更新。 Android Kotlin 提供了许多异步函数
来让用户体验更好一点,但它们超出了本书的范围,因为我想让示例保持简单
并专注于使用 ML Kit 中呈现的功能。
4.3
检测和跟踪视频中的物体
ML Kit 物体检测器还可以对视频流进行操作,让你能够检测视频中的物体并在连续视频
帧中跟踪该物体。例如,如图 4-6 所示,我在场景中移动相机,不仅检测到了 Android
小雕像,给出了一个边界框,而且还分配了一个跟踪 ID。当物体停留在视野内时,后续
帧会根据新位置获得不同的边界框,但跟踪 ID 保持不变
尽管因为帧内的位置和不
同的相机角度而看起来不同,但它被识别为同一物体。
4-6
:使用基于视频的物体检测器
正文.indd 68正文.indd 68 2023-4-30 9:08:162023-4-30 9:08:16
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