Skip to content

Instantly share code, notes, and snippets.

View sowmenappd's full-sized avatar
Building something great

Sowmen Rahman sowmenappd

Building something great
View GitHub Profile
@Andrey2G
Andrey2G / encoding.txt
Last active May 3, 2024 11:26
Video Encoding with multiple resolutions
ffmpeg -i "c:/videos/sample.mp4
-map 0:v:0 -map 0:a:0 -map 0:v:0 -map 0:a:0 -map 0:v:0 -map 0:a:0
-c:v libx264 -crf 22 -c:a aac -ar 48000
-filter:v:0 scale=w=480:h=360 -maxrate:v:0 600k -b:a:0 64k
-filter:v:1 scale=w=640:h=480 -maxrate:v:1 900k -b:a:1 128k
-filter:v:2 scale=w=1280:h=720 -maxrate:v:2 900k -b:a:2 128k
-var_stream_map "v:0,a:0,name:360p v:1,a:1,name:480p v:2,a:2,name:720p"
-preset slow -hls_list_size 0 -threads 0 -f hls -hls_playlist_type event -hls_time 3
-hls_flags independent_segments -master_pl_name "name-pl.m3u8"
"c:/videos/encoded/name-%v.m3u8"
@amitness
amitness / clickbait.csv
Last active November 18, 2023 00:42
Dataset of clickbait and non-clickbait titles
We can't make this file beautiful and searchable because it's too large.
title,label
"15 Highly Important Questions About Adulthood, Answered By Michael Ian Black",1
250 Nuns Just Cycled All The Way From Kathmandu To New Delhi,1
"Australian comedians ""could have been shot"" during APEC prank",0
Lycos launches screensaver to increase spammers' bills,0
Fußball-Bundesliga 2008–09: Goalkeeper Butt signs with Bayern Munich,0
"In Afghanistan, Soldiers Bridge 2 Stages of War",0
"After Fleeing North Korea, an Artist Parodies Its Propaganda",0
Lessons (or Not) When a Start-Up Misses the Mark,0
Court Issues Order Against 3 Car-Warranty Calling Firms,0
@paulgrieselhuber
paulgrieselhuber / Schema.js
Last active March 22, 2023 04:20
Adding Schema Data to Next.js Sites
import Head from "next/head";
import { site, siteTitle } from "../../config";
function strip(html) {
var one = html.replace(/<\/?[^>]+(>|$)/gm, "");
var two = one.replace(/[\r\n]\s*[\r\n]/gm, "");
return two;
}
const Schema = ({ post }) => {
@mrbar42
mrbar42 / README.md
Last active April 20, 2024 02:57
bash scripts to create VOD HLS stream with ffmpeg almighty (tested on Linux and OS X)

running:

bash create-vod-hls.sh beach.mkv

will produce:

    beach/
      |- playlist.m3u8
 |- 360p.m3u8