Examples of ActivationFunction


Examples of de.jungblut.math.activation.ActivationFunction

    for (int i = 0; i < layers; i++) {
      MatrixWritable mv = new MatrixWritable();
      mv.readFields(in);
      array[i] = mv.getMatrix();
    }
    ActivationFunction func = null;
    try {
      func = (ActivationFunction) Class.forName(in.readUTF()).newInstance();
    } catch (InstantiationException | IllegalAccessException
        | ClassNotFoundException e) {
      throw new RuntimeException(e);
View Full Code Here

Examples of eas.simulation.brain.neural.functions.ActivationFunction

    }
   
    public void propagate() {
        this.neuronVector.mult(this.weightMatrix);
        for (int i = 0; i < this.neuronVector.getRowCount(); i++) {
            ActivationFunction act = this.getActivationFunction(i);
            this.neuronVector.set(0, i, act.activationPhi(this.neuronVector.get(0, i)));
        }
    }
View Full Code Here

Examples of eas.simulation.brain.neural.functions.ActivationFunction

    public void propagateReverse() {
        if (this.inverseWeightMatrix == null) {
            this.createInverseWeightMatrix();
        }
        for (int i = 0; i < this.neuronVector.getRowCount(); i++) {
            ActivationFunction act = this.getActivationFunction(i);
           
            try {
                this.neuronVector.set(0, i, act.inverseActivationPhi(this.neuronVector.get(0, i)));
            } catch (InversionNotSupportedException e) {}
        }
        this.neuronVector.mult(this.inverseWeightMatrix);
    }
View Full Code Here

Examples of eas.simulation.brain.neural.functions.ActivationFunction

    private void createInverseWeightMatrix() {
        this.inverseWeightMatrix = this.weightMatrix.inverse();
    }
   
    public ActivationFunction getActivationFunction(int neuronID) {
        ActivationFunction a = this.activationFunctions.get(neuronID);
        if (a == null) {
            return this.standardActFct;
        } else {
            return a;
        }
View Full Code Here

Examples of eas.users.lukas.neuroCEGPM.simpleNeural.activationFunction.ActivationFunction

        if (endTime - startTime > longTime) {
            GlobalVariables.getPrematureParameters().logWarning("Very long matrix multiplication in propagate: " + (endTime - startTime));
        }

        for (int i = 0; i < this.neuronVector.getRowCount(); i++) {
            ActivationFunction act = this.getActivationFunction(i);
            this.neuronVector.set(0, i, act.activationPhi(this.neuronVector.get(0, i)));
        }
       
        if (normalize) {
            this.normalizeNeuronVector(maxNeuronValue);
        }
View Full Code Here

Examples of eas.users.lukas.neuroCEGPM.simpleNeural.activationFunction.ActivationFunction

    public void propagateReverse(boolean normalize) {
        if (this.inverseWeightMatrix == null) {
            this.createInverseWeightMatrix();
        }
        for (int i = 0; i < this.neuronVector.getRowCount(); i++) {
            ActivationFunction act = this.getActivationFunction(i);
           
            try {
                this.neuronVector.set(0, i, act.inverseActivationPhi(this.neuronVector.get(0, i)));
            } catch (InversionNotSupportedException e) {}
        }
       
        long startTime = System.currentTimeMillis();
        this.neuronVector.mult(this.inverseWeightMatrix);
View Full Code Here

Examples of eas.users.lukas.neuroCEGPM.simpleNeural.activationFunction.ActivationFunction

    private void createInverseWeightMatrix() {
        this.inverseWeightMatrix = this.weightMatrix.inverse();
    }
   
    public ActivationFunction getActivationFunction(int neuronID) {
        ActivationFunction a = this.activationFunctions.get(neuronID);
        if (a == null) {
            return this.standardActFct;
        } else {
            return a;
        }
View Full Code Here

Examples of eas.users.lukas.neuroCEGPM.simpleNeural.activationFunction.ActivationFunction

     * @param sequence  The sequence to translate.
     *
     * @return  The translation.
     */
    public NeuroController translateGenomeToController(List<BigDecimal> sequence, boolean normalize) {
        ActivationFunction func = this.getStandardActFct();
        int scale = MatrixBigDecimal.GLOBAL_SCALE;
        MatrixBigDecimal.GLOBAL_SCALE = 10;
        this.setStandardActFct(new ActivationFunctionSQRT());
       
//        System.out.println();
View Full Code Here

Examples of org.dmg.pmml._40.ACTIVATIONFUNCTION

   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void setActivationFunction(ACTIVATIONFUNCTION newActivationFunction) {
    ACTIVATIONFUNCTION oldActivationFunction = activationFunction;
    activationFunction = newActivationFunction == null ? ACTIVATION_FUNCTION_EDEFAULT : newActivationFunction;
    boolean oldActivationFunctionESet = activationFunctionESet;
    activationFunctionESet = true;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.SET, _40Package.NEURAL_LAYER_TYPE__ACTIVATION_FUNCTION, oldActivationFunction, activationFunction, !oldActivationFunctionESet));
View Full Code Here

Examples of org.dmg.pmml._40.ACTIVATIONFUNCTION

   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   * @generated
   */
  public void unsetActivationFunction() {
    ACTIVATIONFUNCTION oldActivationFunction = activationFunction;
    boolean oldActivationFunctionESet = activationFunctionESet;
    activationFunction = ACTIVATION_FUNCTION_EDEFAULT;
    activationFunctionESet = false;
    if (eNotificationRequired())
      eNotify(new ENotificationImpl(this, Notification.UNSET, _40Package.NEURAL_LAYER_TYPE__ACTIVATION_FUNCTION, oldActivationFunction, ACTIVATION_FUNCTION_EDEFAULT, oldActivationFunctionESet));
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.