Skip to main content

Multi-Modality

Gen1

My Implementation of " Structure and Content-Guided Video Synthesis with Diffusion Models" by RunwayML. "Input videos x are encoded to z0 with a fixed encoder E and diffused to zt. We extract a structure representation s by encoding depth maps obtained with MiDaS, and a content representation c by encoding one of the frames with CLIP. The model then learns to reverse the diffusion process in the latent space, with the help of s, which gets concatenated to zt, as well as c, which is provided via cross-attention blocks. During inference (right), the structure s of an input video is provided in the same manner. To specify content via text, we convert CLIP text embeddings to image embeddings via a prior."

Install

pip3 install gen1

Usage

import torch
from gen1.model import Gen1

model = Gen1()

images = torch.randn(1, 3, 128, 128)
video = torch.randn(1, 3, 16, 128, 128)

run_out = model.forward(images, video)

Datasets

Here is a summary table of the datasets used in the Structure and Content-Guided Video Synthesis with Diffusion Models paper:

Dataset Type Size Domain Description Source
Internal dataset Images 240M General Uncaptioned images Private
Custom video dataset Videos 6.4M clips General Uncaptioned short video clips Private
DAVIS Videos - General Video object segmentation Link
Stock footage Videos - General Diverse video clips -

Citation

@misc{2302.03011,
Author = {Patrick Esser and Johnathan Chiu and Parmida Atighehchian and Jonathan Granskog and Anastasis Germanidis},
Title = {Structure and Content-Guided Video Synthesis with Diffusion Models},
Year = {2023},
Eprint = {arXiv:2302.03011},

Todo

  • Add training script
  • Add in conditional text paramater to pass in text, not just images and or other videos

Metadata

Release files for gen1 0.0.6

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

Source distribution (sdist)

Source distribution for gen1 0.0.6
File Size Uploaded Provenance Actions
gen1-0.0.6.tar.gz 10.1 kB Without provenance Details for gen1-0.0.6.tar.gz

Built distribution (wheel)

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

Total release size: 19.7 kB

Release files / gen1-0.0.6.tar.gz

Download URL gen1-0.0.6.tar.gz
Size 10.1 kB
Tags Source
SHA-256 checksum
How to use checksums
34107d91d3de9c40429e3ba1531f5bd84059698016067bcf17b97982571bd694
BLAKE2b-256 checksum
How to use checksums
23e142194372df0357dbbe3bc6c2001a462708a34e440cfeb36bb2172c1e18eb
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 / gen1-0.0.6-py3-none-any.whl

Download URL gen1-0.0.6-py3-none-any.whl
Size 9.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5ef1bf96afa2974c44dcad64c29d45b39999977b6075e4d61602a470984d5000
BLAKE2b-256 checksum
How to use checksums
5fdad0ad35a305aab9f62ac4ddc9896086e15db0f90c053714fdd3d55a5ce4c7
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

Security for gen1 0.0.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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