How can I use the new ArcGIS Pro PerfTools Add-in?

2779
8
10-11-2016 10:44 AM
Labels (1)
IanSims
Esri Contributor
2 8 2,779

I’ve installed the new PerfTools add-in for ArcGIS Pro; what are some scenarios in which this new tool can help optimize performance?

Displaying and Logging Rendering Time for Specific Spatial Extents

Have you created a series of spatial bookmarks in your ArcGIS Pro project? A one-line script command (ZoomToBookmarks all) can zoom through these spatial bookmarks and log draw time, frames per second (FPS) metrics, and other timestamps. No bookmarks?  No problem…you can also specify extents by providing 2D or 3D camera positions in the same spatial coordinates as your data. Capture_BookmarksLog-1024x611.png

Playing and Timing Animations

Have you added an animation? Using the PlayAnimation command returns measures of total elapsed animation time, as well as average and minimum FPS.

Roaming

To build a thorough display cache or simulate navigation through large datasets without specifying bookmarks or camera positions, you can use the roaming capabilities of PerfTools. This allows you to virtually “walk” across the active view, starting from the upper left and moving row-by-row towards the lower right. The total draw time, in addition to average and minimum FPS, are logged for your reference.

RoamingDiagram-300x300.png

Timing Spatial Selection

Moving from a file geodatabase to an enterprise geodatabase? Or have you updated your spatial index? You can examine the impacts these changes have on making spatial selections in ArcGIS Pro. The SelectFeatures command allows you to specify your selection bounding box in screen coordinates on the active 2D or 3D view. PerfTools logs a count of the features selected, as well as the selection and draw complete times.

Scripting Commands

Most power from the PerfTools add-in comes through a comprehensive scripting language that allows you to assemble several commands into a more comprehensive scenario. With this functionality, you can simulate typical user interactions with ArcGIS Pro, including creating and opening projects, panning, zooming, selecting, and so forth. You can add delays or “think time”, as well as looping commands (ForCount, ForFile, ForFolder, and ForTime) to repeat key parts of your workflow. Via script command, you can also control key aspects of logging content and structure in PerfTools.

Custom Script Commands

Not finding the script command you’re looking for? PerfTools allows you to create your own commands through leveraging the ArcGIS Pro SDK. Part of the PerfTools download includes documentation and a sample, “T1Command”, that gets you started with your own customizations.

More Documentation?

After installing the add-in and opening Pro, Take a look in your Documents\ArcGIS\AddIns\ArcGISPro\PerfTools folder.  You should see a PDF there titled "PerfTools_for_ArcGIS_Pro.pdf".  This contains comprehensive documentation and sample code snippets.

Is PerfTools comprehensive? You bet! We’ll be taking a closer look at some of these techniques in upcoming blog posts. In the meantime, feel free to download the PerfTools AddIn and try it out for yourself! 


Ian S. – Performance Engineer
8 Comments
ThomasColson
MVP Frequent Contributor

I'm really interested in using this tool, are you able to post a sample script that demonstrates some of the concepts in your post? I'm having a hard time with the minimal documentation. 

IanSims
Esri Contributor

Take a look in your Documents\ArcGIS\AddIns\ArcGISPro\PerfTools folder once you’ve opened Pro.  You should see a PDF there with the full documentation and code samples.  Let me know if you need more specifics.  Thanks.

MatthewIrwin
New Contributor III

is there some sample data that goes with the script examples?

AndrewQuee
Occasional Contributor III

Thanks for that link to the manual - as far as I know this is the only reference to it.  It would be good if it was available from the tool ribbon.

PerfTools for Desktop had a neat function for randomly generating extents for sampling and testing from a feature class.  Does this add-in support that feature?

LyonMNGIS
Occasional Contributor II

Hi,

The PerfTools demos are working with ArcGIS Pro 3.0.2.  Unfortunatly, I am having trouble when I try to use my own map.

Here is what I did:

  • Create a Map
  • Add several bookmarks
  • Open Preftool-->View-->Script View
  • Added ZoomToBookmarks all
  • Press play within the script view window

Here is what happens:

  • The tool will zoom to the first bookmark.  A dialog for PrefTools.PanZoomCommand will display but appear to keep running.
  • The tool does not zoom to the next bookmark.

Am I missing something?

Thanks

xecushenbery
New Contributor

@LyonMNGIS  Same issue, were you able to get this working? The progress dialog just hangs on the first one.

LyonMNGIS
Occasional Contributor II

@xecushenbery 

I did not have enough time to look further into the matter.  Instead I just got around the problem by loading my data and bookmarks into the demo Portland map.

I found that as expected that Geodatabases with the Standard label engine draw the fastest.  Mapplex will take longer with complicated rules.  AGOL was by and far the slowest even with caching enabled.

 

 

 

AndrewQuee
Occasional Contributor III

Readers, please note the download link provided here is 404 at writing.  The latest version appears to be "PerfTools (Build 258) for ArcGIS Pro 2.x and 3.x is now available for download"  as at 2022-06-23.

For future perftool updates: IanSims personal OneDrive and IanSims blog.

Using Pro 3.1.3, yes "ZoomToBookmarks all" seems to jump to the first bookmark then choke.  'Roaming' feature works okay.

Metrics View, Render View and Log View are only ones I use for performance testing and these all work fine.

Thanks again to @IanSims for continuing to support this valuable project!

About the Author
Esri Performance Engineering. From Warwickshire, England. Mapper, photographer, explorer and technology evangelist.