Skip to content

Get the multimodal embeddings #117

Description

@hessaAlawwad

Thank you for the great model.

I wonder how can I get the multimodat embedding of different inputs like image and its caption usign Imagebind?

if I can get that then how can it be compared to CLIP?

Activity

  1. hessaAlawwad commented on May 22, 2024

    @hessaAlawwad
    Author

    Please bear with me if my questions does not make sense but I am still learning.
    I see after I give it an input consist of two modality ( text and image) it retrurn two different embeddings.

    # Load data
    inputs = {
        ModalityType.TEXT: data.load_and_transform_text(text_list, device),
        ModalityType.VISION: data.load_and_transform_vision_data(image_paths, device),
    }
    
    with torch.no_grad():
        embeddings = model(inputs)
    
    print(embeddings[ModalityType.VISION])
    print(embeddings[ModalityType.TEXT])
    

    but I couldn't find something about getting one embeddings for the both.

  2. lixinghe1999 commented on Jun 25, 2024

    @lixinghe1999

    As far as I know, there is no multimodal embedding.
    You got embedding for each modality and compare them (Text * Image) to see whether they match that the ideas of Imagebind and CLIP in short.

    If you insist to get one, naive way is to add or take the average of them, however I believe it is not appealling.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions