Generalize MasterWorker class to fit WorkerFamily objects using PSO
- Dominant language
- Python
- Stars
- 1
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
# Description
We want to be able to route all PSO jobs through the MasterWorker class and with the addition of the WorkerFamily class in #17, we'll need to generalize the MasterWorker for this to happen.
# Proposal
Specifically, we'll need to change how the children of the MasterWorker are initialized and how they're referred to.
## Initialization
Currently, Worker objects are spawned and stored in a list during the MasterWorker's initialization through the `initialize_workers` method. I propose we change this to `initialize_children` and pass in a `child_class` and `child_class_kwargs` as initialization parameters to the MasterWorker.
## Attribute Naming Convention
I also propose that we switch how we refer to the Worker objects in the MasterWorker class. I think we should switch the naming convention from "worker" to "children" to generalize this. This sort of generalization should carry over to the `WokerFamily` class as well, where the class spawns "children," not further "workers."
- [ ] Generalize initialization
- [x] Generalize naming convention for the repository
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.