removed unnessecary runs

This commit is contained in:
=
2024-02-08 13:13:17 +01:00
parent 13456bc7aa
commit edb487bd98

View File

@@ -40,6 +40,9 @@ end
function generate_children(pcube::PolyCube, n_max::Int) function generate_children(pcube::PolyCube, n_max::Int)
cubes = pcube.cubes cubes = pcube.cubes
allowed_growth = n_max - length(cubes) allowed_growth = n_max - length(cubes)
if allowed_growth == 0
return []
end
growth_candidates = Vector{Coord}(undef, 0) growth_candidates = Vector{Coord}(undef, 0)
for root_cube pcube.last_added for root_cube pcube.last_added
for neighbor neighbors(root_cube...) for neighbor neighbors(root_cube...)