replicate/replicate-python

Return cost in minutes of inference

Closed this issue · 5 comments

Users have a finite number of minutes of inference per-month.

It would be useful to see how many compute minutes Replicate has charged for a given inference once it has completed.

This could be useful for allocating time to a given user, or simply profiling.

I've been looking at the code, and am not seeing anything that does this. However it seems like something that could be a member of the Prediction class.

I think is a great idea

I strongly agree it a good idea. I really need it.

any updates on this?

mattt commented

As of #136, you can now get the predict time in seconds through the metrics field of a prediction.

prediction.metrics['predict_time']

This is available in version 0.11.0.