This file contains hidden or 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 python | |
from __future__ import print_function | |
import argparse | |
import hashlib | |
import itertools | |
import os | |
import multiprocessing as mp | |
import sys |
This file contains hidden or 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
# Kalman filtering | |
# Prediction: | |
# x_pre[k] = A*x[k-1] + B*u[k] | |
# P_pre[k] = A*P[k-1]*A' + Q | |
# Measurement update: | |
# K[k] = P_pre[k]*H'*(H*P_pre[k]*H'+R)**(-1) | |
# x[k] = x_pre[k] + K[k]*(z[k]-H*x_pre[k]) | |
# P[k] = (I-K[k]*H)*P_pre[k] | |
# | |
# Simplified with A=H=1, B=0, Q=0: |
This file contains hidden or 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 ruby | |
require 'optparse' | |
require 'zip' | |
require 'fileutils' | |
# parse command line arguments | |
options = {} | |
OptionParser.new do |opt| | |
opt.on('-f FROM_ENC') {|o| options[:from_enc] = o} |
NewerOlder