Skip to main content

Multi-Modality

KosmosG

My implementation of the model KosmosG from "KOSMOS-G: Generating Images in Context with Multimodal Large Language Models"

Installation

pip install kosmosg

Usage

import torch
from kosmosg.main import KosmosG

# usage
img = torch.randn(1, 3, 256, 256)
text = torch.randint(0, 20000, (1, 1024))

model = KosmosG()
output = model(img, text)
print(output)

Architecture

text, image => KosmosG => text tokens with multi modality understanding

License

MIT

Todo

  • Create Aligner in pytorch
  • Create Diffusion module
  • Integrate these pieces
  • Create a training script

Metadata

Release files for kosmosg 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for kosmosg 0.0.4
File Size Uploaded
kosmosg-0.0.4.tar.gz 4.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for kosmosg 0.0.4
File Interpreter ABI Platform
kosmosg-0.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 9.5 kB

Release files / kosmosg-0.0.4.tar.gz

Download URL kosmosg-0.0.4.tar.gz
Size 4.7 kB
Tags Source
SHA-256 checksum
How to use checksums
2721a5d38684c47e2452717c44e5cdf039ea73de67a941da1ca2e13d861631b1
BLAKE2b-256 checksum
How to use checksums
267a7ef1e2efb021c0318b7a0c44eb9f65a1b22a684845885795022b537e4a1e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.2 CPython/3.11.0 Darwin/22.4.0

Release files / kosmosg-0.0.4-py3-none-any.whl

Download URL kosmosg-0.0.4-py3-none-any.whl
Size 4.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ae7206b315c6ab15f77fe63d94b26bb72d43216bdfef879f1187beca64731750
BLAKE2b-256 checksum
How to use checksums
8ede5461107f228385baa151c4309d95a7d625f3816c4644a7992ec9b47e4486
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/1.3.2 CPython/3.11.0 Darwin/22.4.0

Release history Release notifications | RSS feed

This release

0.0.4 This release

2 release files

0.0.3

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page