'Is it possible to serve multiple/dynamic tensorflow models from a single app instance?

I'm not sure if this is the right place to ask this question, it's strange to me and not sure how to address it.

I have a client who has a large number of TensorFlow models (1000+) and want a API to serve them. I do not want to do this manually.

I'm not sure if this solution works and I'm not sure how to validate before putting in a huge amount of effort.

  1. In a DB table save the format of the model inputs, outputs, and location of the model?
  2. When a specific API endpoint is called on my system, load the relevant model and schema to apply the prediction(keras.models.load_model('model.h5')) .

Does this approach work? or is there any challenges that I need to address in advance?



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source