YAML Metadata Warning: empty or missing yaml metadata in repo card (https://huggingface.co/docs/hub/model-cards#model-card-metadata)

license: other ---pip install transformers torch torchvision from transformers import T5ForConditionalGeneration, T5Tokenizer import torch import torchvision.transforms as transforms from torchvision.io import write_video model = T5ForConditionalGeneration.from_pretrained("t5-base") tokenizer = T5Tokenizer.from_pretrained("t5-base") device = torch.device("cuda" if torch.cuda.is_available() else "cpu") model = model.to(device) def generate_video_from_text(text): input_ids = tokenizer.encode(text, return_tensors="pt").to(device) output = model.generate(input_ids) video_frames = output[0].cpu().numpy()

# Convert frames to a video
frames = [torch.tensor(frame, dtype=torch.uint8).permute(1, 2, 0) for frame in video_frames]
video = torch.stack(frames)
video = video.permute(0, 3, 1, 2)  # (T, C, H, W)

return video
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model is not currently available via any of the supported Inference Providers.
The model cannot be deployed to the HF Inference API: The model has no library tag.