Fixing the collision detection

Edited the random generator of the neural networks to have negative
weights too.