Python - Error at equals sign for no reason?
eval evaluates expressions.  Assignment in Python is not an expression, it's a statement.
But you don't need this anyway.  Make a list or dict to hold all of your values.
I'm using eval and pybrain to make neural networks. Here's it stripped down. Using python 3.6


    from pybrain import *

    numnn = 100

    eval("neuralNetwork" + chr(numnn) + " = buildNetwork(2, 3, 1, bias=True)")