-
Notifications
You must be signed in to change notification settings - Fork 91
Description
TypeError: only 0-dimensional arrays can be converted to Python scalars
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "C:\Users\25-09256\Documents\GitHub\jes\jes.py", line 36, in
ui.detectEvents()
~~~~~~~~~~~~~~~^^
File "C:\Users\25-09256\Documents\GitHub\jes\jes_ui.py", line 396, in detectEvents
button.click()
~~~~~~~~~~~~^^
File "C:\Users\25-09256\Documents\GitHub\jes\jes_button.py", line 29, in click
self.func(self)
~~~~~~~~~^^^^^^
File "C:\Users\25-09256\Documents\GitHub\jes\jes_sim.py", line 212, in doGeneration
nextCreatures[winner] = self.mutate(self.creatures[gen][winner],(gen+1)*self.c_count+winner)
~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\25-09256\Documents\GitHub\jes\jes_sim.py", line 244, in mutate
newDNA, newSpecies, cwc = parent.getMutatedDNA(self)
~~~~~~~~~~~~~~~~~~~~^^^^^^
File "C:\Users\25-09256\Documents\GitHub\jes\jes_creature.py", line 117, in getMutatedDNA
result[big_mut_loc+i] += delta
~~~~~~^^^^^^^^^^^^^^^
ValueError: setting an array element with a sequence.
What could be the problem behind this?