Salary Predictor Model using machine learning on Docker

Summer Program 2021 #Task1

Task Description:

step 1:We have collected Data and formed a dataset.

Step 2: Prepare an ML model of linear regression on Jupyter NoteBook

Step 3: Check if the Docker is available

We use the command: docker info

Step 4: Download CentOS latest version image from Docker Hub

We use the command: docker pull centos:latest

Step 5: Create a Container with the help of CentOS image

We use the command: docker run -i -t — name=<name> centos:latest

Step 6: Download Python in the Container

We use the command: yum install python3

Step 7: Install the necessary libraries for the Python

pip3 install NumPy

pip3 install pandas

pip3 install scikit-learn

Step 8: Copy the ML Model from the host to the container

Copy the model and .csv file from the host machine to the guest machine

We use the command:

docker cp <model_name> <container_name>:/<model_name>

Step 9: Create a Model file in the Container

Open a vi editor and make a file with .py extension.

Step 10: Run the model on python

To run the code for test we use the command: python3 model.py

Thank you!

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store