|
hi, got another issue, when using the random_swap function it returns the following error : │ 105 │ │ new_genotype = np.where(mask, mutator, individual).astype(int).tolist() │ list object has no attribute astype. which seems coherent as new_genotype is converted to a list the line above ... from a000.py file I remove the astype(int).tolist() on line 105 and it works like a charm :) Thought ? |
Answered by
Jacopo-DM
Sep 6, 2025
Replies: 1 comment
|
As I mentioned on Canvas: That is a bug indeed; we call "astype(int).tolist()" twice. Good catch! |
0 replies
Answer selected by
Jacopo-DM
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
As I mentioned on Canvas:
That is a bug indeed; we call "astype(int).tolist()" twice. Good catch!
If you notice, we double "astype(int).tolist()" on both line 105 and 106, removing it from 105 makes the most sense.
(I will make the same fix)