Live stream from your PS4 to a local computer running an RTMP server by intercepting the twitch.tv stream.
Requirements
- DD-WRT enabled Router (or router with iptables compatibility)
- nix Envirment
- nginx with the nginx-rtmp-module
"""Exponential moving average for PyTorch. Adapted from | |
https://www.zijianhu.com/post/pytorch/ema/. | |
""" | |
from copy import deepcopy | |
import torch | |
from torch import nn | |
"""Exponential moving average for PyTorch. Adapted from | |
https://www.zijianhu.com/post/pytorch/ema/. | |
""" | |
from copy import deepcopy | |
import torch | |
from torch import nn | |
# My ISP-provided fiber optical modem broadcasts a line of a poem every ten seconds. Here's the tcpdump of the complete poem. | |
# The optical modem is made by Shanghai Nokia-Bell Co.,Ltd and its model number is G-140W-UD. It's provided by my ISP, China Unicom in Shenzhen. | |
$ tcpdump -i vlan10 ether proto 0x8300 | |
15:59:00.720301 00:00:00:00:00:12 (oui Ethernet) > Broadcast, ethertype Unknown (0x8300), length 72: | |
0x0000: 0000 0000 e4ea 8386 d93c 5468 6520 6461 .........<The.da | |
0x0010: 7920 4920 6c6f 7374 206d 7920 7665 7279 y.I.lost.my.very | |
0x0020: 2066 6972 7374 2074 6f6f 7468 2c00 0000 .first.tooth,... | |
0x0030: 0000 0000 0000 0000 0000 .......... | |
15:59:10.740778 00:00:00:00:00:12 (oui Ethernet) > Broadcast, ethertype Unknown (0x8300), length 72: |
from torchvision.transforms.transforms import GaussianBlur | |
import webdataset as wds | |
import io | |
from PIL import Image | |
from clip.loader import TextImageDataset | |
from clip.clip import load, tokenize | |
from torchvision import transforms as T | |
from torch.utils.data import DataLoader | |
from torch.optim import Adam | |
import torch.nn.functional as F |
# WARNING : This gist in the current form is a collection of command examples. Please exercise caution where mentioned. | |
# Docker | |
sudo apt-get update | |
sudo apt-get remove docker docker-engine docker.io | |
sudo apt install docker.io | |
sudo systemctl start docker | |
sudo systemctl enable docker | |
docker --version |