code: def unArrayify(self, gene):
          
          g = 0
          # if gene is too small an IndexError will be thrown
          for layer in self.layers:
              if layer.type != 'Input':
                  for i in range(layer.size):
                      layer.weight[i] = float( gene[g])
                      g += 1
          for connection in self.connections:
              for i in range(connection.fromLayer.size):
                  for j in range(connection.toLayer.size):
                      connection.weight[i][j] = gene[g]
                      g += 1
          # if gene is too long we may have a problem
          if len(gene) > g:
              raise IndexError('Argument to unArrayify is too long.', len(gene))
docs: Copies gene bias values and weights to network bias values and
          weights.