<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Execution time- Arcpy in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590525#M46295</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;practice&amp;nbsp; with your stop watch before you use the time function&lt;/P&gt;&lt;P&gt;copy and paste these in an interactive editor session&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; import datetime
&amp;gt;&amp;gt;&amp;gt; now = datetime.datetime.now()&amp;nbsp; # wait a bit, then paste the next line
&amp;gt;&amp;gt;&amp;gt; later = datetime.datetime.now()
&amp;gt;&amp;gt;&amp;gt; # ... your code stuff here or nothing ...
&amp;gt;&amp;gt;&amp;gt; elapsed = later - now
&amp;gt;&amp;gt;&amp;gt; print elapsed
0:00:04.416000
&amp;gt;&amp;gt;&amp;gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 12 Dec 2021 01:21:46 GMT</pubDate>
    <dc:creator>DanPatterson_Retired</dc:creator>
    <dc:date>2021-12-12T01:21:46Z</dc:date>
    <item>
      <title>Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590524#M46294</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello everyone,&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; background-color: rgba(248, 248, 248, 0.6);"&gt;I am working on arcmap 10.3.1&amp;nbsp; and python 2.7.8.&amp;nbsp; I need to determine how much time arcpy needed to finish a specific task (add layer) . I'm using this code:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import arcpy,os,sys,string,datetime,timeit
import arcpy.mapping
from arcpy import env

env.workspace = r"C:\Project"
Layer1 = arcpy.mapping.Layer(r"C:\Project\layers\atikot.lyr")
counter = 0
for mxd in arcpy.ListFiles("*.mxd"):
&amp;nbsp;&amp;nbsp;&amp;nbsp; print (mxd)
&amp;nbsp;&amp;nbsp;&amp;nbsp; mapdoc = arcpy.mapping.MapDocument(r"C:\Project\\" + mxd)
&amp;nbsp;&amp;nbsp;&amp;nbsp; df = arcpy.mapping.ListDataFrames(mapdoc, "Layers")[0]&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.mapping.AddLayer(df ,Layer1, "TOP")
&amp;nbsp;&amp;nbsp;&amp;nbsp; print ('AddLayer')
&amp;nbsp;&amp;nbsp;&amp;nbsp; mapdoc.save()
&amp;nbsp;&amp;nbsp;&amp;nbsp; counter = counter + 1
del mxd 
print (counter)
print str(datetime.datetime.now().date())
print time.clock()&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When i run it i get:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; 
Project 2.mxd
AddLayer
Project.mxd
AddLayer
soil.mxd
AddLayer
soil_20008.mxd
AddLayer
ta34b_4.mxd
AddLayer
wells.mxd
AddLayer
6
2015-03-18
3.20723655198e-07
&amp;gt;&amp;gt;&amp;gt; &lt;/PRE&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; background-color: rgba(248, 248, 248, 0.6);"&gt; I have been unable to get execution times for the processes. when i measured this process with stopper -i got 9.6 second in real time&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; background-color: rgba(248, 248, 248, 0.6);"&gt;but in the code the score is 3.207. I dont know if 3.2 is seconds -and if it is that mean this time isn't right.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #333333; font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; background-color: rgba(248, 248, 248, 0.6);"&gt;Any help would be great &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:43 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590524#M46294</guid>
      <dc:creator>Yaron_YosefCohen</dc:creator>
      <dc:date>2021-12-12T01:21:43Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590525#M46295</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;practice&amp;nbsp; with your stop watch before you use the time function&lt;/P&gt;&lt;P&gt;copy and paste these in an interactive editor session&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&amp;gt;&amp;gt;&amp;gt; import datetime
&amp;gt;&amp;gt;&amp;gt; now = datetime.datetime.now()&amp;nbsp; # wait a bit, then paste the next line
&amp;gt;&amp;gt;&amp;gt; later = datetime.datetime.now()
&amp;gt;&amp;gt;&amp;gt; # ... your code stuff here or nothing ...
&amp;gt;&amp;gt;&amp;gt; elapsed = later - now
&amp;gt;&amp;gt;&amp;gt; print elapsed
0:00:04.416000
&amp;gt;&amp;gt;&amp;gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590525#M46295</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2021-12-12T01:21:46Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590526#M46296</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;And for extra clarity... just substitute the &lt;STRONG&gt;nap_time&lt;/STRONG&gt; line with your code block&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;#&amp;nbsp; time_timeit_sleep_demo.py
#&amp;nbsp; &lt;A href="mailto:Dan.Patterson@carleton.ca" rel="nofollow noopener noreferrer" target="_blank"&gt;Dan.Patterson@carleton.ca&lt;/A&gt;
#
import time
import datetime
now = datetime.datetime.now()
#
nap_time = time.sleep(5)&amp;nbsp; # sleep time in seconds... change to test
#
later = datetime.datetime.now()
elapsed = later - now
print('Nap time was... {} seconds').format(elapsed)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590526#M46296</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2021-12-12T01:21:48Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590527#M46297</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dan, the run time is acually less then in my watch timer- why is it?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Mar 2015 10:11:01 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590527#M46297</guid>
      <dc:creator>Yaron_YosefCohen</dc:creator>
      <dc:date>2015-03-18T10:11:01Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590528#M46298</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;maybe computer clock speeds...don't know &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Mar 2015 10:26:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590528#M46298</guid>
      <dc:creator>DanPatterson_Retired</dc:creator>
      <dc:date>2015-03-18T10:26:47Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590529#M46299</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks&amp;nbsp; Dan&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Mar 2015 11:29:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590529#M46299</guid>
      <dc:creator>Yaron_YosefCohen</dc:creator>
      <dc:date>2015-03-18T11:29:28Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590530#M46300</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Implement a Timer class to reuse throughout the code base.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;class Timer:&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; def __enter__(self):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; self.start = time.clock()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return self
&amp;nbsp;&amp;nbsp;&amp;nbsp; def __exit__(self, *args):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; self.end = time.clock()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; self.interval = self.end - self.start&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Simple to implement, especially when you wrap up your functions/code blocks into individual def's&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;def dftest():
&amp;nbsp;&amp;nbsp;&amp;nbsp; #some process wrapped up in this def()

#time the process
t = Timer()
with t:
&amp;nbsp;&amp;nbsp;&amp;nbsp; dftest()

print "The process took %.2f Milisecs. " % (t.interval)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590530#M46300</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2021-12-12T01:21:51Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590531#M46301</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;where i implement your code in my code?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 18 Mar 2015 13:54:12 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590531#M46301</guid>
      <dc:creator>Yaron_YosefCohen</dc:creator>
      <dc:date>2015-03-18T13:54:12Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590532#M46302</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;class Timer:&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; def __enter__(self):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; self.start = time.clock()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return self
&amp;nbsp;&amp;nbsp;&amp;nbsp; def __exit__(self, *args):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; self.end = time.clock()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; self.interval = self.end - self.start
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
import arcpy,os,sys,string,datetime,timeit&amp;nbsp; 
import arcpy.mapping&amp;nbsp; 
from arcpy import env&amp;nbsp; 

def mainProcess():
&amp;nbsp;&amp;nbsp;&amp;nbsp; env.workspace = r"C:\Project"&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; Layer1 = arcpy.mapping.Layer(r"C:\Project\layers\atikot.lyr")&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; counter = 0&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; for mxd in arcpy.ListFiles("*.mxd"):&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print (mxd)&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mapdoc = arcpy.mapping.MapDocument(r"C:\Project\\" + mxd)&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; df = arcpy.mapping.ListDataFrames(mapdoc, "Layers")[0]&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; arcpy.mapping.AddLayer(df ,Layer1, "TOP")&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print ('AddLayer')&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; mapdoc.save()&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; counter = counter + 1&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; del mxd 
&amp;nbsp; 
t = Timer()
with t:
&amp;nbsp;&amp;nbsp;&amp;nbsp; mainProcess()

print "The process took %.2f Milisecs. " % (t.interval)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590532#M46302</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2021-12-12T01:21:54Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590533#M46303</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This slight change should give you the time interval in seconds:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;#adjust from miliseconds to seconds
&lt;SPAN class="keyword"&gt;print &lt;SPAN class="string"&gt;"The process took %.02f secs. "&lt;/SPAN&gt; % (t.interval) &lt;/SPAN&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590533#M46303</guid>
      <dc:creator>JamesCrandall</dc:creator>
      <dc:date>2021-12-12T01:21:56Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590534#M46304</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have found function decorators a useful way to do this kind of thing. A good starting guide on function decorators is available at &lt;A href="http://simeonfranklin.com/blog/2012/jul/1/python-decorators-in-12-steps/" title="http://simeonfranklin.com/blog/2012/jul/1/python-decorators-in-12-steps/" rel="nofollow noopener noreferrer" target="_blank"&gt;simeonfranklin.com - Understanding Python Decorators in 12 Easy Steps!&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Basically, you wrap your processing function inside a timer function. This can be done ad-hoc by pre-pending the function definition with a decorator name and the @ symbol:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import time
import inspect

def recordPerformance(func):
&amp;nbsp;&amp;nbsp;&amp;nbsp; def wrapper(*arg):
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; t1 = time.clock()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; res = func(*arg)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; t2 = time.clock()
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print '%s, %0.2f' % (func.func_name, (t2-t1))
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; return res
&amp;nbsp;&amp;nbsp;&amp;nbsp; return wrapper

def mainProcess():
&amp;nbsp;&amp;nbsp;&amp;nbsp; subProcess1()
&amp;nbsp;&amp;nbsp;&amp;nbsp; subProcess2()
&amp;nbsp;&amp;nbsp;&amp;nbsp; subProcess3()

@recordPerformance
def subProcess1():
&amp;nbsp;&amp;nbsp;&amp;nbsp; time.sleep(2)

@recordPerformance
def subProcess2():
&amp;nbsp;&amp;nbsp;&amp;nbsp; time.sleep(1)

@recordPerformance
def subProcess3():
&amp;nbsp;&amp;nbsp;&amp;nbsp; time.sleep(3)


mainProcess()&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When you run this the result is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;subProcess1&lt;/SPAN&gt;, 1.99
&lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;subProcess2&lt;/SPAN&gt;, 1.01
&lt;SPAN style="color: rgba(0, 0, 0, 0); font-family: Consolas, 'Courier New', Courier, mono, serif; font-size: 12px;"&gt;subProcess3&lt;/SPAN&gt;, 3.00&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;EDIT - fixed function names in output results.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This approach provides a lot of flexibility and is great for logging and performance timing.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:21:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590534#M46304</guid>
      <dc:creator>OwenEarley</dc:creator>
      <dc:date>2021-12-12T01:21:59Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590535#M46305</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks Owen, i will try it&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Mar 2015 07:00:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590535#M46305</guid>
      <dc:creator>Yaron_YosefCohen</dc:creator>
      <dc:date>2015-03-19T07:00:38Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590536#M46306</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;thanks James, when i run your code i get exactly the same result (seconds) as the of Dan's code. acualy ,when i measured time with stopper it shoe 5 second more than arcpy- maybe it because py call all modules and then start to measured the time?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 19 Mar 2015 07:36:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/590536#M46306</guid>
      <dc:creator>Yaron_YosefCohen</dc:creator>
      <dc:date>2015-03-19T07:36:30Z</dc:date>
    </item>
    <item>
      <title>Re: Execution time- Arcpy</title>
      <link>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/1405840#M70257</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/1066"&gt;@DanPatterson_Retired&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Not sure if you're still monitoring this thread but just wanted to comment that the syntax for Python 3.x has changed since Print is now a function so the brackets have to change slightly:&lt;/P&gt;&lt;LI-CODE lang="python"&gt;print('Script Complete...run time was... {} seconds'.format(elapsed))&lt;/LI-CODE&gt;&lt;P&gt;Figured I'd share this updated line here in case anyone else is trying to use it. Thanks for providing the original code block!&lt;/P&gt;</description>
      <pubDate>Thu, 04 Apr 2024 16:02:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/execution-time-arcpy/m-p/1405840#M70257</guid>
      <dc:creator>FredMitchell</dc:creator>
      <dc:date>2024-04-04T16:02:08Z</dc:date>
    </item>
  </channel>
</rss>

