Skip to content

AttributeError: module 'genetics' has no attribute 'DNAComponent' #7

@aadesousa

Description

@aadesousa

punched in a snippet of the example code to create my own GA and it returned this:

AttributeError: module 'genetics' has no attribute 'DNAComponent'

SYNTAX:

import string
import random
import genetics
import numpy
class genetic(genetics.DNAComponent):
def ed(e):
solution = e == 'win'

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions