Skip to content

Instantly share code, notes, and snippets.

View shidephen's full-sized avatar
🏖️
Beach

Blur Radius shidephen

🏖️
Beach
  • Bytedance
  • Shenzhen
View GitHub Profile
@signaldust
signaldust / halite.cpp
Created January 15, 2022 17:11
Halite - an analog circuit simulator in ~1k lines of code
#include <vector>
#include <string>
#include <cstdio>
#include <cmath>
// set to 1 to make LU factorization show pivots
#define VERBOSE_LU 0
// gMin for diodes etc..
static const double gMin = 1e-12;
@talaviram
talaviram / add_debug_entitlement.sh
Last active September 13, 2025 21:08
Simple Utility Script for allowing debug of hardened macOS apps.
#! /bin/bash
# Simple Utility Script for allowing debug of hardened macOS apps.
# This is useful mostly for plug-in developer that would like keep developing without turning SIP off.
# Credit for idea goes to (McMartin): https://forum.juce.com/t/apple-gatekeeper-notarised-distributables/29952/57?u=ttg
# Update 2022-03-10: Based on Fabian's feedback, add capability to inject DYLD for sanitizers.
#
# Please note:
# - Modern Logic (on M1s) uses `AUHostingService` which resides within the system thus not patchable and REQUIRES to turn-off SIP.
# - Some hosts uses separate plug-in scanning or sandboxing.
# if that's the case, it's required to patch those (if needed) and attach debugger to them instead.
@kyleneideck
kyleneideck / headphones-detect.c
Created November 19, 2017 12:10
Runs a command when headphones are plugged in to or unplugged from the built-in audio device.
//
// headphones-detect.c
// Kyle Neideck, [email protected]
//
// Compile with:
// clang -framework CoreAudio -framework CoreFoundation -o headphones-detect headphones-detect.c
//
// Runs a command when headphones are plugged in to or unplugged from the
// built-in audio device.
//
#Program to drive Sonic Pi 3 visualiser written in "processing"
#by Robin Newman, September 2017
#see article at https://rbnrpi.wordpress.com
#set up OSC address of processing sketch
use_osc '127.0.0.1',5000
#select shapes to show
osc "/viz/shapes","e" #"s" "e" "r" Star,Ellipse, Rectangle or combination
sleep 0.1
live_loop :c do
@r9y9
r9y9 / Test Tacotoron.ipynb
Created September 14, 2017 15:26
Trying to implement Tacotron in PyTorch.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@r9y9
r9y9 / spectral_param.ipynb
Last active July 23, 2020 10:33
Comparison of spectral envelope parametrization methods (http://nbviewer.jupyter.org/gist/r9y9/ca05349097b2a3926ec77a02e62c6632)
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@myme5261314
myme5261314 / rbm_MNIST_test.py
Last active April 10, 2020 06:59
RBM procedure using tensorflow
import tensorflow as tf
import numpy as np
import input_data
import Image
from util import tile_raster_images
def sample_prob(probs):
return tf.nn.relu(
tf.sign(
@guitarrapc
guitarrapc / Get-ScreenShot.ps1
Last active July 31, 2023 15:21
Screenshot Automation with PowerShell
function Get-ScreenShot
{
[CmdletBinding()]
param(
[parameter(Position = 0, Mandatory = 0, ValueFromPipelinebyPropertyName = 1)]
[ValidateNotNullOrEmpty()]
[string]$OutPath = "$env:USERPROFILE\Documents\ScreenShot",
#screenshot_[yyyyMMdd_HHmmss_ffff].png
[parameter(Position = 1, Mandatory = 0, ValueFromPipelinebyPropertyName = 1)]
@r9y9
r9y9 / mlsa_filter.h
Last active February 15, 2023 11:07
MLSA digital filter for speech synthesis in C++
#pragma once
#include <cmath>
#include <memory>
#include <vector>
#include <cassert>
namespace sp {
/**
@cjgiridhar
cjgiridhar / articles.html
Created July 30, 2012 05:30
Tornado - Static File Handler
<html>
<title>
Articles
</title>
<body>
<h1>Articles page</h1>
<p><img src="images/images.jpg"/></p>
</body>
</html>