Deploy ONXX model to Sagemaker
Hi,I am wondering if anyone has an example of how to deploy an ONXX converted model to Sagemaker.What is the procedure to create a model artifact for deployment?And is there anything changing when deploying the model to Sagemaker?Thanks
2022-07-13T13:40:30Z
Hey@kamneb,Sadly there is no example yet for it. I hope i can create on soon.The process would be similar tothis example. Except that you would need to upload you onnx model and create arequirements.txtincluding onnxruntime/optimum and write ainfernece.py
2022-07-14T08:15:07Z
Thanks@philschmid. I just changed the path to the onxx model in theinference.pyfile and I add the dependency in therequirements.txtfile. it works well.
2023-01-31T21:41:09Z
@kamnebcan you share your requirements.txt and your inference.py?a little confused how you load the onnx runtime as the HuggingFace container expects an transformers automodel object.
2023-06-05T15:56:40Z
I made a blog post walking through how to do this for a simple casehere.  Hopefully that can help streamline it for any folks trying to do this in the future : )
2024-04-18T08:27:07Z
@nbertagnolliWhere’s the blog? The ‘here’ link does not take us there.
2024-04-18T16:15:20Z
Oh no sorry! Does this one work?Deploy an ONNX Transformer to Sagemaker.