diagnostics for OOM
improve log-sum-exp idiom in HMM
debug log-sum-exp initializations