简体   繁体   中英

Python have program running and ready for when called

To be clear I have no idea what I'm doing here and any help would be useful.

I have a number of saved files, Keras neural network models and dataframes. I want to create a program that loads all of these files so that the data is there and waiting for when needed.

Any data sent to the algorithm will be standardised and fed into the neural networks.

The algorithm may be called hundreds of times in quick succession and so I don't want to have to import the model and standardisation parameters every time as it will slow everything down.

As I understand it the plan is to have this program running in the background on a server and then somehow call it when required.

How would I go about setting up something like this? I'm asking here first because I've never attempted anything like this before and I don't even know where to start. I'm really hoping you can help me find some direction or maybe provide an example of something similar. Even a search term that would help me research would be useful.

Many thanks

Wrap it in a Python based web server listening on some agreed-on port. Hit it with HTTP requests when you want to supply a new file or retrieve results.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM