Deprecated: This blog article is deprecated. We strive to rapidly improve our product and some of the information contained in this post may no longer be accurate or applicable. For the most current instructions on deploying a model like CLIP to Banana, please check our updated documentation.
Let's demo how you can deploy the machine learning model CLIP to production on serverless GPUs. For reference, we are deploying CLIP ViT B 32 from HuggingFace.
This tutorial should only take approx. 10 minutes (minus build time) to complete, as we have a template ready for you to use. Let's begin!
BONUS: All new users to Banana get 1 hour of FREE GPU time to get comfortable with our serverless platform and test it out. Ship that project! :)
How to Deploy CLIP on Serverless GPUs
1. Fork Banana's CLIP Serverless Repo
Fork this repository into a private repo to work from. The repository you forked is a version of the Banana serverless framework that has been modified to run CLIP. Lucky for you, that makes this tutorial very simple! You can make further customization to this repo if you want but that is an optional step.
Note: We highly recommend you take 2 minutes to read our docs about the Banana Serverless Framework to understand how it functions. Doing so will ensure you get maximum performance and cost effectiveness with Banana when you deploy.
2. Create Banana Account and Deploy CLIP
Once the repo is forked, simply login to your Banana Dashboard and click the "New Model" button.
A popup will appear looking like this:
Select "GitHub Repo", and choose the GitHub repository you made for CLIP. Click "Deploy" and the model will start to build. The build process can take up to 1 hour so be patient, though it usually is much faster than that.
You'll see the Model Status change from "Building" to "Deployed" when it's ready to be called.
You can also monitor the status of your build in the Model Logs tab.
3. Call your CLIP Model
After your model has built, it's ready to run in production! Choose the programming language you plan to use (Python, Node, Go) and then jump over to the Banana SDK. Within the SDK you will see example code snippets of how you can call your CLIP model.
That's it! Congratulations on running CLIP on serverless GPUs. You are officially deployed in production!
Reach out to us if you have any questions or want to talk about CLIP. We're around on our Discord or by tweeting us on Twitter. What other machine learning models would you like to see a deployment tutorial for? Let us know!