Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Bol.com

Deeplearning for ecommerce
Barrie Kersbergen
Expert Data Scientist bij bol.com

Big Data Expo

  • Login to see the comments

  • Be the first to like this

Bol.com

  1. 1. 25-9-2017 Deep Learning for E-commerce recognize content in images Big Data Expo ‘17 Barrie Kersbergen #krsbrgn Computer Science Machine Learning? Formal definition: Machine learning (ML) is a subfield of computer science … that gives computers the ability to learn without being explicitly programmed 1. Taken from https://en.wikipedia.org/wiki/Machine_learning at 2016-08-05 Machinelearning
  2. 2. 25-9-2017 Deep Learning? Formal definition: Deep learning (DL) is a branch of machine learning … …(computer) attempt to model different levels abstractions in data (automatically). sourcehttps://en.wikipedia.org/wiki/Deep_Learning at 2016-08-05 Computer Science Machinelearning Deep learning ML: (Statistical) classification Classifier software “Offline/Batch” Every week train Classifier software “Offline/Batch” predict Training phase Prediction phase petal_length petal_width 5.6 1.6 class ? class Iris-virginica petal_length petal_width class 5.5 1.8 Iris-virginica 4.8 1.8 Iris-versicolor 1.4 0.2 Iris-setosa 1.4 0.2 Iris-setosa train.csv prediction.csv ML: (Statistical) classification petal_length petal_width class 5.5 1.8 Iris-virginica 4.8 1.8 Iris-versicolor 1.4 0.2 Iris-setosa 1.4 0.2 Iris-setosa petal_length petal_width 5.6 1.6 class ? train.csv prediction.csv • Onsite bot detection • Customer churning • Fraud detection • Customer problem detection • Catalog attribute prediction • … • but …
  3. 3. 25-9-2017 Data’s rarely structured in rows and columns Product images Product reviews Product descriptions Customer support Logfiles from our applications Data scientists/analysts spend 80 percent of their time sourcing, cleaning, and preparing data. (source Data Science Report Crowdflower 2016) ‘Common’ machine learning Traditional ML software (human performance) Deep learning software “automatic feature engineering” (superhuman performance) Unstructured dataStructured data Data scientist/analystspetal_length petal_width class 5.5 1.8 Iris-virginica 4.8 1.8 Iris-versicolor 1.4 0.2 Iris-setosa 1.4 0.2 Iris-setosa “feature engineering: painful black art, transforming data” Features are key to statistics and machine learning Deep Learning • Deep learning f.k.a. Artificial Neural Networks. (1950’s) • Loosely inspired by how our brain functions. The software can teach themselves to understand things like images, text and speech. • Major advances in 1980’s 1990’s. The DL quality improves when: • Massive data • (Massive) Cheap computing horse power. Popular Deep Learning ‘network configs’ Super human results when working on unstructured data
  4. 4. 25-9-2017 image class Long sleeve Perfume Flower Short sleeve Deep Convolutional Neural Network Classifier software (Tensorflow) “Offline” (Batch) Every week train Classifier software (Tensorflow) “Offline” (Batch) predict Training phase Prediction phase class Long sleeve image class ? Deep Convolutional Neural Network Deep learning best practice: For every distinct “class” you need at least 1.000 training images 1000 classes * 1000 images= 1.000.000 training images ‘training’ tensorflow will take 1 year on a modern pc * * FireCaffe: near-linear acceleration of deep neural network training on compute clusters, 2016 It is common to train a dozen times to see which settings work best Deep Convolutional Neural Network * FireCaffe: near-linear acceleration of deep neural network training on compute clusters, 2016 machine learning * i7 CPU GPU Clock speed 4.2 GHz 1.7 GHz # of processor ‘cores’ 8 2560 Duration (days) 365 21
  5. 5. 25-9-2017 Transfer learning: reduce training from 21 days to 2 minutes • Download a model that’s already trained on millions of images. • Retrain that model with our images. • Advantages: • Still good results if lesser training images per class • (Re)training done in minutes instead of 21 days • Get really good results Use-case: Predict t-shirt sleeve length What do you need to install? (opensource software) • Python 3 (64bit) • Google Tensorflow (CPU or GPU edition). Runs native on Windows 7 and Windows 10. Deep Convolutional Neural Network with transfer learning
  6. 6. 25-9-2017 • Tensorflow example is was missing code to do predictions Deep Convolutional Neural Network with transfer learning DCNN-TL project: Each directory now contains 100+ distinct images 23 Place training images in ‘train’ directory
  7. 7. 25-9-2017 (re)training on bol.com images Double click on retrain.cmd (re)training on images Predict t-shirt sleeve length
  8. 8. 25-9-2017 Predict t-shirt sleeve length Double click on predict.cmd ‘external’ images ‘external’ images
  9. 9. 25-9-2017
  10. 10. 25-9-2017 Deep Convolutional Neural Network with Transfer Learning • Predict from structured data using RandomForest • Predict from unstructured data using DCNN with TL • Improve training duration • Applications DL: What’s the catch? • DL • CPU 365 days = 365*24hrs*91J*3600sec/h= 2869.8 MJ • GPU 21 days = 21days*24hrs*(91J+280J)*3600sec/h= 673.1MJ • Traditional ML (quality will not match DL) • 20 hours on CPU=20hrs*91J*3600sec/h= 6.5 MJ * Usually we only train once in a week, month. That’s 104 times more power consumption! * (When not using transfer learning) • Barrie Kersbergen Deep Learning for E-commerce You got Questions we’ve got Answers #krsbrgn recognize content in images

×