I'm serving my model using an export produced as this:
features_placeholder = tf.placeholder(tf.float32, None)
labels_placeholder = tf.placeholder(tf.float32, None)
# Training loop code
......
# Train is finished.
# Export model
tf.saved_model.simple_save(sess,param.logs_dir + 'model_export',
{"features": features_placeholder}, {"binary_classif": labels_placeholder})
Then, I'm making the following POST request (raw body):
{"instances" : [1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0]}
The error I get is the following:
{ "error": "You must feed a value for placeholder tensor \'Placeholder_1\' with dtype float\n\t [[Node: Placeholder_1 = Placeholder_output_shapes=[], dtype=DT_FLOAT, shape=, _device=\"/job:localhost/replica:0/task:0/device:CPU:0\"]]" }
Does anyone know what I'm doing wrong?