Module utils

Source
Expand description

Helper functions with tests for fee calculation, weight computation, and waste metrics

Functionsยง

calculate_accumulated_weight
adjusted_target is the target value plus the estimated fee.
calculate_base_weight_btc
Returns the weights of data in transaction other than the list of inputs that would be selected.
calculate_fee
calculate_waste
effective_value
Returns the effective value of the OutputGroup, which is the actual value minus the estimated fee.