Giter VIP home page Giter VIP logo

rtv's Introduction

RTV

Broadcasting the latest and greatest generative AI, direct to your web browser.

Screenshot 2023-02-20 at 21 14 51

RTV takes a series of prompts and feeds them through andreasjansson/tile-morph to create a tiled animation drifting through latent space.

It is broadcast on the Replicate home page. If you want to edit our home page, contribute some prompts!

How to add prompts

Stick 'em in prompts.json.

How to run it

You need to set REPLICATE_API_TOKEN and RTMP_URL in your environment then run node writer.js and node broadcaster.js in separate terminals.

How it works

Two bits:

Writer

Writer generates tiles on Replicate. They are saved as a queue in the directory queue as ordered JSON files.

It will generate tiles in parallel at whatever rate is needed to keep a 5 minute buffer.

Broadcaster

Broadcaster takes tiles in the queue directory and broadcasts them in order to Mux using ffmpeg. When a tile has been successfully broadcast, it gets deleted from the queue.

Deploy

fly deploy

Debugging

If things get stuck, you can SSH into the Fly instance and look at the queue:

$ fly ssh console                                                                                                                                                            !10251
Connecting to fdaa:0:690b:a7b:ad0:4:e415:2... complete
# cd src/queue
# ls -l
total 1661992
-rw-r--r-- 1 root root      3023 Feb 15 23:29 1792.json
-rw-r--r-- 1 root root  73036120 Feb 15 23:29 1792.ts
-rw-r--r-- 1 root root      3019 Feb 15 23:29 1793.json
-rw-r--r-- 1 root root  71689100 Feb 15 23:29 1793.ts
-rw-r--r-- 1 root root      3028 Feb 15 23:30 1794.json
-rw-r--r-- 1 root root  92167940 Feb 15 23:30 1794.ts
...

rtv's People

Contributors

bfirsh avatar erbridge avatar mattt avatar pwntus avatar

Stargazers

BaitPhish avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.