Add worker max threads

pull/1593/head
Piero Toffanin 2025-01-27 13:44:39 -05:00
rodzic d0139fccc2
commit 85c56df2e7
3 zmienionych plików z 5 dodań i 2 usunięć

Wyświetl plik

@ -17,7 +17,7 @@ def detect(orthophoto, model, progress_callback=None):
return {'error': "GeoDeep library is missing"}
try:
return {'output': gdetect(orthophoto, model, output_type='geojson', progress_callback=progress_callback)}
return {'output': gdetect(orthophoto, model, output_type='geojson', max_threads=settings.WORKERS_MAX_THREADS, progress_callback=progress_callback)}
except Exception as e:
return {'error': str(e)}

Wyświetl plik

@ -21,7 +21,7 @@ drf-nested-routers==0.11.1
funcsigs==1.0.2
futures==3.1.1
gunicorn==19.8.0
geodeep==0.9.4
geodeep==0.9.7
itypes==1.1.0
kombu==4.6.7
Markdown==3.3.4

Wyświetl plik

@ -384,6 +384,9 @@ UI_MAX_PROCESSING_NODES = None
# are removed (or None to disable)
CLEANUP_PARTIAL_TASKS = 72
# Maximum number of threads that a worker should use for processing
WORKERS_MAX_THREADS = 1
# Link to GCP docs
GCP_DOCS_LINK = "https://docs.opendronemap.org/gcp/#gcp-file-format"