By Austin G. Davis-Richardson
(Use their installation instructions)
<html> | |
<head> | |
<title> | |
[Visualizing Movement Data with D3.js] | |
</title> | |
<script src="https://d3js.org/d3.v4.min.js"></script> | |
<script src="https://omid.al/Mova-Viz/MovaViz-v0.1.2.js"></script> | |
<style> | |
* { | |
box-sizing: border-box |
function toJSON(node) { | |
node = node || this; | |
var obj = { | |
nodeType: node.nodeType | |
}; | |
if (node.tagName) { | |
obj.tagName = node.tagName.toLowerCase(); | |
} else | |
if (node.nodeName) { | |
obj.nodeName = node.nodeName; |
var base64map = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; | |
// Global Crypto object | |
var Crypto = exports.Crypto = {}; | |
// Crypto utilities | |
var util = Crypto.util = { | |
// Bit-wise rotate left | |
rotl: function (n, b) { |
# install dependencies | |
sudo apt-get update | |
sudo apt-get install -y build-essential | |
sudo apt-get install -y cmake | |
sudo apt-get install -y libgtk2.0-dev | |
sudo apt-get install -y pkg-config | |
sudo apt-get install -y python-numpy python-dev | |
sudo apt-get install -y libavcodec-dev libavformat-dev libswscale-dev | |
sudo apt-get install -y libjpeg-dev libpng-dev libtiff-dev libjasper-dev | |
# A Ruby implementation of | |
# the Viterbi algorithm based on the hidden Markov model (HMM) | |
# | |
# An original Python code: a Wikipedia page "Viterbi algorithm" at | |
# http://en.wikipedia.org/wiki/Viterbi_algorithm | |
# | |
# Author: MISHIMA, Hiroyuki | |
# | |
require 'pp' |
By Austin G. Davis-Richardson
(Use their installation instructions)
$(document).ready(function() { | |
$('.gist').each(function(i) { | |
writeCapture.html(this, '<script src="'+$(this).text()+'.js"></script>'); | |
}); | |
}); |
When starting a project that includes refinerycms-blog: | |
$ rake refinery:override view=refinery/pages/* | |
$ rake refinery:override view=layouts/* | |
$ rake refinery:override view=refinery/blog/shared/* | |
$ rake refinery:override view=refinery/blog/posts/* | |
$ rake refinery:override view=refinery/* | |
$ rake refinery:override controller=refinery/blog/* | |
$ rake refinery:override controller=refinery/* |
script(src='/javascripts/jquery-1.7.min.js') | |
link(rel='stylesheet', href='/stylesheets/bootstrap.min.css') | |
link(rel='stylesheet', href='/stylesheets/bootstrap-overrides.css') |
# config/initializers/will_paginate_array.rb | |
require 'will_paginate/collection' | |
Array.class_eval do | |
attr_reader :total_pages | |
def paginate(options = {}) | |
raise ArgumentError, "parameter hash expected (got #{options.inspect})" unless Hash === options | |
WillPaginate::Collection.create( | |
options[:page] || 1, |