Everything is going really fast since the start of this project. But after only two months of hard work, I start the development of (kind of) the Proof Of Concept (P.O.C) !
I will not explain here what is a Proof Of Concept or what is it for, but I will try to explain how I proceed in my very specific case.
I will not explain here what is a Proof Of Concept or what is it for, but I will try to explain how I proceed in my very specific case.
1. State of the art
Since I consider a DCOP algorithm as part of my solution for a long time, I first reviewed a lot of different algorithm, trying to find the best one for my project. I take a look on ADOPT, DPOP, even some specific ones like CoCoA. Finally, I choose the DPOP algorithm (Dynamic Parameters Optimization Problem) which gives me more advantages :
- It is one of the fastest in the execution time. It is always a nice advantage.
- Also, the DPOP algorithm is a 100% decentralized method since all agents executes the same code : there are no “intelligent mediator” to manage them. This is really convenient since the system does not rely on a central process.
Coupled with this research phase, I made my own inquiries about the medical field, and more precisely, nurses work. My objective was to gain enough information about their process to define a clear purpose for my project. And to do so, I needed to understand their needs.
2. Mathematical aspect
With this first step, I define the main goal of my system :
“Avoid syringe pump to ring without involving nurses too often”
Now that it was said, it was time to start the tough part : I needed to translate my constraints in a mathematical language in order to transcribe it inside the DPOP algorithm. This is required because the algorithm optimize constraints through a (mathematical) minimizing function. Therefore, I need to describe my constraints as functions. Above are some examples.
For Mi = {m1, …, ml} the set of devices linked to the agent i, if the agent has no devices, then there is no need to call the nurse.This next function transcribe the following constraint : If two agents are in the same geographical area (= they are neighbors), they can eventually synchronize themselves in order to avoid two interventions in a t_synchro laps of time.
To understand those functions, notes that vi is the hypothetical time that remains before the next nurse passage in the room. For instance, if vi = 5, it means that the next passage of the nurse is encouraged in the next 5 minutes. Thus, the algorithm try to find the best vi affectations for each agent i of the system depending on those constraints (by trying to minimize their results).
3. Hands on keyboard
With those constraints, I finally start to code ! Here is a photo of the current installation.
I am working with two raspberry pi : each one of them is an agent – which mean that my DPOP algorithm is running on both of them in the same time.
I also have an AVNET Linux server which run a “server” specific code. This process is here to give a kind of Let’s go! signal to all agents. This Let’s go! allow all agents to start the DPOP algorithm in the same time. This is just for implementation. Maybe I will remove it later, when my agents will be more advanced.
For those who are interested, I code this algorithm in Python 3, and my agents/server are communicating with an MQTT Protocol.