Uncategorized

python rest api for machine learning aiohttp bad load times – Stack Overflow


I am using aiohttp in python. I have a machine learning project that i want to make available over a restapi. i timed the functions and they dont take long to execute. They do not await the result, but check on progress and start the task. the problem is that the wait time is pretty long. i tried to find the issue and its not the function itself, but aiohttp to run the function or to send the result. the function itself is not the problem.(wait time 10s, function execution 2e-05). I just create a class with the project in it. Does anyone have a suggestion how to ensure a fast response time. is there a way to preallocate resources for the api or spawn the machine learning project in a seperate thread.



Source link

Leave a Reply

Your email address will not be published. Required fields are marked *