Skip to content

Conversation

perib
Copy link
Contributor

@perib perib commented Apr 9, 2025

What does this PR do?

FSSNode was not returning True or False for the mutation/crossover operations as required.
Additionally, when only a single feature set was passed in, there would be an error thrown. This was found in issue #1366

Where should the reviewer start?

How should this PR be tested?

subset_1_dict  = { "sense_strands" :  ['a', 'b', 'c']}
fss_1 = FSSNode(subsets=subset_1_dict)

ind1 = fss_1.generate()

for i in range(1000):
    ind1.mutate()

Before this would throw an error like :

File "/scratch2/users/mpb703/conda_environments/tpot_v1/lib/python3.10/site-packages/tpot/search_spaces/nodes/fss_node.py", line 113, in mutate self.selected_subset_name = rng.choice(names) File "numpy/random/_generator.pyx", line 803, in numpy.random._generator.Generator.choice ValueError: a cannot be empty unless no samples are take

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant