I have just started to use the DEAP package in python. Following the tutorial, I can't understand this statement:
toolbox.register("cross",tools.cxTwoPoint)
I understand that tools.cxTwoPoint
is to call the cxTwoPoint
function. However, I checked the source code, the cxTwoPoint
function is not within tools
module, and it is a defined function within crossover.py
. Also, I didn't find any statement in tools.py
which may relate to crossover.py
or cxTwoPoint
.
Can someone help me? Many many thanks!!!