ahmedh409 / deepfake-detection

GNU General Public License v3.0
4 stars 1 forks source link

Simulator #4

Closed sambux1 closed 2 years ago

sambux1 commented 2 years ago

We need some way to test the entire network without running nodes on several computers. A local simulation with nodes which communicate using TCP channels should be developed for testing. We might be able to set up the network so it can be tested across multiple processes.

sambux1 commented 2 years ago

We now have a simulation.cpp file which spawns n nodes and runs them each as an individual process. The nodes currently execute a dummy routine and do nothing useful.

Once the nodes have real abilities, we will need to configure the simulator to take input regarding what to do and pass the input to a specific node to control its actions.

sambux1 commented 2 years ago

The bulk of the work on this is done. We have a Simulator class that spawns n nodes as independent processes and can pass input to them through their standard input (piping). The nodes each run a separate thread to listen for standard input and pass commands to the main thread, which converts commands into actions. The only work left to do before closing this issue is to add actual actions that the simulator can perform by passing the corresponding command to a node.

sambux1 commented 2 years ago

This is done. There are tiny features to add, so I'm closing this topic and adding the small items to the v0.2 cleanup issue.