Upgrade to Pro — share decks privately, control downloads, hide ads and more …

How can you get started with Machine Learning ?

How can you get started with Machine Learning ?

There are three ways to get started with Machine Learning:
The first way is to use “ready to use” APIs, like Cloud Vision.
These are powered by machine learning, but you can take advantage of them without needing to know all the details
The second way is to use an existing model, and retrain it with your data.
For example, say you wanted to train a model to recognize your own images
One way to do this is to use TensorFlow, an open source library for machine learning
You could start with an existing model, like Inception, and train it with your own data
We’ll see an example of how to do this using TensorFlow for Poets later on
Finally, you can use TensorFlow to develop your own algorithms

Yannick Serge Obam

March 17, 2019
Tweet

More Decks by Yannick Serge Obam

Other Decks in Technology

Transcript

  1. 2 2 WHO I AM Yannick Serge Obam • Co-

    founder IsoMora • AI/ML Evangelist • Organiser GDG Ebolowa
  2. Agenda (1) Use a Cloud-based or Mobile API (Vision, Natural

    Language …) (2) Use an existing model architecture, and retrain it or fine tune on your dataset (3) Develop your own machine learning models for new problems
  3. Faces Faces, facial landmarks, emotions OCR Read and extract text,

    with support for > 10 languages Label Detect entities from furniture to transportation Logos Identify product logos Landmarks & Image Properties Detect landmarks & dominant color of image Safe Search Detect explicit content - adult, violent, medical and spoof Cloud Vision API
  4. API Usage: Detect Objects in an Image Image Detected Items

    Vision API Create JSON request with the image or pointer to an image Process the JSON response Call the REST API 1 2 3
  5. Confidential & Proprietary Google Cloud Platform 8 Cloud Natural Language

    API Extract sentence, identify parts of speech and create dependency parse trees for each sentence. Identify entities and label by types such as person, organization, location, events, products and media. Understand the overall sentiment of a block of text. Syntax Analysis Entity Recognition Sentiment Analysis
  6. Confidential & Proprietary Google Cloud Platform 10 Cloud Speech AI

    Automatic Speech Recognition (ASR) powered by deep learning neural networking to power your applications like voice search or speech transcription. Recognizes over 80 languages and variants with an extensive vocabulary. Returns partial recognition results immediately, as they become available. Filter inappropriate content in text results. Audio input can be captured by an application’s microphone or sent from a pre-recorded audio file. Multiple audio file formats are supported, including FLAC, AMR, PCMU and linear-16. Handles noisy audio from many environments without requiring additional noise cancellation. Audio files can be uploaded in the request and, in future releases, integrated with Google Cloud Storage. Automatic Speech Recognition Global Vocabulary Inappropriate Content Filtering Streaming Recognition Real-time or Buffered Audio Support Noisy Audio Handling Integrated API
  7. Face API faces, facial landmarks, eyes open, smiling Barcode API

    1D and 2D barcodes Text API Latin-based text / structure Common Mobile Vision API Support for fast image and video on-device detection and tracking.
  8. Googly Eyes Android App Video credit Google 1. Create a

    face detector for facial landmarks (e.g., eyes) 3. For each face, draw the eyes FaceDetector detector = new FaceDetector.Builder() .setLandmarkType(FaceDetector.ALL_LANDMARKS) .build(); SparseArray<Face> faces = detector.detect(image); for (int i = 0; i < faces.size(); ++i) { Face face = faces.valueAt(i); for (Landmark landmark : face.getLandmarks()) { // Draw eyes 2. Detect faces in the image
  9. Easy to use Java API image detected items Detector 1.Create

    a detector object 2.detectedItems = detector.detect(image) Photo credit developers.google.com/vision
  10. Barcode Detection 1D barcodes EAN-13/8 UPC-A/E Code-39/93/128 ITF Codabar 2D

    barcodes QR Code Data Matrix PDF-417 AZTEC UPC DataMatrix QR Code PDF 417 Video and image credit Google
  11. Mobile Vision: Codelabs and Samples Googly Eyes Code Sample github.com/googlesamples/android-vision/tree/master/visionSamples/googly-eyes

    Codelabs codelabs.developers.google.com/codelabs/face-detection/ codelabs.developers.google.com/codelabs/mobile-vision-ocr/ Mobile Vision Developers developers.google.com/vision/ GitHub Code Samples github.com/googlesamples/android-vision .
  12. Open source Machine Learning library Especially useful for Deep Learning

    For research and production Apache 2.0 license
  13. Production on any platform •TensorFlow Serving: A TensorFlow library allowing

    models to be served over HTTP/REST or gRPC/Protocol Buffers. •TensorFlow Lite: TensorFlow’s lightweight solution for mobile and embedded devices provides the capability to deploy models on Android, iOS and embedded systems like a Raspberry Pi and Edge TPUs. •TensorFlow.js : Enables deploying models in JavaScript environments, such as in a web browser or server side through Node.js. TensorFlow.js also supports defining models in JavaScript and training directly in the web browser using a Keras-like API.
  14. Complete code import tensorflow as tf mnist = tf.keras.datasets.mnist (x_train,

    y_train),(x_test, y_test) = mnist.load_data() x_train, x_test = x_train / 255.0, x_test / 255.0 model = tf.keras.models.Sequential([ tf.keras.layers.Flatten(input_shape=(28, 28)), tf.keras.layers.Dense(512, activation=tf.nn.relu), tf.keras.layers.Dropout(0.2), tf.keras.layers.Dense(10, activation=tf.nn.softmax) ]) model.compile(optimizer='adam', loss='sparse_categorical_crossentropy', metrics=['accuracy']) model.fit(x_train, y_train, epochs=5) model.evaluate(x_test, y_test)
  15. Claude Monet - Bouquet of Sunflowers Images from the Metropolitan

    Museum of Art (with permission) Image by @random_forests
  16. Image source: Wikimedia + = A Neural Algorithm of Artistic

    Style http://arxiv.org/abs/1508.06576 ?
  17. Image source: Wikimedia + = A Neural Algorithm of Artistic

    Style http://arxiv.org/abs/1508.06576
  18. What's Next tensorflow.org github.com/tensorflow Want to learn more? deeplearning.ai :

    Intro to TensorFlow for AI, ML and DL Udacity class : Intro to TensorFlow for Deep Learning Guides, codelabs, videos TensorFlow for Poets, goo.gl/bVjFIL https://www.tensorflow.org/tutorials/