You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Character Classification (of Synthetic Dataset) using Keras (CNN)
2
2
3
-
1.`python3 generate-images.py `
3
+
**Step-1:**
4
4
5
-
This generates the synthetic datasetin this and this folder.
5
+
Download backgrounds and put the light and dark backgrounds separately. We'll be using them for creating synthetic dataset. We have uploaded sample backgrounds in light_backgrounds and dark_backgrounds for reference.
6
6
7
-
2.`python3 train_model.py`
7
+
**Step-2:**
8
8
9
-
This trains the model on the given dataset.
9
+
Download fonts from [here](https://fonts.google.com/). These fonts will be used for randomly selected font-type while creating synthetic dataset.
10
10
11
-
3.`python3 make_predictions.py <image_path>`
11
+
**Step-3:**
12
12
13
-
This predicts on the test images. Note: You have to specify your test image as an argument.
13
+
Create synthetic data using ImageMagick. We have given an intuition behind creating synthetic data, in our blog. This can be done with following command:
14
14
15
+
`python3 generate-images.py`
16
+
17
+
**Step-4:**
18
+
19
+
Training the model on the given dataset. A modified LeNet structure has been used to train our model, using Keras. This can be done with following command:
20
+
21
+
`python3 train_model.py`
22
+
23
+
**Step-5:**
24
+
25
+
In order to predict the digit or character in an image, execute the following command. Give the test image path as the argument.
0 commit comments