Skip to content

Instantly share code, notes, and snippets.

View wjt's full-sized avatar

Will Thompson wjt

View GitHub Profile
@hwayne
hwayne / explanation.md
Last active April 9, 2024 21:37
Sudoku DIMACS format

How the J Script Works

Going line by line:

b =: >: i. 9 9 9

This generates a 9 by 9 by 9 array with all values from 1 to 729. We can choose what each axis represents: I decided that each table is all of the boolean variables for one number, and the rows and columns map to sudoku rows and columns. For example:

@gboudreau
gboudreau / AuthyToOtherAuthenticator.md
Last active February 28, 2025 23:46 — forked from Ingramz/AuthyToOtherAuthenticator.md
Export TOTP tokens from Authy

Exporting your 2FA tokens from Authy to transfer them into another 2FA application

IMPORTANT - Update regarding deprecation of Authy desktop apps

Past August 2024, Authy stopped supported the desktop version of their apps:
See Authy is shutting down its desktop app | The 2FA app Authy will only be available on Android and iOS starting in August for details.

And indeed, after a while, Authy changed something in their backend which now prevents the old desktop app from logging in. If you are already logged in, then you are in luck, and you can follow the instructions below to export your tokens.

If you are not logged in anymore, but can find a backup of the necessary files, then restore those files, and re-install Authy 2.2.3 following the instructions below, and it should work as expected.

@aparrish
aparrish / understanding-word-vectors.ipynb
Last active February 20, 2025 02:47
Understanding word vectors: A tutorial for "Reading and Writing Electronic Text," a class I teach at ITP. (Python 2.7) Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@aparrish
aparrish / spacy_intro.ipynb
Last active July 29, 2024 21:03
NLP Concepts with spaCy. Code examples released under CC0 https://creativecommons.org/choose/zero/, other text released under CC BY 4.0 https://creativecommons.org/licenses/by/4.0/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@dill
dill / all_the_single_palettes.txt
Last active November 11, 2015 16:21
👑🐝 All the single palettes 👑🐝 (one line per palette)
#273649 #647184 #B1B2C8 #A7755D #5D2E1C #38201C
#0F2B5F #5991C7 #8EC1E7 #B9DBF1 #D5A370 #7B4F37
#5A7362 #6B867C #A1A897 #9A8D6B #8E6341 #432B21
#1F150D #2B190C #513B2C #9B4D44 #893D37 #3E1B17
#9C8A45 #CABE85 #678B88 #9CADAF #CCCCCC #EFEFEF
#1C3333 #226060 #639CA4 #D2AD7C #BE7245 #46211C
#0D1723 #112040 #204D88 #96ABC6 #D1DDE2 #EFEFEF
#000000 #350E16 #5E1521 #A72C29 #C44221 #EC702E
#A56B47 #C79982 #0D8EDA #23ADED #6BC6F5 #EFEFEF
#2A2432 #4F3855 #846D86 #EFEFCF #D5B77D #A89E5E
@remy
remy / audiosprite.js
Created December 23, 2010 13:54
An example of how an audio sprite can be used (includes fixes for iOS)
function Track(src, spriteLength, audioLead) {
var track = this,
audio = document.createElement('audio');
audio.src = src;
audio.autobuffer = true;
audio.load();
audio.muted = true; // makes no difference on iOS :(
/* This is the magic. Since we can't preload, and loading requires a user's
input. So we bind a touch event to the body, and fingers crossed, the