View Brewfile
brew 'ack' | |
brew 'ag' | |
brew 'coreutils' | |
brew 'bash-completion' | |
brew 'openssl' | |
brew 'readline' | |
brew 'ispell' | |
brew 'wget' | |
brew 'tree' | |
brew 'autoenv' |
View bwmorph.py
""" | |
Functions that implement some of the same functionality found in Matlab's bwmorph. | |
`thin` - was taken and adapted from https://gist.github.com/joefutrelle/562f25bbcf20691217b8 | |
`spur` - Not perfect but pretty close to what matlab does via LUTs | |
`endpoints` - lines up perfectly with matlab's output (in my limited testing) | |
`branches` - this results in more clustered pixels than matlab's version but it pretty close | |
""" | |
import numpy as np | |
import scipy.ndimage as ndi |
View prometheus-text004.instaparse
(* see https://github.com/prometheus/docs/blob/master/content/docs/instrumenting/exposition_formats.md#text-format-details *) | |
statements = (type-def | help | metric)* | |
type-def = <"# TYPE "> metric-name <space> type <newline>? | |
type = #"counter|gauge|histogram|summary|untyped" | |
help = <"# HELP "> metric-name <space> docstring <newline>? | |
metric = metric-name labels? <space> value (<space> timestamp)? <newline>? | |
labels = <'{'> label-name label-value {<','> label-name label-value} <','>? <'}'> | |
(* the below doesn't take into account escaping but probably not an issue for our use case *) |
View multiple_return_specs_compojure_api.clj
(require '[spec-tools.core :as st]) | |
(require '[spec-tools.spec :as st.s]) | |
(require '[clojure.spec.alpha :as s]) | |
(s/def ::cheese st.s/string?) | |
(s/def ::stuff st.s/int?) | |
(s/def ::bar (st/spec (s/keys :req-un [::cheese]))) | |
(s/def ::foo (st/spec (s/keys :req-un [::stuff]))) | |
(s/def ::response (s/or :b ::bar :f ::foo)) |
View Brewfile
brew 'ack' | |
brew 'ag' | |
brew 'coreutils' | |
brew 'bash-completion' | |
brew 'openssl' | |
brew 'readline' | |
brew 'ispell' | |
brew 'wget' | |
brew 'tree' | |
brew 'autoenv' |
View joblib_numpy_memoziation_bug.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View Hungarian.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View output.txt
0 | |
1 | |
2 | |
3 | |
4 | |
5 | |
6 | |
7 | |
8 | |
9 |
View Bayesian Update.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View sublist.clj
;; my first version taking advantage of the new shuffle generator introduced in 0.6... | |
(defn sublist1 | |
[coll] | |
(-> (gen/tuple (gen/shuffle coll) (gen/choose 0 (count coll))) | |
(gen/bind (fn [[coll* how-many]] | |
(gen/return (take how-many coll*)))))) | |
;; version inspired by http://roberto-aloi.com/erlang/notes-on-erlang-quickcheck/ | |
;; sublist(L0) -> | |
;; ?LET(L, [{E, eqc_gen:bool()} || E <- L0], [X || {X, true} <- L]). |
NewerOlder