You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+85
Original file line number
Diff line number
Diff line change
@@ -60,6 +60,91 @@ If you built a project that uses PyGAD, then please drop an e-mail to ahmed.f.ga
60
60
61
61
Please check the **Contact Us** section for more contact details.
62
62
63
+
# Life Cycle of PyGAD
64
+
65
+
The next figure lists the different stages in the lifecycle of an instance of the `pygad.GA` class. Note that PyGAD stops when either all generations are completed or when the function passed to the `on_generation` parameter returns the string `stop`.
Based on the used 3 generations as assigned to the `num_generations` argument, here is the output.
123
+
124
+
```
125
+
on_start()
126
+
127
+
on_fitness()
128
+
on_parents()
129
+
on_crossover()
130
+
on_mutation()
131
+
on_generation()
132
+
133
+
on_fitness()
134
+
on_parents()
135
+
on_crossover()
136
+
on_mutation()
137
+
on_generation()
138
+
139
+
on_fitness()
140
+
on_parents()
141
+
on_crossover()
142
+
on_mutation()
143
+
on_generation()
144
+
145
+
on_stop()
146
+
```
147
+
63
148
# Example
64
149
65
150
Check the [PyGAD's documentation](https://pygad.readthedocs.io/en/latest/README_pygad_ReadTheDocs.html) for information about the implementation of this example.
0 commit comments