Replace cPickle with tables, add exec init_data.py, move some code to misc.py