paulvangentcom / python_corona_simulation

An agent-based simulation of corona and other viruses in python
GNU General Public License v3.0
292 stars 76 forks source link

In population.py, something aggregation can be applied #36

Closed mamushi641 closed 3 years ago

mamushi641 commented 3 years ago

Hello, I am a student of EECS 3311. Through the study of aggregation this week, I think that part of the code can be aggregated. Here are some of my thoughts

Because population.py is unordered, I have encapsulated the program to a certain extent through the study of aggregation, so that it is clearer and more convenient to read and use.

something I changed: 1.I aggregated the population initialization so that the method would not exist as a separate def 2.I aggregated initialize_destination_matrix and set_destination_bounds, because these two defs operate on destination 3.I aggregate save_data and save_population, because these two operations are storing data