Skip to content

Instantly share code, notes, and snippets.

View ROBERT-MCDOWELL's full-sized avatar

ROBERT MCDOWELL ROBERT-MCDOWELL

View GitHub Profile
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / CONDA_SETUP.md
Created October 18, 2025 02:52 — forked from lmmx/CONDA_SETUP.md
Installing faster-whisper with GPU support via CTranslate2 (dependencies: CUDA>=11.2 CuDNN 8.x and CuBLAS)
conda create -n fasterwhisper python
conda activate fasterwhisper
conda install pytorch torchvision torchaudio pytorch-cuda=11.7 -c pytorch -c nvidia
conda install "cudnn>8" -c conda-forge

Then install CTranslate2 into ~/opt:

I needed libiomp5 and couldn't get it to find the Intel MKL include directory (by setting MKLROOT)

@ROBERT-MCDOWELL
ROBERT-MCDOWELL / runner.py
Created October 11, 2025 01:51 — forked from devdave/runner.py
non-blocking python subprocess
import subprocess
import threading
import queue
import os
import time
class Runner(object):
def __init__(self, cmd: []):
self.cmd = cmd
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / apache-peertube-for-7.x.conf
Last active May 30, 2025 11:20
Unofficial support of the last and updated httpd/Apache vhost to run PeerTube >= 7.x ONLY
# PeerTube Apache configuration version 25.4.25 (for PeerTube version >= 7+ only)
SSLSessionCache "shmcb:/usr/local/apache/logs/ssl_gcache_data(512000)"
SSLSessionCacheTimeout 87400
SSLStaplingCache shmcb:logs/stapling-cache(150000)
# Please check your Apache installation features the following modules via 'apachectl -M':
# STANDARD HTTP MODULES: core_module, proxy_module, proxy_http2_module, proxy_wstunnel_module, proxy_http_module, headers_module, remoteip_module, ssl_module, filter_module, reqtimeout_module
# THIRD PARTY MODULES: None.
# check https://ssl-config.mozilla.org/#server=apache&version=2.4.41&config=modern&openssl=1.1.1d&hsts=false&ocsp=false&guideline=5.6 for hardening security
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / webgl.js
Created December 16, 2023 12:39 — forked from x-labz/webgl.js
WebGL initialization
var glRef = {};
function loadImage(src) {
return new Promise((resolve, reject) => {
const img = new Image();
img.onload = () => {
resolve(img);
};
img.src = src;
});
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / apache-peertube-for-v6.x.conf
Last active March 8, 2025 12:45
Unofficial support of the last and updated httpd/Apache vhost to run PeerTube >= 6.x ONLY
# PeerTube Apache configuration version 24.6.29 (for PeerTube version >= 6+ only)
SSLSessionCache "shmcb:/usr/local/apache/logs/ssl_gcache_data(512000)"
SSLSessionCacheTimeout 87400
SSLStaplingCache shmcb:logs/stapling-cache(150000)
# Please check your Apache installation features the following modules via 'apachectl -M':
# STANDARD HTTP MODULES: core_module, proxy_module, proxy_http2_module, proxy_wstunnel_module, proxy_http_module, headers_module, remoteip_module, ssl_module, filter_module, reqtimeout_module
# THIRD PARTY MODULES: None.
# check https://ssl-config.mozilla.org/#server=apache&version=2.4.41&config=modern&openssl=1.1.1d&hsts=false&ocsp=false&guideline=5.6 for hardening security
const W = 640; // video frame width
const H = 360; // video frame height
const pixelData = await imageLoader("./seaside.png"); // get the pixel data of the backgroung image in RGBA format
const buffer = new Uint8Array(W * H * 1.5); // byte buffer for the incoming frame in YUV 422 format
const bufferRGB = new Uint8Array(W * H * 4); // byte buffer for the result frame in RGBA format
const transformer = new TransformStream({
async transform(videoFrame, controller) {
const copyResult = await videoFrame.copyTo(buffer);
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / yuv_canvas
Created August 25, 2023 21:33 — forked from Teaonly/yuv_canvas
Draw YUV in a HTML5's Canvas
function yuv2canvas(yuv, width, height, canvas) {
/*
canvas.width = width;
canvas.height = height;
*/
context = canvas.getContext("2d");
output = context.createImageData(width, height);
outputData = output.data;
yOffset = 0;
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / convert.js
Created August 25, 2023 02:18 — forked from ryohey/convert.js
Convert YUV420(I420) Progressive Planar to RGB in JavaScript
const WIDTH = 176
const HEIGHT = 144
const progRGB = yuv420ProgPlanarToRgb(base64ToArrayBuffer(yuv420ProgPlanarImage()), WIDTH, HEIGHT)
const canvas = document.createElement("canvas")
document.body.appendChild(canvas)
const ctx = canvas.getContext("2d")
const imageData = ctx.createImageData(WIDTH, HEIGHT)
putRGBToRGBA(imageData.data, progRGB, WIDTH, HEIGHT)
ctx.putImageData(imageData, 0, 0)
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / apache-peertube-for-v5.conf
Last active June 29, 2024 15:30 — forked from rigelk/peertube.conf
Unofficial support of the last and updated httpd/Apache vhost to run PeerTube 5.x ONLY
# PeerTube Apache configuration version 24.6.29 (for PeerTube version 5.x only)
SSLSessionCache "shmcb:/usr/local/apache/logs/ssl_gcache_data(512000)"
SSLSessionCacheTimeout 87400
SSLStaplingCache shmcb:logs/stapling-cache(150000)
# Please check your Apache installation features the following modules via 'apachectl -M':
# STANDARD HTTP MODULES: core_module, proxy_module, proxy_http2_module, proxy_wstunnel_module, proxy_http_module, headers_module, remoteip_module, ssl_module, filter_module, reqtimeout_module
# THIRD PARTY MODULES: None.
# check https://ssl-config.mozilla.org/#server=apache&version=2.4.41&config=modern&openssl=1.1.1d&hsts=false&ocsp=false&guideline=5.6 for hardening security
@ROBERT-MCDOWELL
ROBERT-MCDOWELL / udp.js
Created July 19, 2022 13:55 — forked from sid24rane/udp.js
Simple UDP Client and Server in Node.js ==> ( Echo Server )
var udp = require('dgram');
// --------------------creating a udp server --------------------
// creating a udp server
var server = udp.createSocket('udp4');
// emits when any error occurs
server.on('error',function(error){
console.log('Error: ' + error);