Python – how to measure speed

Measuring the speed of scripts.

An example of measuring the speed of work in Python:

import time
start_time = timetime()
user_ids = [ for x in db.session.query(User).distinct()]
print(“-% s seconds -“ % (timetime() – start_time))

Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *