All Projects → svpino → clip-container

svpino / clip-container

Licence: other
A containerized REST API around OpenAI's CLIP model.

Programming Languages

python
139335 projects - #7 most used programming language
Dockerfile
14818 projects

Projects that are alternatives of or similar to clip-container

aws-customer-churn-pipeline
An End to End Customer Churn Prediction solution using AWS services.
Stars: ✭ 30 (-34.78%)
Mutual labels:  sagemaker
video features
Extract video features from raw videos using multiple GPUs. We support RAFT and PWC flow frames as well as S3D, I3D, R(2+1)D, VGGish, CLIP, ResNet features.
Stars: ✭ 225 (+389.13%)
Mutual labels:  clip
aws-is-how
Know How Guide and Hands on Guide for AWS
Stars: ✭ 27 (-41.3%)
Mutual labels:  sagemaker
studio-lab-examples
Example notebooks for working with SageMaker Studio Lab. Sign up for an account at the link below!
Stars: ✭ 319 (+593.48%)
Mutual labels:  sagemaker
awesome-aws-research
A curated list of awesome Amazon Web Services (AWS) libraries, open source repos, guides, blogs, and other resources for Academic Researchers new to AWS
Stars: ✭ 41 (-10.87%)
Mutual labels:  sagemaker
videoclip
Easily create videoclips with mpv.
Stars: ✭ 49 (+6.52%)
Mutual labels:  clip
datajob
Build and deploy a serverless data pipeline on AWS with no effort.
Stars: ✭ 101 (+119.57%)
Mutual labels:  sagemaker
photo-magician
🎨 provide some common image process apis with canvas
Stars: ✭ 12 (-73.91%)
Mutual labels:  clip
clip-italian
CLIP (Contrastive Language–Image Pre-training) for Italian
Stars: ✭ 113 (+145.65%)
Mutual labels:  clip
map-floodwater-satellite-imagery
This repository focuses on training semantic segmentation models to predict the presence of floodwater for disaster prevention. Models were trained using SageMaker and Colab.
Stars: ✭ 21 (-54.35%)
Mutual labels:  sagemaker
natural-language-joint-query-search
Search photos on Unsplash based on OpenAI's CLIP model, support search with joint image+text queries and attention visualization.
Stars: ✭ 143 (+210.87%)
Mutual labels:  clip
sagemaker-xgboost-container
This is the Docker container based on open source framework XGBoost (https://xgboost.readthedocs.io/en/latest/) to allow customers use their own XGBoost scripts in SageMaker.
Stars: ✭ 93 (+102.17%)
Mutual labels:  sagemaker
fauxClip
Clipboard support for Vim without +clipboard
Stars: ✭ 32 (-30.43%)
Mutual labels:  clip
hub
Public reusable components for Polyaxon
Stars: ✭ 8 (-82.61%)
Mutual labels:  sagemaker
MoTIS
Mobile(iOS) Text-to-Image search powered by multimodal semantic representation models(e.g., OpenAI's CLIP). Accepted at NAACL 2022.
Stars: ✭ 60 (+30.43%)
Mutual labels:  clip
DeployMachineLearningModels
This Repo Contains Deployment of Machine Learning Models on various cloud services like Azure, Heroku, AWS,GCP etc
Stars: ✭ 14 (-69.57%)
Mutual labels:  sagemaker
Transformer-MM-Explainability
[ICCV 2021- Oral] Official PyTorch implementation for Generic Attention-model Explainability for Interpreting Bi-Modal and Encoder-Decoder Transformers, a novel method to visualize any Transformer-based network. Including examples for DETR, VQA.
Stars: ✭ 484 (+952.17%)
Mutual labels:  clip
mlops-platforms
Compare MLOps Platforms. Breakdowns of SageMaker, VertexAI, AzureML, Dataiku, Databricks, h2o, kubeflow, mlflow...
Stars: ✭ 293 (+536.96%)
Mutual labels:  sagemaker
Hello-AWS-Data-Services
Sample code for AWS data service and ML courses on LinkedIn Learning
Stars: ✭ 144 (+213.04%)
Mutual labels:  sagemaker
Paddle-CLIP
A PaddlePaddle version implementation of CLIP of OpenAI.
Stars: ✭ 51 (+10.87%)
Mutual labels:  clip

OpenAI's CLIP — REST API

This is a container wrapping OpenAI's CLIP model in a RESTful interface.

Running the container locally

First, build the container:

docker build -t clip-container:latest .

Then, you can run it:

docker run -it -p 8080:8080 --name "clip-container" --rm clip-container:latest /opt/ml/code/serve

Sending requests:

The container exposes two different endpoints:

  • GET /ping: Returns 200 status if the container is working properly.
  • POST /invocations: Processes a list of images and returns the list of labels with their corresponding probabilities.

Here is an example request assuming the container is listening in port 8080:

curl --location --request POST 'http://localhost:8080/invocations' \
--header 'Content-Type: application/json' \
--data-raw '{
    "images": [
        "https://images.unsplash.com/photo-1597308680537-1ba44407ffc0?ixid=MXwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHw%3D&ixlib=rb-1.2.1&auto=format&fit=crop&w=1834&q=80",
        "https://images.unsplash.com/photo-1589270216117-7972b3082c7d?ixid=MXwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHw%3D&ixlib=rb-1.2.1&auto=format&fit=crop&w=1834&q=80"],
    "classes": ["person", "bag", "person with a bag", "woman riding a horse", "woman with a bag", "woman with black shirt and a bag"]
}'

The response looks like this:

[
    [
        [
            5,
            4,
            2
        ],
        [
            "woman with black shirt and a bag",
            "woman with a bag",
            "person with a bag"
        ],
        [
            0.8420771360397339,
            0.13471755385398865,
            0.020683499053120613
        ]
    ],
    [
        [
            2,
            5,
            4
        ],
        [
            "person with a bag",
            "woman with black shirt and a bag",
            "woman with a bag"
        ],
        [
            0.8793349266052246,
            0.06026121601462364,
            0.027413660660386086
        ]
    ]
]

SageMaker Integration

This container is compatible with SageMaker so you should be able to host it as a SageMaker endpoint with no modifications. The code supports GPU and CPU instances.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].