This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bb | |
(ns aliases | |
(:require [clojure.edn :as edn] | |
[clojure.tools.cli :refer [parse-opts]] | |
[clojure.string :as str])) | |
(defn show-aliases [{:keys [in-string]}] | |
(let [filter-list (if in-string | |
(partial filter (fn [[kw body]] | |
(str/includes? (str kw) in-string))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "segnet" | |
layer { | |
name: "data" | |
type: "DenseImageData" | |
top: "data" | |
top: "label" | |
dense_image_data_param { | |
source: "/SegNet/CamVid/train.txt" # Change this to the absolute path to your data file | |
batch_size: 4 # Change this number to a batch size that will fit on your GPU | |
shuffle: true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
iex ((new-object net.webclient).DownloadString('https://chocolatey.org/install.ps1')) | |
choco install ruby vagrant virtualbox | |
gem update --clear-sources --source http://rubygems.org/ --system | |
gem install xnlogic |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
### Keybase proof | |
I hereby claim: | |
* I am pangloss on github. | |
* I am pangloss (https://keybase.io/pangloss) on keybase. | |
* I have a public key whose fingerprint is CF64 AF42 70F8 2951 1E26 DB6E 4E6A D7F7 35D6 AF65 | |
To claim this, I am signing this object: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns js-to-clj-bench.core) | |
; Run this benchmark at: http://jsperf.com/js-clj-transducer-test | |
(let [data | |
"[{ \"web-app\": { \"servlet\": [ { \"servlet-name\": \"cofaxCDS\", \"servlet-class\": \"org.cofax.cds.CDSServlet\", \"init-param\": { \"configGlossary:installationAt\": \"Philadelphia, PA\", \"configGlossary:adminEmail\": \"[email protected]\", \"configGlossary:poweredBy\": \"Cofax\", \"configGlossary:poweredByIcon\": \"/images/cofax.gif\", \"configGlossary:staticPath\": \"/content/static\", \"templateProcessorClass\": \"org.cofax.WysiwygTemplate\", \"templateLoaderClass\": \"org.cofax.FilesTemplateLoader\", \"templatePath\": \"templates\" } }, { \"servlet-name\": \"cofaxAdmin\", \"servlet-class\": \"org.cofax.cds.AdminServlet\" }, { \"servlet-name\": \"cofaxTools\", \"servlet-class\": \"org.cofax.cms.CofaxToolsServlet\", \"init-param\": { \"templatePath\": \"toolstemplates/\", \"log\": 1, \"logLocation\": \"/usr/local/tomcat/logs/CofaxTools.log\", \"logMaxSize\": \"\", \"dataLog\": 1, \"dataLogLocation |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:dependencies [[org.clojure/clojure "1.6.0"] | |
[org.clojure/clojurescript "0.0-2311"] | |
[org.clojure/core.async "0.1.338.0-5c5012-alpha"] | |
[figwheel "0.1.3-SNAPSHOT" :exclusions [org.clojure/core.async]]] | |
:plugins [[lein-figwheel "0.1.3-SNAPSHOT" :exclusions [org.clojure/core.async]] | |
[org.clojure/core.async "0.1.338.0-5c5012-alpha"] | |
[lein-cljsbuild "1.0.3"] | |
[com.cemerick/clojurescript.test "0.3.1"] ] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(ns async | |
(:require cljs.core.match | |
[cljs.core.async.impl.protocols :as impl] | |
[cljs.core.async.impl.channels :as channels])) | |
(defn delay-chan* | |
"chan-thunk is something that when deref'd returns a channel. The | |
first thing that that channel emits will be saved and always returned | |
by the channel this produces." | |
[chan-thunk] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The expected result: | |
>> show(search.simple_router.route("/model/tweet/rel/responses")) | |
{:type :model, :model [tweet], :child {:type :rel, :rel responses}} | |
The actual result: | |
>> show(search.logic_router.routes(1, "/model/tweet/rel/responses")) | |
({:type :model, :model <lvar:value_238>, :child <lvar:child_241>}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defn partition-chan | |
([start-pred in] (partition-chan start-pred (complement start-pred) in)) | |
([start-pred end-pred in] | |
(let [out (chan)] | |
(go | |
(loop [] | |
(if-let [val (<! in)] | |
(if (start-pred val) | |
(let [next-chan (chan)] | |
(>! out next-chan) |
NewerOlder