Class AlexNet.Builder
java.lang.Object
ai.djl.basicmodelzoo.cv.classification.AlexNet.Builder
- Enclosing class:
- AlexNet
The Builder to construct a
AlexNet
object.-
Method Summary
Modifier and TypeMethodDescriptionai.djl.nn.Block
build()
Builds aAlexNet
block.setDropOutRate
(float dropOutRate) Sets the dropout rate in the network.setNumChannels
(int[] numChannels) Sets the number of channels for the AlexNet blocks.setOutSize
(long outSize) Sets the size of the output.
-
Method Details
-
setDropOutRate
Sets the dropout rate in the network.- Parameters:
dropOutRate
- the dropout rate- Returns:
- this
Builder
-
setNumChannels
Sets the number of channels for the AlexNet blocks.- Parameters:
numChannels
- the number of channels for every AlexNet block.- Returns:
- this
Builder
-
setOutSize
Sets the size of the output.- Parameters:
outSize
- the output size- Returns:
- this
Builder
-
build
public ai.djl.nn.Block build()Builds aAlexNet
block.- Returns:
- the
AlexNet
block
-