- Design the output layer using OutputLayer:
builder.layer(new OutputLayer.Builder(LossFunctions.LossFunction.NEGATIVELOGLIKELIHOOD)
.nOut(numLabels)
.activation(Activation.SOFTMAX)
.build());
- Set the input type using setInputType():
builder.setInputType(InputType.convolutional(30,30,3));