Class SDLayerParams

    • Constructor Detail

      • SDLayerParams

        public SDLayerParams​(Map<String,​long[]> weightParams,
                             Map<String,​long[]> biasParams)
    • Method Detail

      • addWeightParam

        public void addWeightParam​(@NonNull
                                   @NonNull String paramKey,
                                   @NonNull
                                   @lombok.NonNull long... paramShape)
        Add a weight parameter to the layer, with the specified shape. For example, a standard fully connected layer could have weight parameters with shape [numInputs, layerSize]
        Parameters:
        paramKey - The parameter key (name) for the weight parameter
        paramShape - Shape of the weight parameter array
      • addBiasParam

        public void addBiasParam​(@NonNull
                                 @NonNull String paramKey,
                                 @NonNull
                                 @lombok.NonNull long... paramShape)
        Add a bias parameter to the layer, with the specified shape. For example, a standard fully connected layer could have bias parameters with shape [1, layerSize]
        Parameters:
        paramKey - The parameter key (name) for the bias parameter
        paramShape - Shape of the bias parameter array
      • getParamShapes

        public Map<String,​long[]> getParamShapes()
        Get the parameter shapes for all parameters
        Returns:
        Map of parameter shapes, by parameter
      • clear

        public void clear()
        Clear any previously set weight/bias parameters (including their shapes)
      • isWeightParam

        public boolean isWeightParam​(String param)
      • isBiasParam

        public boolean isBiasParam​(String param)
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object