Open Anaconda Prompt & create enviornment create env
conda create -n winequality python=3.7 -y
Activate the env
conda activate winequality
Create requirements.txt & install it
pip install -r requirements.txt
Create template.py & mentioned the directory structure to create, run it
python template.py
Create .gitignore file
put winequality.csv file in the data_given folder.
let initialise the git, files went untracked mode (U)
git init
Initialize the dvc & .dvcingnore file is created
git dvc
Add the winequality dataset into dvc, .dvc file is created
dvc add data_given\winequality.csv
Add all files into git , After that all files turned into Added mode (A)
git add .
Commit all the changes & then A mode clear ,
git commit -m "first commit"
.gitignore file is created automatically for winequality.csv files
let update REAME.md as it is modified
git add . && git commit -m "Update the README.md files"
Call Remote git remote directory & push the code
git remote add origin https://github.com/sainathpawar/MLOPS.git
git branch -M main
git push -u origin main
- Create get_data.py file under src directory to get the data
- Create load_data.py file to load the data with required preprocessing & save it under data\raw\winequality.csv
- add staged into dvc.yaml file
Once program is done do the testing uisng pytest & tox tox is providing virtual enviornmet for temporary testing
skipsdist = True is mentioned in tox.ini files becasue setup.py file is not there
To run the tox
tox
To reload the virutal enviornment
tox -r
To create python dsitribution to run on differnt machine you can share the tar file with anyone
python setup.py sdist bdist
setup commands - This will use to create package for your program for ex. Numpy or Pandas
pip install -e .
Packages install in your prgram
pip freeze
In a single line you can update the git repository
git add . && git commit -m "updated readme" && git push origin main
Install jupyter lab
pip install jupyterlab
Command to open jupyter notebook.
jupyter-lab