Skip to content

Instantly share code, notes, and snippets.

@juanmc2005
juanmc2005 / diart_whisper.py
Last active April 27, 2024 02:15
Code for my tutorial "Color Your Captions: Streamlining Live Transcriptions with Diart and OpenAI's Whisper". Available at https://medium.com/@juanmc2005/color-your-captions-streamlining-live-transcriptions-with-diart-and-openais-whisper-6203350234ef
import logging
import os
import sys
import traceback
from contextlib import contextmanager
import diart.operators as dops
import numpy as np
import rich
import rx.operators as ops
@b0gdanw
b0gdanw / ESD to ISO on macOS.txt
Last active April 27, 2024 02:13
Converting ESD files to ISO images on macOS
ESD to ISO on macOS
https://gist.github.com/b0gdanw/e36ea84828dbd19e03eff6158f1fc77c
Converting ESD files to ISO images on macOS
- download Parallels Desktop 18 for Mac Image from https://www.parallels.com/products/desktop/download/
- at the moment https://download.parallels.com/desktop/v18/18.2.0-53488/ParallelsDesktop-18.2.0-53488.dmg
- open/mount the dmg
- copy prl_esd2iso and libwimlib.1.dylib from /Volumes/Parallels\ Desktop\ 18/Parallels\ Desktop.app/Contents/ to /usr/local/bin/ and /usr/local/lib/
sudo ditto /Volumes/Parallels\ Desktop\ 18/Parallels\ Desktop.app/Contents/MacOS/prl_esd2iso /usr/local/bin/prl_esd2iso
@rudSarkar
rudSarkar / xss-image.svg
Created August 12, 2019 18:28
SVG Image XSS File
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@palkan
palkan / factory_doctor.rb
Created March 27, 2017 15:42
FactoryDoc: detect useless data generation in tests
module FactoryGirl
module Doctor
module FloatDuration
refine Float do
def duration
t = self
format("%02d:%02d.%03d", t / 60, t % 60, t.modulo(1) * 1000)
end
end
end
@palkan
palkan / Gemfile
Last active April 27, 2024 02:02
FactoryProf: profiler for your FactoryGirl
# if you want to render flamegraphs
gem "stackprof", require: false # required by flamegraph
gem "flamegraph", require: false
@aamiaa
aamiaa / CompleteDiscordQuest.md
Last active April 27, 2024 02:11
Complete Recent Discord Quest

Complete Recent Discord Quest

Note

This no longer works in browser!

Note

This no longer works if you're alone in vc! Somebody else has to join you!

How to use this script:

  1. Accept the quest under User Settings -> Gift Inventory
def get_all_cookies():
'''
WARNING: We use unsupported features of Streamlit
However, this is quite fast and works well with
the latest version of Streamlit (1.27)
RETURNS:
Returns the cookies as a dictionary of kv pairs
'''
from streamlit.web.server.websocket_headers import _get_websocket_headers
# https://github.com/streamlit/streamlit/pull/5457
@DomPizzie
DomPizzie / README-Template.md
Last active April 27, 2024 01:50
A simple README.md template

Project Title

Simple overview of use/purpose.

Description

An in-depth paragraph about your project and overview of use.

Getting Started