T
T
Timebird2019-07-19 22:35:00
Python
Timebird, 2019-07-19 22:35:00

How to write a site with image processing?

Essence: you need to write a website with a button like "Send photos".
Photos are recorded in the database, processed, the processing result is displayed in the form of a text-line, and the site displays this text.
Processing by mathematical methods is supposed to be quite complicated.
Question: how to write such a site easier / faster / more rational? In the future, it is planned to expand the functionality.
From the stack: I program moderately in python, weakly in pure C.
Is Flask my choice? Are there alternatives? Where to begin?
Advise courses (not extensive, I don’t plan to go far) on this topic?
Interested only in the inner part, layout is not needed.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
R
Roman Mirilaczvili, 2019-07-19
@2ord

You can start with Python. After all, image processing will most likely be performed by means of libraries in other languages, such as C. In this case, Python only plays the role of a bundle. Flask is a pretty good option.
There are many alternatives, but the gain may be small.
Here, most likely, the architecture of the application itself is more important. If it is expected that image processing will take more than a second, then it is better to use a queue and do processing in the background, then notify the web server when it is finished so that it can notify the web client in turn. For example, using Flask-SSE. Something like this.

T
ThunderCat, 2019-07-19
@ThunderCat

The ideal option is to run something low-level, run it as a service or call it from the command line, a layer that works with the web interface in any language with a developed stack towards the web: puff, python, javascript.
As an option - write everything in Java.

X
xmoonlight, 2019-07-20
@xmoonlight

1. Handlers (by complex mathematical methods) are microservices. They take the photo from the database, process the image and put it back into the database (putting a "flag": "Completed"). They can be written in any language (C/C++, Python, etc.).
2. And the web face itself - on something more familiar, on the same PHP.

M
metajiji, 2019-07-20
@metajiji

Django + celery is a great choice for developing things like this quickly. For image processing, you can write tools in C or Go that will be launched by celery and in general there will be a good result.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question