From 9f3eb7111e3ada742672451ed67a3c79c88c1c8b Mon Sep 17 00:00:00 2001 From: "nabil.abdennad" <nabil.abdennadher@hesge.ch> Date: Mon, 10 Jun 2024 16:18:48 +0200 Subject: [PATCH] fine tunig the text - Nabil --- Local-Without-Prediction/README.md | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/Local-Without-Prediction/README.md b/Local-Without-Prediction/README.md index f9be7b8..5c9aea8 100644 --- a/Local-Without-Prediction/README.md +++ b/Local-Without-Prediction/README.md @@ -16,23 +16,26 @@ The exercise involves the following steps, [main file](./sock.py): - Each node reads its neighbors file. - Each node starts a server socket to listen for incoming connections 2. Message Exchange: - - During the first *x* iterations, each node sends a message of type REQUEST_WEIGHT to all its neighbors. - - Upon receiving a message of type REQUEST_WEIGHT, a node responds by sending back a message of type WEIGHTS to the requesting node. - - The algorithm runs for a total of *N* iterations - - Each node logs its activities and messages + - Each node sends a message of type "REQUEST_WEIGHT" to all its neighbors. + - Upon receiving a message of type REQUEST_WEIGHT, a node responds by sending back a message of type "W + - Each node logs its activities and messages. ## Neighbors Configuration The [neighbors configuration](./neighbors/) is a directory that contains the neighbors files for all the nodes. Ensure that you have a corresponding number of neighbor files in the neighbors directory, named neighbors0.txt, neighbors1.txt, etc. ## Dockerfile -Once your code is developed, it is time to build the container image, [DockerFile](./Dockerfile) +To build the container image, [DockerFile](./Dockerfile) + + docker build -t <image_name> . + +Where <image_name> is the name you have chosen for your image. ## Local Deployment -For local deployment, you can use the [script](./generate-docker-compose.py) to generate a Docker Compose file. This script takes the number of nodes in your network as an argument and generates the Docker Compose configuration. To generate the Docker Compose file, run the [script](./generate-docker-compose.py) with the desired number of nodes: +You can use the [script](./generate-docker-compose.py) to generate a Docker Compose file. This script takes the number of nodes in your network as an argument and generates the Docker Compose configuration. To generate the Docker Compose file, run the [script](./generate-docker-compose.py) with the desired number of nodes: python generate_docker_compose.py <num_nodes> -Replace <num_nodes> with the number of nodes in your network. +Where <num_nodes> is the number of nodes in your network. Replace the varibale `image` (line 3) with your previouly built container image. -- GitLab