Skip to content

Instantly share code, notes, and snippets.

View metacritical's full-sized avatar
Creating Black holes.

Pankaj Doharey metacritical

Creating Black holes.
View GitHub Profile
@angusiguess
angusiguess / biblio.md
Last active May 6, 2023 21:52
Emulators, Immutability, and Time Travel
@bzamecnik
bzamecnik / simples_lstm_softmax_classifier_keras.py
Created December 24, 2016 07:11
Simplest sequence classifier with LSTM & softmax in Keras
"""
Classifies sequences of length 10 with 20 features into 2 classes
with a single LSTM layer with 32 neurons.
See also a more involved example:
https://gist.github.com/bzamecnik/dccc1c4fdcf1c7a31757168b19c827a7
"""
from keras.layers import Input, LSTM, Dense
@bzamecnik
bzamecnik / lstm_with_softmax_keras.py
Created December 24, 2016 07:04
LSTM with softmax activation in Keras
"""
When classifying upon a sequence usually we stack some LSTM returning sequences,
then one LSTM returning a point, then Dense with softmax activation.
Is it possible instead to give the last non-sequential LSTM a softmax activation?
The answer is yes.
In this example we have 3 sequential layers and one layer producing the final result.
@tilarids
tilarids / tiny_hello.asm
Created September 23, 2016 00:49
A minimal Mach-o x32 executable for OS X El Capitan (with proper padding and symtable)
; A minimal Mach-o x32 executable for OS X El Capitan (with proper padding and symtable)
;
; Original (pre 10.10.5) version - https://gist.github.com/softboysxp/1084476
; $ nasm -O0 -f bin -o tiny_hello tiny_hello.asm
; $ chmod +x tiny_hello
; $ ./tiny_hello
; (returns 42)
; $
; c.f.
@vkravets
vkravets / README.md
Created September 14, 2016 13:15 — forked from pthrasher/README.md
Mac OS X - Wallpaper Changer - Swift

Mac OS X - Wallpaper Changer

Swift code to change the Wallpaper for all screens. Currently, it changes only the current spaces' wallpaper. I'm working on a version to change in all spaces.

Usage: WallpaperChanger "/Users/username/SomeFolder/SomePicture.jpg"

@cszentkiralyi
cszentkiralyi / .spacemacs
Last active February 15, 2023 16:12
Spacemacs config
;; -*- mode: emacs-lisp -*-
;; This file is loaded by Spacemacs at startup.
;; It must be stored in your home directory.
(defun dotspacemacs/layers ()
"Configuration Layers declaration.
You should not put any user code in this function besides modifying the variable
values."
(setq-default
;; Base distribution to use. This is a layer contained in the directory
@hajimes
hajimes / logsumexp-asm.js
Last active January 29, 2017 02:25
handwritten asm.js code for logsumexp
// MIT License. Copyright (c) 2016 Hajime Senuma.
/**
* asm.js module for logsumexp
*/
function asmModule(stdlib, foreign, heap) {
'use asm';
var exp = stdlib.Math.exp;
var log = stdlib.Math.log;
@nagua
nagua / lgtm.md
Created March 11, 2016 16:37
LGTM Markdown

LGTM

@vasanthk
vasanthk / System Design.md
Last active May 6, 2024 20:21
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@bkaradzic
bkaradzic / orthodoxc++.md
Last active April 23, 2024 13:59
Orthodox C++

Orthodox C++

What is Orthodox C++?

Orthodox C++ (sometimes referred as C+) is minimal subset of C++ that improves C, but avoids all unnecessary things from so called Modern C++. It's exactly opposite of what Modern C++ suppose to be.

Why not Modern C++?