---
title: batchSize
framework: createmlcomponents
role: symbol
role_heading: Instance Property
path: createmlcomponents/fullyconnectednetworkconfiguration/batchsize
---

# batchSize

The number of examples to use per mini-batch.

## Declaration

```swift
var batchSize: Int
```

## Discussion

Discussion A larger batch size will speed up computation when training, as long as the batch fits in memory. note: This parameter is only used by the fitted method. When using the update method it’s up to you to do batching.

## See Also

### Getting the properties

- [dropoutProbability](createmlcomponents/fullyconnectednetworkconfiguration/dropoutprobability.md)
- [earlyStopIterationCount](createmlcomponents/fullyconnectednetworkconfiguration/earlystopiterationcount.md)
- [earlyStoppingTolerance](createmlcomponents/fullyconnectednetworkconfiguration/earlystoppingtolerance.md)
- [hiddenUnitCounts](createmlcomponents/fullyconnectednetworkconfiguration/hiddenunitcounts.md)
- [learningRate](createmlcomponents/fullyconnectednetworkconfiguration/learningrate.md)
- [maximumIterations](createmlcomponents/fullyconnectednetworkconfiguration/maximumiterations.md)
- [randomSeed](createmlcomponents/fullyconnectednetworkconfiguration/randomseed.md)
