qformer - Pytorch
Project description
Qformer
Implementation of Qformer from BLIP2 in Zeta Lego blocks. The implementation is here straight from Figure 2. In particular the image block and text block.
Install
pip3 install qformer
Usage
import torch
from qformer import QFormer
x = torch.randn(1, 32, 512)
img = torch.randn(1, 32, 512)
qformer = QFormer(512, 8, 8, 0.1, 2, 2)
y = qformer(x, img)
print(y.shape)
License
MIT
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
qformer-0.0.3.tar.gz
(4.6 kB
view details)
Built Distribution
File details
Details for the file qformer-0.0.3.tar.gz
.
File metadata
- Download URL: qformer-0.0.3.tar.gz
- Upload date:
- Size: 4.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.2 CPython/3.11.0 Darwin/22.4.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2a1001f3210e116b3f840802e3d5b27073a1ebdc298bfd2fb2ade411ecd4f9c4 |
|
MD5 | 5e9e9e9aa0f84cdefbf60a0b91b01fe4 |
|
BLAKE2b-256 | 7e6ba52982d5a8984d164e0ce90dc74770b2e954df005cdc53f45eecdb13d161 |
File details
Details for the file qformer-0.0.3-py3-none-any.whl
.
File metadata
- Download URL: qformer-0.0.3-py3-none-any.whl
- Upload date:
- Size: 4.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.3.2 CPython/3.11.0 Darwin/22.4.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6794c58ffcf81e374e83c5cbf58dc69959134323ac4536612f8038d002d6534c |
|
MD5 | 3f8b3c65c518f4693bd79e8cf031fd8d |
|
BLAKE2b-256 | c641cdc4be9eddfce275b8f8d8e283f6318488dececee25c172230e9f333fe9e |