Reka Torch - Pytorch
Project description
Reka Torch
Implementation of the model: "Reka Core, Flash, and Edge: A Series of Powerful Multimodal Language Models" in PyTorch. PAPER LINK
Install
pip3 install -U reka-torch
Usage
import torch # Importing the torch library
from reka_torch.model import Reka # Importing the Reka model from the reka_torch package
text = torch.randint(0, 10000, (2, 512)) # Generating a random tensor of shape (2, 512) with values between 0 and 10000
img = torch.randn(2, 3, 224, 224) # Generating a random tensor of shape (2, 3, 224, 224) with values from a normal distribution
audio = torch.randn(2, 1000) # Generating a random tensor of shape (2, 1000) with values from a normal distribution
video = torch.randn(2, 3, 16, 224, 224) # Generating a random tensor of shape (2, 3, 16, 224, 224) with values from a normal distribution
model = Reka(512) # Creating an instance of the Reka model with input size 512
out = model(text, img, audio, video) # Forward pass through the model with the input tensors
print(out.shape) # Printing the shape of the output tensor
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
reka_torch-0.0.2.tar.gz
(4.5 kB
view hashes)
Built Distribution
Close
Hashes for reka_torch-0.0.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e05b598de41dbaa2aed22111ae64acf9f28035b2d1a82836f5c643f6f9dcb5f7 |
|
MD5 | d4bf16645542cc8077119af995eae257 |
|
BLAKE2b-256 | 97e1fbc2e0c9c7a687d86599574f56e7f8e8b5f8bf32b5f9490710736d4b229d |