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
### What does \["sample", "batch", "epoch"\] mean?
61
+
62
+
Below are some common definitions that are necessary to know and understand to correctly utilize Keras:
63
+
64
+
-**Sample**: one element of a dataset.
65
+
-*Example:* one image is a **sample** in a convolutional network
66
+
-*Example:* one audio file is a **sample** for a speech recognition model
67
+
-**Batch**: a set of *N* samples. The samples in a **batch** are processed independently, in parallel. If training, a batch results in only one update to the model.
68
+
- A **batch** generally approximates the distribution of the input data better than a single input. The larger the batch, the better the approximation; however, it is also true that the batch will take longer to processes and will still result in only one update. For inference (evaluate/predict), it is recommended to pick a batch size that is as large as you can afford without going out of memory (since larger batches will usually result in faster evaluating/prediction).
69
+
-**Epoch**: an arbitrary cutoff, generally defined as "one pass over the entire dataset", used to separate training into distinct phases, which is useful for logging and periodic evaluation.
70
+
- When using `evaluation_data` or `evaluation_split` with the `fit` method of Keras models, evaluation will be run at the end of every **epoch**.
71
+
- Within Keras, there is the ability to add [callbacks](https://keras.io/callbacks/) specifically designed to be run at the end of an **epoch**. Examples of these are learning rate changes and model checkpointing (saving).
72
+
73
+
---
74
+
57
75
### How can I save a Keras model?
58
76
59
77
*It is not recommended to use pickle or cPickle to save a Keras model.*
0 commit comments