public void mutate (double intensity) {
        //Our start/end values for the set of node ids we want to mutate
        int topEnd = NeuralNets.generator.nextInt(this.getTopId()) + 1;
        //System.out.println("Top Node: " + topEnd);
        int bottomEnd = NeuralNets.generator.nextInt(topEnd) + 1;
        //System.out.println("Bot Node: " + bottomEnd);

        Node[] alteredNodes = new Node[topEnd - bottomEnd];
        for (int i = bottomEnd; i < topEnd; i++) {
            alteredNodes[i - bottomEnd] = this.getNodeForId(i);
        }

        for (Node node : alteredNodes) {
            node.setThreshold(node.getThreshold() + (NeuralNets.generator.nextGaussian() * intensity));
        }

        int topLink = NeuralNets.generator.nextInt(getLinks().size()) + 1;
        //System.out.println("Top Link: " + topLink);
        int bottomLink = NeuralNets.generator.nextInt(topLink) + 1;
        //System.out.println("Bottom Link: " + bottomLink);
        for (int i = bottomLink; i < topLink; i++) {
            Link link = getLinks().get(i);
            link.setWeight(link.getWeight() + (NeuralNets.generator.nextGaussian()));// * intensity));
        }

        if (NeuralNets.generator.nextInt(2000) == 1) {
            // Throw in some new, random links, between 2 random nodes.
            int linkSource = NeuralNets.generator.nextInt(getTopId()-1) + 1;
            int linkDest = NeuralNets.generator.nextInt(getTopId()-1) + 1;
            Link newLink = new Link(getNodeForId(linkSource), getNodeForId(linkDest));
            addLink(newLink);
        }
    }