Fix weighted sum back
This commit is contained in:
@@ -24,9 +24,9 @@ public class Main {
|
||||
int nbrClass = 1;
|
||||
|
||||
DataSet dataset = new DatasetExtractor()
|
||||
.extract("C:/Users/Laurent/Desktop/ANN-framework/src/main/resources/assets/table_2_9.csv", nbrClass);
|
||||
.extract("C:/Users/Laurent/Desktop/ANN-framework/src/main/resources/assets/table_4_12.csv", nbrClass);
|
||||
|
||||
int[] neuronPerLayer = new int[]{1800, 2, 1800, dataset.getNbrLabels()};
|
||||
int[] neuronPerLayer = new int[]{10, 5, 10, dataset.getNbrLabels()};
|
||||
int nbrInput = dataset.getNbrInputs();
|
||||
|
||||
FullyConnectedNetwork network = createNetwork(neuronPerLayer, nbrInput);
|
||||
@@ -36,7 +36,7 @@ public class Main {
|
||||
Trainer trainer = new GradientBackpropagationTraining();
|
||||
trainer.train(0.01F, 2000, network, dataset);
|
||||
|
||||
//plotGraph(dataset, network);
|
||||
plotGraph(dataset, network);
|
||||
}
|
||||
|
||||
private static FullyConnectedNetwork createNetwork(int[] neuronPerLayer, int nbrInput){
|
||||
@@ -78,8 +78,8 @@ public class Main {
|
||||
});
|
||||
}
|
||||
|
||||
float min = -5F;
|
||||
float max = 5F;
|
||||
float min = -3F;
|
||||
float max = 3F;
|
||||
float step = 0.03F;
|
||||
for (float x = min; x < max; x+=step){
|
||||
for (float y = min; y < max; y+=step){
|
||||
|
||||
Reference in New Issue
Block a user