
aima.core.learning.neural.NNConfig Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of aima-core Show documentation
Show all versions of aima-core Show documentation
AIMA-Java Core Algorithms from the book Artificial Intelligence a Modern Approach 3rd Ed.
package aima.core.learning.neural;
import java.util.Hashtable;
/**
* A holder for config data for neural networks and possibly for other learning
* systems.
*
* @author Ravi Mohan
*
*/
public class NNConfig {
private final Hashtable hash;
public NNConfig(Hashtable hash) {
this.hash = hash;
}
public NNConfig() {
this.hash = new Hashtable();
}
public double getParameterAsDouble(String key) {
return (Double) hash.get(key);
}
public int getParameterAsInteger(String key) {
return (Integer) hash.get(key);
}
public void setConfig(String key, Double value) {
hash.put(key, value);
}
public void setConfig(String key, int value) {
hash.put(key, value);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy