Skip to content

Instantly share code, notes, and snippets.

View gcr's full-sized avatar

Kimmy gcr

  • Google AI
  • 13:54 (UTC -05:00)
View GitHub Profile
@gcr
gcr / TD.org
Created August 26, 2024 14:28
Tao of Descent

Introduction

Welcome!

Intro’s are a bore, but bear with me for just a few moments. On the pages in this site, you can find many points of interest if you play Descent 1, Descent 2, or Descent 3. I am currently a member of the Wildcards Empire, where I serve in several capacities. I am the Flight Training Center Commander and an advisor to the Command Team. This site, more than anything else, is about my role as a lead trainer for the Wildcards. Feel free to start with any link, but if you are a Pyro pilot, I would recommend starting with the bookmark labeled Tao.

What is Tao? Many Eastern philosophers have ruminated on this for hundreds of years. I wouldn’t presume to second guess their many opinions and observations. I am only seeking to apply their basic philosophy to playing games online, against human opponents. Keep in mind as you browse this site that while I am not a philosopher or even one of the best pilots, there is something here that you may learn from my experiences.

If you have fun here,

Recovering corrupt files from a failing Raspberry Pi SD card

Yesterday night, my RasPi wouldn’t boot (black screen). It’s an SD card issue: macOS reports I/O timeouts, so something’s clearly going wrong.

Rescue what parts of the filesystem we can

First, we can use ddrescue to gather all of the blocks:

sudo ddrescue -vv -n /dev/rdisk4 sd-card.img sd-card.img.ddrescue-map-2

The default configuration is to read 128 sectors of 512 bytes each per read() call, ad if any fail, to skip 128 sectors (64kb) ahead. This takes all night because each time reads something from a failing part of the card, MacOS takes 30 sec to I/O timeout, and I think this can’t be configured.

THE NORTH STAR

FREDERICK DOUGLASS, M. R. DELANY, Editors

RIGHT IS OF NO SEX - TRUTH IS OF NO COLOR - GOD IS THE FATHER OF US ALL, AND ALL WE ARE BRETHEREN

WILLIAM C. NEIL, Publisher JOHN DICK, Printer


# 🌟 #
jq\
-rn '"ggEDC
grrggEDCarraaFEDbrrr
GGFDErrrEEErEEErEGCDE"|gsub
("\\s";"")|explode|.[]as$note
|"rg.a.bC
.D.EF.G.A.BC"|gsub
("\\s";"")|explode|index
@gcr
gcr / donut.jq.md
Last active April 12, 2024 14:08

donut.c, but it's in jq

Run this in your terminal:

                  jq -nr 'def R(A;B;C
            ):range(A;B;C);def R(A):range
          (A);30as$s|1as$R1|2as$R2|7as$K2|(
        $s*$K2*3/(8*($R1+$R2)))as$K1|def t($A;$B
     ):($A|cos)as$cA|($B|cos)as$cB|($A|sin)as$sA|($B
pico-8 cartridge // http://www.pico-8.com
version 29
__lua__
-- kimmys-treasure-hunt-galaxy.p8
points={
0xfffe.ddfa,0x0009.d8e2,0xfffe.ace5,0x0001.0000,
0x0006.b93d,0xfffa.ab8c,0xfffa.dcf1,0x0001.0000,
0xfffa.5019,0x0007.7bd4,0x0003.69e8,0x0001.0000,
0xfffa.ca0e,0x0007.1a5f,0xfffb.4463,0x0001.0000,
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@gcr
gcr / rapid-image-viewer.rkt
Last active May 25, 2017 15:35
Tool for showing images
#lang racket
;;
;; Displays a directory full of images in rapid succession.
;; Handy for checking annotations or finding irregularities
;; in large-scale datasets.
;;
;; Usage:
;; - racket rapid-image-viewer.rkt [imglist]
;; Will show all of the '*.jpg' files given as lines in `imglist`,