List of usage examples for org.deeplearning4j.nn.conf.inputs InputType getType
@JsonIgnore
public abstract Type getType();
From source file:org.ensor.fftmusings.mdn.MixtureDensityRNNOutputLayer.java
License:Apache License
@Override public InputType getOutputType(int layerIndex, InputType inputType) { if (inputType == null || inputType.getType() != InputType.Type.RNN) { throw new IllegalStateException("Invalid input type for RnnOutputLayer (layer index = " + layerIndex + ", layer name=\"" + getLayerName() + "\"): Expected RNN input, got " + inputType); }//from w w w . ja va 2 s. c o m return InputType.recurrent(nOut); }
From source file:org.ensor.fftmusings.mdn.MixtureDensityRNNOutputLayer.java
License:Apache License
@Override public void setNIn(InputType inputType, boolean override) { if (inputType == null || inputType.getType() != InputType.Type.RNN) { throw new IllegalStateException("Invalid input type for RnnOutputLayer (layer name=\"" + getLayerName() + "\"): Expected RNN input, got " + inputType); }/*w w w . java2 s. c o m*/ if (nIn <= 0 || override) { InputType.InputTypeRecurrent r = (InputType.InputTypeRecurrent) inputType; this.nIn = r.getSize(); } }