Function sequant::opt::detail::flops_counter¶
Defined in File single_term.hpp
Function Documentation¶
-
auto sequant::opt::detail::flops_counter(has_index_extent auto &&ixex)¶
Cost function returning the flop count of a binary tensor contraction.
The returned callable computes the product of extents over the union of indices on
lhs,rhs, andresult. A product of 1 (scalar contraction) is reported as zero flops.- Parameters:
ixex – Invocable mapping an Index to its extent.
- Returns:
A callable
(lhs, rhs, result) -> doubleyielding the flop count of the contraction.