Skip to content

Commit 19e2508

Browse files
authored
Merge pull request #16 from watson-developer-cloud/consolidate
Consolidate
2 parents 59f3086 + 640d85e commit 19e2508

22 files changed

Lines changed: 118 additions & 105 deletions

‎404.html‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
layout: default
2+
layout: base
33
---
44

55
<style type="text/css" media="screen">
@@ -21,4 +21,5 @@ <h1>404</h1>
2121

2222
<p><strong>Page not found :(</strong></p>
2323
<p>The requested page could not be found.</p>
24+
<p><a href="/watson-vision-coreml-code-pattern/">Head back to the main page.</a></p>
2425
</div>

‎Gemfile‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ source "https://rubygems.org"
88
#
99
# This will help ensure the proper Jekyll version is running.
1010
# Happy Jekylling!
11-
gem "jekyll", "~> 3.7.3"
11+
gem "jekyll", "~> 3.7.4"
1212

1313
# This is the default theme for new Jekyll sites. You may change this to anything you like.
1414
gem "minima", "~> 2.0"

‎Gemfile.lock‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,12 +9,12 @@ GEM
99
eventmachine (>= 0.12.9)
1010
http_parser.rb (~> 0.6.0)
1111
eventmachine (1.2.5)
12-
ffi (1.9.23)
12+
ffi (1.9.24)
1313
forwardable-extended (2.6.0)
1414
http_parser.rb (0.6.0)
1515
i18n (0.9.5)
1616
concurrent-ruby (~> 1.0)
17-
jekyll (3.7.3)
17+
jekyll (3.7.4)
1818
addressable (~> 2.4)
1919
colorator (~> 1.0)
2020
em-websocket (~> 0.5)
@@ -65,10 +65,10 @@ PLATFORMS
6565
ruby
6666

6767
DEPENDENCIES
68-
jekyll (~> 3.7.3)
68+
jekyll (~> 3.7.4)
6969
jekyll-feed (~> 0.6)
7070
minima (~> 2.0)
7171
tzinfo-data
7272

7373
BUNDLED WITH
74-
1.16.1
74+
2.0.1

‎_config.yml‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ authors:
2626

2727
collections:
2828
advanced:
29-
output: true
29+
output: false
3030
simple:
3131
output: true
3232
multiple:
33-
output: true
33+
output: false
3434
plz_work:
35-
output: true
35+
output: false
3636
arduino:
37-
output: true
37+
output: false
3838

3939
defaults:
4040
- scope:

‎_layouts/index.html‎

Lines changed: 13 additions & 76 deletions
Original file line numberDiff line numberDiff line change
@@ -7,93 +7,30 @@
77
<div class="pui-panel bg-neutral-11 box-shadow-1 border-rounded paxxxl">
88
<div class="pui-panel-body opt-inner-class txt-c" style="width: 550px;">
99

10-
<p style="margin-top: 150px;">
10+
<p style="margin-top: 50px;">
1111
<svg alt="ibm-logo" height="40">
1212
<use xlink:href="#ibm-logo"></use>
1313
</svg>
1414
</p>
1515
{{ content }}
1616
<br />
1717
<p>
18-
<div class="ok_row">
1918

20-
<div class="ok_column">
21-
<div class="card">
22-
<div class="card_container">
23-
<h4><b>Simple Tutorial<br/>(Single Model)</b></h4>
24-
<br />
25-
<p>Create your own custom image classifier using a single model and deploy to an iOS application.</p>
26-
<a href="{{ site.simple[0].url | relative_url }}" class="pui-btn pui-btn-primary pui-btn-lg btn btn-primary btn-lg" aria-label="Start code pattern">
27-
<span class="btn-inner-content pui-btn-inner-content">
28-
<span>Start</span>
29-
</span>
30-
</a>
31-
<br />
32-
</div>
19+
<div class="card">
20+
<div class="card_container">
21+
<h4><b>Tutorial</b></h4>
22+
<br />
23+
<p>Create your own custom image classifier(s) and deploy the model to an iOS application using the Watson Swift SDK.</p>
24+
<a href="{{ site.simple[0].url | relative_url }}" class="pui-btn pui-btn-primary pui-btn-lg btn btn-primary btn-lg" aria-label="Start code pattern">
25+
<span class="btn-inner-content pui-btn-inner-content">
26+
<span>Start</span>
27+
</span>
28+
</a>
29+
<br />
3330
</div>
34-
</div>
35-
36-
<div class="ok_column">
37-
<div class="card">
38-
<div class="card_container">
39-
<h4><b>Simple Tutorial<br/>(Multiple Models)</b></h4>
40-
<br />
41-
<p>Create your own custom image classifier using multiple models and deploy to an iOS application.</p>
42-
<a href="{{ site.multiple[0].url | relative_url }}" class="pui-btn pui-btn-primary pui-btn-lg btn btn-primary btn-lg" aria-label="Start code pattern">
43-
<span class="btn-inner-content pui-btn-inner-content">
44-
<span>Start</span>
45-
</span>
46-
</a>
47-
<br />
48-
</div>
49-
</div>
50-
</div>
51-
5231
</div>
32+
5333
</p>
54-
<br />
55-
<p>
56-
<div class="ok_row">
57-
<div class="ok_column">
58-
<div class="card">
59-
<div class="card_container">
60-
<h4><b>Advanced Tutorial<br/>(Single Model)</b></h4>
61-
<br />
62-
<p>Introduction to Watson Swift SDK as well as building your own custom image classifier using a single model.</p>
63-
<a href="{{ site.advanced[0].url | relative_url }}" class="pui-btn pui-btn-primary pui-btn-lg btn btn-primary btn-lg" aria-label="Start code pattern">
64-
<span class="btn-inner-content pui-btn-inner-content">
65-
<span>Start</span>
66-
</span>
67-
</a>
68-
<br />
69-
</div>
70-
</div>
71-
</div>
72-
73-
<div class="ok_column">
74-
<div class="card">
75-
<div class="card_container">
76-
<h4><b>Advanced Tutorial (Multiple Models)</b></h4>
77-
<br />
78-
<p>Introduction to Watson Swift SDK as well as building your own custom image classifier with multiple models.</p>
79-
<a href="{{ site.arduino[0].url | relative_url }}" class="pui-btn pui-btn-primary pui-btn-lg btn btn-primary btn-lg" aria-label="Start code pattern">
80-
<span class="btn-inner-content pui-btn-inner-content">
81-
<span>Start</span>
82-
</span>
83-
</a>
84-
<br />
85-
</div>
86-
</div>
87-
</div>
88-
</div>
89-
</p>
90-
<!-- <p>
91-
<a href="{{ site.simple[0].url | relative_url }}" class="pui-btn pui-btn-primary pui-btn-lg btn btn-primary btn-lg" aria-label="Start code pattern">
92-
<span class="btn-inner-content pui-btn-inner-content">
93-
<span>Start</span>
94-
</span>
95-
</a>
96-
</p> -->
9734
</div>
9835
</div>
9936
</div>

‎_simple/10_testing-the-application.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,6 @@ date: 2018-01-10
44
---
55
Now we're ready to test! First we'll make sure the app builds on our computer, if all goes well, the simulator will open and the app will display. Since the simulator does not have access to a camera, and the app relies on the camera to test the classifier, we will also deploy the app to an iPhone (in the next step).
66

7-
1. To run in the simulator, choose a phone option from the dropdown and click run
8-
![](assets/xcode_main_select_sim.png)
7+
1. Select the **Core ML Vision Custom** scheme and choose a phone option from the dropdown.
8+
9+
1. Click on the **Build and run** icon at the top left to test the application in the simulator.

‎_simple/12_bonus-improving-your-classifier.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ title: "Bonus: Improving your classifier"
33
date: 2018-01-12
44
---
55

6-
1. If you finish everything and still have time, you can work on improving the classifier that you built. There are cables provided to test your application. To improve your classifier you can take images of the cables to be used as training data.
7-
2. Take as many images as you want of each cable.
6+
1. If you finish everything and still have time, you can work on improving the classifier that you built. Use the items provided to test your application. To improve your classifier you can take additional images of the items to be used as training data.
7+
2. Take as many images as you want of each items. Focus on edge cases that are currently not handled well.
88
3. Upload the images to your computer.
99
4. Back in the Visual Recognition tooling, select your model and click ‘Edit and Retrain.’
1010
5. Here you can upload your new training images and retrain the model.
11-
6. You can click the refresh button in the app to pull down the new model after retraining.
11+
6. You can click the refresh button in the app to pull down the new model after retraining. **This update happens on-the-fly without rebuilding the app!**

‎_simple/2_requirements.md‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,11 @@ This Code Pattern was created for developers who want to create intelligent mobi
77

88
It requires some skills on Swift but if you have background on other programming languages, the code is still simple and fairly straightforward.
99

10-
Before you begin, you need to make sure you have these softwares versions installed on your machine. **These versions are required to support Core ML**:
10+
Before you begin, you need to make sure you have these softwares versions installed on your machine. **These versions are required to support Core ML and this lab**:
1111

1212
* **MacOS 10.11 El Capitan** or later
1313
* The **latest version of Xcode**
1414
* **iOS 11** or later (on your iPhone or iPad if you want the application to be on your device)
15-
* **[Carthage 0.29 or later](https://github.com/Carthage/Carthage#installing-carthage)**
15+
* **[CocoaPods](https://guides.cocoapods.org/using/getting-started.html#installation)**
1616

17-
<br />
1817

19-
{% include alert-warning.html title="Carthage installation" content="If you don't have Homebrew on your computer, it's easier to setup Carthage with the `.pkg` installer. You can download it [here](https://github.com/Carthage/Carthage/releases)." %}

‎_simple/3_prepare-your-data.md‎

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,22 @@ In order to create our model, we have to provide training images to the classifi
77
Each class we create should have *at least* **10** images. However, for optimal training time and accuracy it's best to have around 200 images sized at 224 x 224 pixels. Also, it's good practice to have images from an environment comparable to what you expect to classify. For example, since this is an iOS app, photos from your smartphone camera are probably ideal, verses professional photos or image search results. Also, try and change the background, lighting, and any other variables that you can think of!
88

99
# Preparing our data
10+
There are multiple flavors of this workshop with different associated image content. Please follow the appropriate instructions. **You only need to do one of the steps below.**
11+
12+
## 3A -- Connectors
1013
Download the [training image dataset](https://github.com/watson-developer-cloud/watson-vision-coreml-code-pattern/releases/download/1.0/Training.Images.zip), and unzip the contents to your desktop
14+
15+
## 3B -- Arduino boards
16+
Download the [training image dataset](https://github.com/watson-developer-cloud/watson-vision-coreml-code-pattern/releases/download/3.1/arduino_training_images_small.zip), and unzip the contents to your desktop.
17+
18+
**Note:** you have actually been provided with data for **two different models**, one for part identification (`part_*`) and one for fault detection (`fault_*`)
19+
20+
## 3C -- Collect your own images
21+
Take a few minutes to take photos of the various items to prepare our data. Make sure to take *at least* **10** images of each item or class. For best results, change the background, lighting, and any other variables that you can think of! (Once you're done taking photos, use airdrop to transfer the images to your computer)
22+
23+
Now we need to prepare our data by classifying each image.
24+
1. Create an empty folder for each *type* of item
25+
![](assets/classified_images.png)
26+
1. Sort through your images, putting each in the correct folder based on the type of item.
27+
1. Once all of your images are in the correct folder, archive each folder to create individual *.zip* files ***Note: on OS X, "compress" is used to create a .zip***
28+
![](assets/classified_images_final.jpeg)

‎_simple/5_create-a-new-project.md‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: Create a new project
33
date: 2018-01-05
44
---
55

6-
Once you've created an account, navigate to [Watson Studio](http://dataplatform.ibm.com/), you should be greeted with with a nice welcome screen, but if not, click on the **Get started ▾** dropdown and you should end up seeing something like this:
6+
Once you've created an account, navigate to [Watson Studio](https://dataplatform.cloud.ibm.com), you should be greeted with with a nice welcome screen, but if not, click on the **Get started ▾** dropdown and you should end up seeing something like this:
77

88
![](https://cdn-images-1.medium.com/max/6208/1*dTrUKjjQl8W0O0uA6CDthg.png)
99

@@ -21,7 +21,7 @@ Give your project a descriptive name and then click **Add** to add a Cloud Objec
2121
> ### Object Storage is used to store all your training images
2222
> **Note:** If you already have an object storage instance it will automatically be selected
2323
24-
![](https://cdn-images-1.medium.com/max/6208/1*xPV-6tkZ49c0rshbs1AZgA.png)
24+
![](https://developer.ibm.com/v1/AUTH_7046a6f4-79b7-4c6c-bdb7-6f68e920f6e5/Code-Tutorials/watson-visual-recognition-with-core-ml-single-model/images/new-watson-studio-proj.png)
2525

2626
Choose a pricing plan and click **Create**. Then **Confirm** on the following popup.
2727

0 commit comments

Comments
 (0)