GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - ra-led/python-remont-api: API for interior quality classification

BranchesTags
Open more actions menu

Latest commit

 

History

15 Commits
15 Commits

Folders and files

NameName
Last commit message
Last commit date
templates
templates
 
 
utils
utils
 
 
views
views
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
app.py
app.py
 
 
conf.py
conf.py
 
 
conf.yml
conf.yml
 
 
requirements.txt
requirements.txt
 
 
run.py
run.py
 
 
train_resnet.ipynb
train_resnet.ipynb
 
 

Repository files navigation

python-remont-api

API for interior quality classification

Getting Started

How to start with our app

Prerequisites

This is an example of how to list things you need to use the software and how to install them.

  • Python >= 3.6
$ sudo apt-get install software-properties-common
$ sudo add-apt-repository ppa:deadsnakes/ppa 
$ sudo apt-get update
$ sudo apt-get install python3.6
$ sudo apt install python3-pip
  • Git
$ sudo apt install git-all

Installation

  1. Clone the repo
$ git clone https://github.com/ra-led/python-remont-api.git
$ cd python-remont-api
  1. Install Python packages
$ pip3 install -r requirements.txt
  1. Download pre-trained weights Create model dir and start Python
$ mkdir models
$ python3

In Python console run

import gdown

url = 'https://drive.google.com/uc?id=1pewnHlXGvPEd0h6yzueIpKq8hlnmCU-E'
output = 'models/resnet18_baseline_cpu.torch'
gdown.download(url, output, quiet=False)

quit()

Start server

Start server with Flask default WSGI

$ python3 run.py

Server will start on port 5005, to change port set it in conf.yml

Alternativly, you can use Gunicorn WSGI

Launch http://{your_host_adres}:5005/

Usage

  • Interior class quality prediction

/predict_class POST

Params

file - image file for classification

Response JSON

{"predicted": "Bez otdelki" | "Luks" | "Standart" | "Trebuet kosmetiki" }

Example

curl -X POST -F 'file=@path/to/pictures/picture.jpg' http://127.0.0.1:5005/predict_class

About

API for interior quality classification

Resources

Readme
Activity

Stars

0 stars

Watchers

1 watching

Forks

0 forks
Report repository

Releases

Packages

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.