This is the code as it was used for the results in my Ph.D. Dissertation "Aligned Hierarchies for Sequential Data."  An updated version will be released soon.