public static Point Translate(Network network, Neuron neuron) { // translate a network coordinate to a screen coordinate Layer layer = network.LayerOf(neuron); Point p = neuron.Coordinate.Multiply(100, 25).Add(50); return p; }
public static void Link(Network network) { Layer previous = null; foreach (Layer layer in network.Layers) { if (previous != null) { Link(previous, layer); } previous = layer; } }
public static Network Build(string name, Action<Network> link, params int[] layersizes) { Network network = new Network(); network.Name = name; network.CreateLayers(layersizes); network.Position(); network.Coordinate(); network.Classify(); network.InjectFunctions(); link(network); return network; }