The-School-of-AI / emlov3-session-03-dlwizard

emlov3-session-03-dlwizard created by GitHub Classroom

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Review Assignment Due Date Open in Visual Studio Code

emlov3-session-03

MNIST Training, Evaluation, and Inference using Docker Compose

Introduction

Here we have used docker compose to train, evaluate and inference the MNIST dataset. We have used a shared volume named mnist to share the data between the containers. The data is downloaded from the internet and saved in the data directory inside it. We have used PyTorch to train the model. The model is trained on the MNIST dataset and the trained model is saved in the models directory. The trained model is then used to evaluate the model on the test dataset and the accuracy matric is saved in eval_results.json file. The trained model is also used to inference the model on the test dataset and the inference results are saved in the results directory in mnist volume. Model code is also shared between the containers. Steps to run the training, evaluation and inference are given below:

Install Docker

Follow the instructions on the Docker website to install Docker on your machine.

Install Docker Compose

Follow the instructions on the Docker website to install Docker Compose on your machine.

Clone the Repository

Clone the repository to your local machine using the following command:

git clone repo link

Build the Docker Images

Build the Docker images using the following command:

docker-compose build

Run the training Docker Container

To run the training Docker container, use the following command:

docker-compose run train

Run the evaluation Docker Container

To run the evaluation Docker container, use the following command:

docker-compose run evaluate

Run the inference Docker Container

To run the inference Docker container, use the following command:

docker-compose run infer

References

Team Members

About

emlov3-session-03-dlwizard created by GitHub Classroom


Languages

Language:Python 91.9%Language:Shell 8.1%