Skip to content

Instantly share code, notes, and snippets.

@seandearnaley
seandearnaley / whispercc.py
Created April 20, 2023 01:55
Whisper.cpp Transcribe Example with Execution Time
"""WhisperCC binding module"""
import time
from pathlib import Path
from whispercpp import Whisper
from app.audio_tools import NdArray, convert_to_float_array, decode_audio
class WhisperTranscriber:
@seandearnaley
seandearnaley / main.py
Created April 20, 2023 01:53
Whisper YouTube Transcriber (GPU)
"""Example of using the Whisper library to detect the language and transcribe."""
import os
import sys
import time
from typing import Optional
import torch
import whisper
from pytube import YouTube
@seandearnaley
seandearnaley / whisper_avg_benchmarks.csv
Created April 20, 2023 01:39
Benchmark Results + Transcriptions for Whisper Transcriptions
We can make this file beautiful and searchable if this error is corrected: Unclosed quoted field in line 2.
Model,"CPU: Macbook M1 Pro (16gb, Nov 2020)","CPU: Mac M2 Pro (Mini 32gb, Jan 2023)","CPU: Windows 11 via Ubuntu 22 (32gb, Oct 2018)","GPU: RTX 2080TI (12gb VRAM, Sep 2018)","GPU: RTX 4090 (24gb, Oct 2022)","GPU: A100 (80GB 16 vCPU 62 GB RAM, Jun 2020)",Transcription
tiny.en,0:00:22.794,0:00:21.477,0:00:45.639,0:00:32.500,0:00:22.748,0:00:18.552,"One of the biggest mysteries of our existence is also one of the biggest mysteries of physics, time. We experienced time as passing with a special moment that we call ""now"". Now you're watching this video. Half an hour ago you were doing something else. Whatever you did, there's no way to change it. And what you will do in half an hour is up to you. At least that's how we perceive time. But what physics tells us about time is very different from our perception. The person who figured this out was none other than Albert Einstein. I know that guy again turns out he kind of knew it all. What did Einstein teach us about the past, the present and the future? That's what
@seandearnaley
seandearnaley / models.csv
Last active September 4, 2023 13:55
Table of LLMs
Model Developer Context Window Size (Tokens) Rough Number of Words
BERT-Large Google 512 128-256
RoBERTa-Large Facebook AI 512 128-256
GPT-2 OpenAI 1024 256-512
GPT-3 OpenAI 2048 512-1024
T5-11B Google 2048 512-1024
LLaMA Meta 2048 512-1024
GPT 3.5 (4k) OpenAI 4096 1024-2048
GPT 3.5 (16k) OpenAI 16384 4096-8192
GPT-4 (8k) OpenAI 8192 2048-4096
@seandearnaley
seandearnaley / JungViz1.yml
Last active May 28, 2022 17:12
Simplified Disco Diffusion YAML for Video Input
# Models
RN101: false
RN50: true
RN50x16: false
RN50x4: false
RN50x64: false
ViTB16: true
ViTB32: true
ViTL14: false
ViTL14_336: false
@seandearnaley
seandearnaley / syntheticAndroid2D-12.yml
Created May 26, 2022 13:53
Simplified Disco Diffusion Template for Human Being - Magma
# Models
RN101: false
RN50: true
RN50x16: false
RN50x4: false
RN50x64: false
ViTB16: true
ViTB32: true
ViTL14: false
ViTL14_336: false
@seandearnaley
seandearnaley / category.model.ts
Created June 8, 2020 15:59
category.model.ts (for Warthog)
import { BaseModel, Model, StringField, ManyToMany } from 'warthog';
import { JoinTable, TreeChildren, TreeParent, Tree } from 'typeorm';
import { Card } from '../card/card.model';
@Model()
@Tree("closure-table")
export class Category extends BaseModel {
@StringField({ nullable: true })
name?: string;
@seandearnaley
seandearnaley / card.model.ts
Created June 8, 2020 15:58
card.model.ts (for Warthog)
import { BaseModel, IntField, Model, StringField, ManyToMany } from 'warthog';
import { Category } from '../category/category.model';
@Model()
export class Card extends BaseModel {
@IntField({ nullable: true })
number?: number;
@StringField({ nullable: true })
label?: string;
@seandearnaley
seandearnaley / Category.ts
Created June 8, 2020 15:56
BrainStrike Category Entity / Model
import {
Entity,
Tree,
Column,
PrimaryGeneratedColumn,
TreeChildren,
TreeParent,
ManyToMany,
JoinTable,
} from "typeorm";
@seandearnaley
seandearnaley / Card.ts
Created June 8, 2020 15:55
BrainStrike Card Entity / Model
import { Entity, PrimaryGeneratedColumn, Column, ManyToMany } from "typeorm";
import { Category } from "./Category";
@Entity()
export class Card {
@PrimaryGeneratedColumn("uuid")
id: string;
@Column()
number: number;