Skip to content

Instantly share code, notes, and snippets.

View knmurphy's full-sized avatar
🏴

Kevin N. Murphy knmurphy

🏴
View GitHub Profile
@statik
statik / h2rnotify.py
Last active July 17, 2023 15:26
apprise custom notifications for h2r experiments
#!/usr/bin/env python3
# include the decorator
from apprise.decorators import notify
from apprise.logger import logger
import requests
import re
import json
import sys
@veekaybee
veekaybee / searchrecs.md
Last active February 3, 2025 14:37
Understanding search and recommendations

How are search and recommendations the same, and how are they different?

TL;DR:

  • The design of both search and recommendations is to find and filter information
  • Search is a "recommendation with a null query"
  • Search is "I want this", recommendations is "you might like this"
@statik
statik / install_ffmpeg.sh
Last active December 18, 2020 22:45 — forked from Piasy/install_ffmpeg.sh
brew install ffmpeg with all options
brew uninstall --force --ignore-dependencies ffmpeg
brew install --ignore-dependencies chromaprint
brew install amiaopensource/amiaos/decklinksdk
brew cask install xquartz
options=$(brew options homebrew-ffmpeg/ffmpeg/ffmpeg | grep -vE '\s' | grep -- '--with-' | grep -vi game-music-emu | tr '\n' ' ')
brew install homebrew-ffmpeg/ffmpeg/ffmpeg ${options}
@drewm
drewm / shoot-sharing-image.js
Last active December 13, 2024 16:56
Dynamic Social Sharing Images
const puppeteer = require('puppeteer');
const imagemin = require('imagemin');
const imageminPngquant = require('imagemin-pngquant');
// Get the URL and the slug segment from it
const url = process.argv[2];
const segments = url.split('/');
const slug = segments[segments.length-2];
(async () => {
I was able to find a VERY QUICK AND DIRTY way to use the media-autobuild suite to compile my own 64-bit static FFmpeg for Windows with the NDI library.
Download it and extract to a place on your computer, and keep note of the path. I put it in "D:\ndi\media-autobuild_suite-master", so for the sake of these instructions when you see "<autobuild>", you need to substitute whatever path you've put it in.
During the initial setup process, request to use the static build and add whatever else you'd like to have in your ffmpeg, then pause what you're doing when the on-screen prompts tell you the ffmpeg_options file has been written, then go into <autobuild>\build\ffmpeg_options.txt and add somewhere a line with
Code:
--enable-libndi_newtek
@mzupan
mzupan / lambda.py
Last active June 8, 2021 05:19
AWS Lambda job to backup RDS instances
import boto3
import datetime
def lambda_handler(event, context):
print("Connecting to RDS")
client = boto3.client('rds')
print("RDS snapshot backups stated at %s...\n" % datetime.datetime.now())
client.create_db_snapshot(
DBInstanceIdentifier='web-platform-slave',