Skip to content

Instantly share code, notes, and snippets.

View hermionewy's full-sized avatar

Yan Wu hermionewy

View GitHub Profile
@tylermorganwall
tylermorganwall / helicopter.R
Created September 30, 2022 21:03
Recreating Wapo Judiciary Square Helicopter Dataviz
#Load all the libraries needed
library(sf)
library(dplyr)
library(rayrender)
library(elevatr)
library(rayshader)
library(geojsonsf)
library(raster)
#To recreate the wapo visualization, we need to visualize a few things in 3D: the buildings,
@andrewbtran
andrewbtran / wpdatateam-ridge
Last active March 2, 2023 17:06
wpdatateam logo generator
# code from https://github.com/gkaramanis/aRtist/blob/main/genuary/2021/2021-3/2021-3.R
library(ggplot2)
library(dplyr)
library(magick)
library(ggridges)
# Read in image and convert to grayscale
img <- image_read(here::here("MRlWzfMH_400x400.jpg")) %>%
image_convert(colorspace = "gray")
@tykurtz
tykurtz / grokking_to_leetcode.md
Last active November 16, 2024 05:08
Grokking the coding interview equivalent leetcode problems

GROKKING NOTES

I liked the way Grokking the coding interview organized problems into learnable patterns. However, the course is expensive and the majority of the time the problems are copy-pasted from leetcode. As the explanations on leetcode are usually just as good, the course really boils down to being a glorified curated list of leetcode problems.

So below I made a list of leetcode problems that are as close to grokking problems as possible.

Pattern: Sliding Window

@earthboundkid
earthboundkid / git gud.md
Last active May 20, 2024 16:42
Git Standards

Git standards Creative Commons License

Git is the democracy of programming: it is the worst tool for version control, except all those other tools that have been tried from time to time. Among other problems, Git’s command names are obtuse (what is a “rebase”?) and non-orthogonal (how is “resetting” different than “checking out”?), and Git generally impedes the creation of an accurate mental model, but without understanding its underlying directed acyclic graph, one can’t move from beginner to intermediate user. Still, it is a necessary tool in every developer’s toolbox, and following good Git practices leads to smoother, more productive development. This guide assumes you already know how to use Git and discusses some of the higher level issues around standards for collaboration.

 

[

@dmnsgn
dmnsgn / WebGL-WebGPU-frameworks-libraries.md
Last active November 17, 2024 08:50
A collection of WebGL and WebGPU frameworks and libraries

A non-exhaustive list of WebGL and WebGPU frameworks and libraries. It is mostly for learning purposes as some of the libraries listed are wip/outdated/not maintained anymore.

Engines and libraries ⚙️

Name Stars Last Commit Description
three.js ![GitHub
@protrolium
protrolium / ffmpeg.md
Last active November 12, 2024 21:27
ffmpeg guide

ffmpeg

Converting Audio into Different Formats / Sample Rates

Minimal example: transcode from MP3 to WMA:
ffmpeg -i input.mp3 output.wma

You can get the list of supported formats with:
ffmpeg -formats

You can get the list of installed codecs with:

@cletusw
cletusw / .eslintrc
Last active February 29, 2024 20:24
ESLint Reset - A starter .eslintrc file that resets all rules to off and includes a description of what each rule does. From here, enable the rules that you care about by changing the 0 to a 1 or 2. 1 means warning (will not affect exit code) and 2 means error (will affect exit code).
{
// http://eslint.org/docs/rules/
"ecmaFeatures": {
"binaryLiterals": false, // enable binary literals
"blockBindings": false, // enable let and const (aka block bindings)
"defaultParams": false, // enable default function parameters
"forOf": false, // enable for-of loops
"generators": false, // enable generators
"objectLiteralComputedProperties": false, // enable computed object literal property names
@cferdinandi
cferdinandi / terminal-cheat-sheet.txt
Last active November 6, 2024 09:24
Terminal Cheat Sheet
# Terminal Cheat Sheet
pwd # print working directory
ls # list files in directory
cd # change directory
~ # home directory
.. # up one directory
- # previous working directory
help # get help
-h # get help
@terrywbrady
terrywbrady / GoogleSpreadsheet.html
Last active July 19, 2024 10:46
Sample HTML/JS to parse a Google Spreadsheet
<!doctype html>
<html>
<head>
<script src="//ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script type="text/javascript">
var spData = null;
function doData(json) {
spData = json.feed.entry;
}
@edankwan
edankwan / snoise2d.js
Created April 6, 2014 06:42
2d snoise Javascript post
// port from GLSL code base on https://github.com/ashima/webgl-noise/blob/master/src/noise2D.glsl
//JS SNOISE PORT
function snoise2d(x, y) {
var C0 = 0.211324865405187;
var C1 = -0.577350269189626;
var C2 = 1.79284291400159;
var OVER_289 = 1 / 289;