Skip to main content

CostEstimator

Protocol for records that can estimate their own processing cost. Implement this on your record type and the batcher will call it automatically when no explicit estimated_cost is passed to DynamicBatcher.submit.

Methods


estimate_cost()

@classmethod
def estimate_cost() - > int

Estimates the processing cost of the record. Implement this method on your record type so the batcher can automatically call it when no explicit estimated_cost is passed to DynamicBatcher.submit.

Returns

TypeDescription
intThe estimated processing cost as an integer.