Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
TensorFlow for Mobile Developers
Search
Enrique López Mañas
February 22, 2018
Programming
180
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
TensorFlow for Mobile Developers
TensorFlow for Mobile Developers @ DroidKaigi
Enrique López Mañas
February 22, 2018
More Decks by Enrique López Mañas
See All by Enrique López Mañas
Composifying Your Not-Compose Code
kikoso
0
64
KMP_for_Swift.pdf
kikoso
0
84
Android Benchmarking and other stories
kikoso
0
570
KMP for Mobile Developers
kikoso
0
110
Diving into Coroutines
kikoso
1
110
K/N for mobile developers (including libraries' snippets)
kikoso
0
130
Kotlin/Native for Multiplatform development
kikoso
0
93
TensorFlow for Mobile Developers
kikoso
0
21
Kotlin/Native for Multiplatform development
kikoso
1
230
Other Decks in Programming
See All in Programming
機械に任せるテスト、人が見るテスト ⽣成AIで引き直した、運⽤保守フェーズの線引き
dske104
0
160
難しいけど、読めた。- OSSの入口に立った話。
sts11142
0
140
20260914 AIエージェント時代のPlatform Engineering LLM基盤とプロダクトの責務境界線
kanfab1
7
2.4k
そのリトライ、死んだコネクションを使い回していませんか ── GoのHTTPクライアントとHTTP/2を実プロダクト障害から学び直す
myus4a
0
390
AI が書く Go コードの品質を劇的に向上させる Linter: “declscope”
mpyw
0
480
CodeRabbitの効果検証と過ごしてみた3ヶ月
armondando
0
140
ハーネス設計入門 〜 基礎知識の整理から実務へのステップアップ 〜
kinopeee
20
21k
Verilogで学ぶCPU自作入門.pdf
uyuki234
8
4k
Findy - エンジニア向け会社紹介/Findy Company Deck
findyinc
6
400k
Unity6 URPによる海底をテーマにしたVJシステムの解説 | Unity Shader 完全に理解した 勉強会
gam0022
0
330
SalesForceを内製化!? ~ HR事業を支える顧客管理基盤のインフラを大公開 ~
oku053
0
120
[ハンズオン]AIへの指示だけで「五目並べ」を作ってみよう
satoshi256kbyte
1
340
Featured
See All Featured
The Director’s Chair: Orchestrating AI for Truly Effective Learning
tmiket
1
310
Fantastic passwords and where to find them - at NoRuKo
philnash
52
4k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
20k
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
230
23k
Dealing with People You Can't Stand - Big Design 2015
cassininazir
367
27k
Thoughts on Productivity
jonyablonski
76
5.4k
DBのスキルで生き残る技術 - AI時代におけるテーブル設計の勘所
soudai
PRO
68
58k
WENDY [Excerpt]
tessaabrams
14
40k
sira's awesome portfolio website redesign presentation
elsirapls
0
440
A Tale of Four Properties
chriscoyier
163
24k
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
610
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
340
Transcript
TensorFlow for Mobile Developers Enrique López Mañas Google Developer Expert
Ego Slide • Freelance Dev • Google Developer Expert •
@eenriquelopez
Machine Learning / AI
Machine Learning / AI
Machine Learning / AI
Buzzwords classification Artificial intelligence Machine Learning The science of making
machines smarts Building machines that can learn Neural Networks One of the many different algorithms in Machine Learning
Buzzwords classification
Neural Network
Machine Learning
Machine Learning
Machine Learning 12% of all responses on mobile
Machine Learning
Machine Learning
Machine Learning
Cloud vs. Mobile Less Traffic & Faster Response Motion Sensors
TensorFlow OpenSource library for Machine Learning tensorflow.org Today most popular
ML framework
TensorFlow You can train: - Mac / Windows - GPU
Server - GPU/TPU on Cloud Prediction: - Android - iOS - Raspberry
TensorFlow CIFAR10
TensorFlow ecosystem
From Training to App (@yufengg)
Data Gathering?
From Training to App (@yufengg)
From Training to App (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
Convolutional Neural Networks (@yufengg)
From Training to App (@yufengg)
Optimizing model for Mobile (@yufengg)
From Training to App (@yufengg) Other inception versions (inception v1
quantised is 7 MB)
From Training to App (@yufengg) TensorFlow increases APK in 12
MB
From Training to App (@yufengg)
From Training to App (@yufengg)
TensorFlow community 1000+ contributors 22.000+ commits 18.000+ repositories with name
“TensorFlow”
TensorFlow community
Building with Android Studio Uses Bazel to build Set Bazel
binary location in /tensorflow/examples/ android/build.gradle Add project in tensorflor/examples/android folder to Android Studio
Building with Android Studio Installing Bazel first: Download from https://github.com/bazelbuild/bazel/releases
Install instructions in https://docs.bazel.build/versions/master/install.html
Building with Android Studio Download Android SDK (23) Download Android
NDK (12b) (recommend it with Android SDK Manager)
Building with Android Studio WORKSPACE FILE
Building with Android Studio Run Bazel bazel build -c opt
//tensorflow/examples/ android:tensorflow_demo
Building with Android Studio Install APK adb install -r bazel-bin/tensorflow/examples/android/
tensorflow_demo.apk
Building with Android Studio OR… TensorFlow AAR from JCenter YUV
-> RGB less efficient Object tracking not available
Android Samples TF Classify TF Detect TF Stylize
TF Classify Uses Google Inception (v3) to label images Model
easy to swap No “person label” Volume button up for statistics
TF Classify
TF Classify
TF Detect
TF Detect - Draw bounding boxes around people - Useful
to count objects - No training yet
TF Style
TF Style - Real time style transfer algorithm - Pick/mix
different styles - Can train Magenta models
TF Style
TensorFlow Written in C++ Android uses Kotlin/Java? HowTo? Android
inference Library https://github.com/tensorflow/tensorflow/tree/master/tensorflow/contrib/android
Building for iOS Install requirements: - Xcode 8 - Command
line tools (xcode-select install) - brew install automake - brew install lib tool - tensorflow/contrib/makefile_build_all_ios.sh (takes 20 minutes)
iOS Examples: simple
iOS Examples: camera
iOS Examples: camera - Run inception each frame - Models
can be replaced
iOS Examples: benchmark
Raspberry Pi
Resources TensorFlow: https://www.tensorflow.org/ Magenta: https://magenta.tensorflow.org/welcome-to-magenta TensorFlow for Poets: https://codelabs.developers.google.com/codelabs/ tensorflow-for-poets/index.html#0
Shameless self-promotion www.kotlinweekly.net
Feedback! http://bit.ly/droidkaigi
None