Spaces:
Runtime error
Runtime error
| import tensorflow as tf | |
| import joblib | |
| def load_model_and_preprocessor(model_path, preprocessor_path): | |
| # Load the neural network model | |
| model = tf.keras.models.load_model(model_path) | |
| # Load the preprocessor | |
| preprocessor = joblib.load(preprocessor_path) | |
| return model, preprocessor | |