Intel® Advisor User Guide

ID 766448
Date 7/13/2023
Public

A newer version of this document is available. Customers should click here to go to the newest version.

Document Table of Contents

collect.py Options

Depending on options specified, collect basic data, do markup, and collect refinement data. By default, execute all steps. For any step besides markup, you must specify an application argument.

Usage

advisor-python <APM>/collect.py <project-dir> [--options] -- <target> [target-options]

NOTE:
Replace <APM> with $APM on Linux* OS or %APM% on Windows* OS.

Options

The following table describes options that you can use with the collect.py script. The target application to analyze and application options, if any, must be preceded by two dashes and a space.

Option

Description

<project-dir>

Required. Specify the path to the Intel® Advisor project directory.

-h

--help

Show all script options.

-v <verbose>

--verbose <verbose>

Specify output verbosity level:

  • 1 - Show only error messages. This is the least verbose level.

  • 2 - Show warning and error messages.

  • 3 (default) - Show information, warning, and error messages.

  • 4 - Show debug, information, warning, and error messages. This is the most verbose level.

NOTE:
This option affects the console output, but does not affect logs and report results.

-c {basic, refinement, full}

--collect {basic, refinement, full}

Specify the type of data to collect for an application:

  • basic - Collect basic performance data (Survey, Trip Counts, FLOP), analyze data transfer between host and device memory, attribute memory objects to loops, and track accesses to stack memory.
  • refinement - Collect refined data (Dependencies) for marked loops only. Do not analyze data transfers.
  • full (default) - Collect both basic data for application and refined data for marked loops, analyze data transfer between host and device memory and potential data reuse, attribute memory objects to loops, and track accesses to stack memory.
NOTE:
For --collect full, make sure to use --data-reuse-analysis and --track-memory-objects for the Performance modeling with analyze.py or advisor --collect=projection.

For --collect basic, make sure to use the --track-memory-objects for the Performance modeling with analyze.py or advisor --collect=projection.

--config <config>

Specify a configuration file by absolute path or name. If you choose the latter, the model configuration directory is searched for the file first, then the current directory.

You can specify several configurations by using the option more than once.

Examples

  • Collect full data on myApplication with default configuration and save the project to the ./advi directory.

    advisor-python $APM/collect.py ./advi_results -- ./myApplication
  • Collect refinement data for OpenMP* and SYCL loops on myApplication with a custom configuration file config.toml and save the project to the ./advi directory.

    advisor-python $APM/collect.py ./advi_results --collect refinement --markup [omp,icpx -fsycl] --config ./config.toml -- ./myApplication
  • Get commands appropriate for a custom configuration specified in the config.toml file to collect data separately with advisor. The commands are ready to copy and paste.

    advisor-python $APM/collect.py ./advi_results --dry-run --config ./config.toml