{"id":15158065,"url":"https://github.com/soluto/python-flask-sklearn-docker-template","last_synced_at":"2025-09-30T07:31:02.697Z","repository":{"id":24789429,"uuid":"97234261","full_name":"Soluto/python-flask-sklearn-docker-template","owner":"Soluto","description":"A simple example of python api for real time machine learning, using scikit-learn, Flask and Docker","archived":true,"fork":false,"pushed_at":"2023-08-28T16:27:25.000Z","size":14,"stargazers_count":135,"open_issues_count":0,"forks_count":41,"subscribers_count":23,"default_branch":"master","last_synced_at":"2024-09-27T20:22:31.168Z","etag":null,"topics":["docker","flask","python","scikit-learn","sklearn","soluto-open-source"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Soluto.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-07-14T13:00:56.000Z","updated_at":"2023-11-07T12:46:04.000Z","dependencies_parsed_at":"2024-09-02T16:21:09.294Z","dependency_job_id":null,"html_url":"https://github.com/Soluto/python-flask-sklearn-docker-template","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soluto%2Fpython-flask-sklearn-docker-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soluto%2Fpython-flask-sklearn-docker-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soluto%2Fpython-flask-sklearn-docker-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Soluto%2Fpython-flask-sklearn-docker-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Soluto","download_url":"https://codeload.github.com/Soluto/python-flask-sklearn-docker-template/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":234712890,"owners_count":18875527,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","flask","python","scikit-learn","sklearn","soluto-open-source"],"created_at":"2024-09-26T20:22:27.407Z","updated_at":"2025-09-30T07:30:57.442Z","avatar_url":"https://github.com/Soluto.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"## DEPRECATED\nThis repository is no longer maintained and has been archived. Feel free to browse the code, but please migrate to other solutions.\n\n## python-flask-docker-sklearn-template\nA simple example of python api for real time machine learning.\nOn init, a simple linear regression model is created and saved on machine. On request arrival for prediction, the simple model is loaded and returning prediction.    \nFor more information read [this post](https://blog.solutotlv.com/deployed-scikit-learn-model-flask-docker/?utm_source=Github\u0026utm_medium=python-flask-sklearn-docker-template)\n\n# requirements  \ndocker installed\n\n# Run on docker - local \ndocker build . -t {some tag name}  -f ./Dockerfile_local  \ndetached : docker run -p 3000:5000 -d {some tag name}  \ninteractive (recommended for debug): docker run -p 3000:5000 -it {some tag name}  \n\n# Run on docker - production \nUsing uWSGI and nginx for production  \ndocker build . -t {some tag name}   \ndetached : docker run -p 3000:80 -d {some tag name}  \ninteractive (recommended for debug): docker run -p 3000:80 -it {some tag name}  \n\n# Run on local computer\npython -m venv env  \nsource env/bin/activate  \npython -m pip install -r ./requirements.txt  \npython main.py  \n\n# Use sample api  \n127.0.0.1:3000/isAlive  \n127.0.0.1:3000/prediction/api/v1.0/some_prediction?f1=4\u0026f2=4\u0026f3=4  \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoluto%2Fpython-flask-sklearn-docker-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsoluto%2Fpython-flask-sklearn-docker-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsoluto%2Fpython-flask-sklearn-docker-template/lists"}