Open AnastasiaProkaieva opened 1 year ago
Hey @AnastasiaProkaieva -
The issue with the first model was that the library versions were not logged in the conda env.
conda_env['dependencies'][2]['pip'] += [f'xgboost=={xgboost.__version__}']
fixes the xgboost version mismatch.
For the second model, I am not sure why V2 cannot serve it. There isn't enough log to determine the cause. The error message I am seeing is
Back-off pulling image "harbor-modelserving-aws-us-west-2.cloud.databricks.com/servingv2-1444828305810485/images@sha256:5f373393d230823ce4732b3d3f7ccac54b63480bc9f78011e3c7a2e51444c7df".
The second model can be served with serving V1, with some minor update in the input_json format in the mlflow 2.x style.
Made a PR for these fixes: https://github.com/databricks-industry-solutions/fraud-orchestration/pull/4
First Part
First part of the SA contains a dff_model, this notebooks present a
XGBWrapper
, the best model that was registered. While serving encountering an error:BAD_REQUEST: Encountered an unexpected error while evaluating the model. Verify that the serialized input Dataframe is compatible with the model for inference. Error ''XGBModel' object has no attribute 'callbacks''
The code to serve model was the following:
The input to serve was following:
I also tried with different input, but then another error was raised (which I believe is due to the bad input this time) :
BAD_REQUEST: Encountered an unexpected error while evaluating the model. Verify that the serialized input Dataframe is compatible with the model for inference. Error ‘only integers, slices (
:), ellipsis (
...), numpy.newaxis (
None) and integer or boolean arrays are valid indices’
Input was the following one:“inputs”: [[10.0, 11500.0, 20153.38, 23000.0, 2647.55, 2.0, 0.0, 10.33, 209.4, 51.0, 0.0, 0.0, 0.0, 779.0, 0.0, 18.0, 0.0, 90.0, 10.48], [12.0, 2500.0, 2639.33, 5000.0, 2200.72, 3.0, 0.0, 12.44, 172.39, 22.0, 0.0, 0.0, 0.0, 999.0, 577.0, 781.0, 0.0, 90.0, 0.0]]}
Second part
Second part of the SA dff_orchestrator contains model serving, but it seems some libraries cannot be installed on V2 serving option - would be great to add a fix into it. The error says: