https://github.com/pythoninthegrass/wine_quality
https://github.com/pythoninthegrass/wine_quality
Last synced: 11 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/pythoninthegrass/wine_quality
- Owner: pythoninthegrass
- Created: 2022-09-22T03:02:25.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-02-11T16:59:27.000Z (almost 3 years ago)
- Last Synced: 2025-01-11T16:50:24.134Z (about 1 year ago)
- Language: Jupyter Notebook
- Size: 2.94 MB
- Stars: 0
- Watchers: 2
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
Awesome Lists containing this project
README
# wine_quality

## Summary
Udacity course on data science.
**Table of Contents**
* [wine_quality](#wine_quality)
* [Summary](#summary)
* [Setup](#setup)
* [Usage](#usage)
* [Poetry](#poetry)
* [Docker](#docker)
* [Both](#both)
* [TODO](#todo)
* [Further Reading](#further-reading)
## Setup
* Install
* [editorconfig](https://editorconfig.org/)
* [asdf](https://asdf-vm.com/guide/getting-started.html#_2-download-asdf)
* [poetry](https://python-poetry.org/docs/)
* [docker](https://docs.docker.com/compose/install/)
* Download CSVs from [here](https://archive.ics.uci.edu/ml/machine-learning-databases/wine-quality/)
* Move to `csv` directory
## Usage
### Poetry
* Install requirements via Poetry:
```bash
poetry install
poetry run ipython kernel install --name "python3.10.7" --user
```
* Run Jupyter Lab
```bash
poetry shell
jupyter lab --ip=0.0.0.0 --port=8888 --no-browser
```
* Quit the server via `ctrl-c` in the terminal
* Enter `deactivate` to exit the Poetry virtual environment
### Docker
* Customize the `.env.example` and rename to `.env`
* General commands
```bash
# build image locally
docker-compose build --pull --no-cache
# start container
docker-compose up -d
# stop container
docker-compose stop
# remove container and network
docker-compose down
```
### Both
* Open a browser and navigate to `http://127.0.0.1:8888`
* Docker uses the token specified in `.env`
* Select the "python3.10.7" kernel if asked
* Open `refactor-wine-quality.ipynb` from the left-hand column
* Run cells by selecting them and pressing `shift-enter`
## TODO
* Get Jupyter working in [VSCode](https://github.com/microsoft/vscode-jupyter)
* `Makefile`
## Further Reading
[Starting JupyterLab](https://jupyterlab.readthedocs.io/en/stable/getting_started/starting.html)
[Jupyter Docker Stacks — Docker Stacks documentation](https://jupyter-docker-stacks.readthedocs.io/en/latest/index.html)
[Dockerizing Jupyter Projects](https://towardsdatascience.com/dockerizing-jupyter-projects-39aad547484a)