in 5-Monitoring/config/inference.py [0:0]
def output_fn(prediction, response_content_type):
"""
After invoking predict_fn, the model server invokes `output_fn`.
An output_fn that just adds a column to the output and validates response_content_type
"""
print("Hello from the POST-processing function!!!")
appended_output = "hello from pos-processing function!!!"
predictions = [prediction, appended_output]
if response_content_type == "text/csv":
csv = ','.join(str(x) for x in predictions)
return
else:
raise ValueError("Content type {} is not supported.".format(response_content_type))