Template Class table_simplifier

Class Documentation

template<typename TableCollectionType>
class fwdpp::ts::table_simplifier

Implements the simplification algorithm of Kelleher2018-fu.

Keeping a persistent simplifier around during a simplification avoids many repeated large memory allocations. On a single-core machine, the more often you simplify, the more this matters. When running many simulations on a many-core machine, keeping a persistent object reduces competition between threads for big memory chunks, which should also lead to a performance boost.

Many of the implementation details are private functions, which are subject to change without notice.

Version

0.7.0 Added to fwdpp.

Version

0.8.0 Added ancestry_list, which greatly reduces memory overhead.

Version

0.8.0 Remove need for temporary output edge table.

Version

0.9.0 Added typename TableCollectionType and refactored as a wrapper around standalone functions.

Public Functions

table_simplifier()
std::pair<std::vector<table_index_t>, std::vector<std::size_t>> simplify(TableCollectionType &tables, const std::vector<table_index_t> &samples)

Simplify algorithm is approximately the same logic as used in msprime 0.6.0

Version

0.7.1 Throw exception if a sample is recorded twice

Version

0.7.3 Return value is now a pair containing the node ID map and a vector of keys to mutations preserved in mutation tables

Parameters