Lambda Function not able to invoke sagemaker endpoint
问题 predict = [0.1,0.2] payload = { "instances": [ { "features": predict } ] } response = linear_regressor.predict(json.dumps(payload)) predictions = json.loads(response) print(json.dumps(predictions, indent=2)) The above code is able to invoke the endpoint which is the linear-learner endpoint and give the below result. { "predictions": [ { "score": 0.13421717286109924 } ] } But when I try to invoke the endpoint using below lambda function, import json import io import boto3 client = boto3.client