amnh / PCG

𝙋𝙝𝙮𝙡𝙤𝙜𝙚𝙣𝙚𝙩𝙞𝙘 𝘾𝙤𝙢𝙥𝙤𝙣𝙚𝙣𝙩 𝙂𝙧𝙖𝙥𝙝 ⸺ Haskell program and libraries for general phylogenetic graph search
28 stars 1 forks source link

Add "dense" Threeway Median Matrix (TMM) for small alphabets #99

Closed recursion-ninja closed 5 years ago

recursion-ninja commented 5 years ago

We should expand the C FFI to allocate a 3D "TCM" which calculates the cost between any 3 ambiguous alphabet states of size eight or fewer. This should improve the efficiency over the general case with the memoized TCM and might be able to be integrated into the 3D (three sequence) C alignment code.

recursion-ninja commented 5 years ago

This was mostly implemented via the C FFI binding to the C code inherited from POY. I wrote a wrapper on the Haskell side and refactored some of the Haskell FFI code to separate the dense TCM generation and queries from the C DO alignment code.

This has been implemented and integrated into the dynamic character metadata.