describe_what_if_analysis

ForecastService.Client.describe_what_if_analysis(**kwargs)

Describes the what-if analysis created using the CreateWhatIfAnalysis operation.

In addition to listing the properties provided in the CreateWhatIfAnalysis request, this operation lists the following properties:

  • CreationTime
  • LastModificationTime
  • Message - If an error occurred, information about the error.
  • Status

See also: AWS API Documentation

Request Syntax

response = client.describe_what_if_analysis(
    WhatIfAnalysisArn='string'
)
Parameters
WhatIfAnalysisArn (string) --

[REQUIRED]

The Amazon Resource Name (ARN) of the what-if analysis that you are interested in.

Return type
dict
Returns
Response Syntax
{
    'WhatIfAnalysisName': 'string',
    'WhatIfAnalysisArn': 'string',
    'ForecastArn': 'string',
    'EstimatedTimeRemainingInMinutes': 123,
    'Status': 'string',
    'Message': 'string',
    'CreationTime': datetime(2015, 1, 1),
    'LastModificationTime': datetime(2015, 1, 1),
    'TimeSeriesSelector': {
        'TimeSeriesIdentifiers': {
            'DataSource': {
                'S3Config': {
                    'Path': 'string',
                    'RoleArn': 'string',
                    'KMSKeyArn': 'string'
                }
            },
            'Schema': {
                'Attributes': [
                    {
                        'AttributeName': 'string',
                        'AttributeType': 'string'|'integer'|'float'|'timestamp'|'geolocation'
                    },
                ]
            },
            'Format': 'string'
        }
    }
}

Response Structure

  • (dict) --
    • WhatIfAnalysisName (string) --

      The name of the what-if analysis.

    • WhatIfAnalysisArn (string) --

      The Amazon Resource Name (ARN) of the what-if analysis.

    • ForecastArn (string) --

      The Amazon Resource Name (ARN) of the what-if forecast.

    • EstimatedTimeRemainingInMinutes (integer) --

      The approximate time remaining to complete the what-if analysis, in minutes.

    • Status (string) --

      The status of the what-if analysis. States include:

      • ACTIVE
      • CREATE_PENDING , CREATE_IN_PROGRESS , CREATE_FAILED
      • CREATE_STOPPING , CREATE_STOPPED
      • DELETE_PENDING , DELETE_IN_PROGRESS , DELETE_FAILED

      Note

      The Status of the what-if analysis must be ACTIVE before you can access the analysis.

    • Message (string) --

      If an error occurred, an informational message about the error.

    • CreationTime (datetime) --

      When the what-if analysis was created.

    • LastModificationTime (datetime) --

      The last time the resource was modified. The timestamp depends on the status of the job:

      • CREATE_PENDING - The CreationTime .
      • CREATE_IN_PROGRESS - The current timestamp.
      • CREATE_STOPPING - The current timestamp.
      • CREATE_STOPPED - When the job stopped.
      • ACTIVE or CREATE_FAILED - When the job finished or failed.
    • TimeSeriesSelector (dict) --

      Defines the set of time series that are used to create the forecasts in a TimeSeriesIdentifiers object.

      The TimeSeriesIdentifiers object needs the following information:

      • DataSource
      • Format
      • Schema
      • TimeSeriesIdentifiers (dict) --

        Details about the import file that contains the time series for which you want to create forecasts.

        • DataSource (dict) --

          The source of your data, an Identity and Access Management (IAM) role that allows Amazon Forecast to access the data and, optionally, an Key Management Service (KMS) key.

          • S3Config (dict) --

            The path to the data stored in an Amazon Simple Storage Service (Amazon S3) bucket along with the credentials to access the data.

            • Path (string) --

              The path to an Amazon Simple Storage Service (Amazon S3) bucket or file(s) in an Amazon S3 bucket.

            • RoleArn (string) --

              The ARN of the Identity and Access Management (IAM) role that Amazon Forecast can assume to access the Amazon S3 bucket or files. If you provide a value for the KMSKeyArn key, the role must allow access to the key.

              Passing a role across Amazon Web Services accounts is not allowed. If you pass a role that isn't in your account, you get an InvalidInputException error.

            • KMSKeyArn (string) --

              The Amazon Resource Name (ARN) of an Key Management Service (KMS) key.

        • Schema (dict) --

          Defines the fields of a dataset.

          • Attributes (list) --

            An array of attributes specifying the name and type of each field in a dataset.

            • (dict) --

              An attribute of a schema, which defines a dataset field. A schema attribute is required for every field in a dataset. The Schema object contains an array of SchemaAttribute objects.

              • AttributeName (string) --

                The name of the dataset field.

              • AttributeType (string) --

                The data type of the field.

                For a related time series dataset, other than date, item_id, and forecast dimensions attributes, all attributes should be of numerical type (integer/float).

        • Format (string) --

          The format of the data, either CSV or PARQUET.

Exceptions

  • ForecastService.Client.exceptions.InvalidInputException
  • ForecastService.Client.exceptions.ResourceNotFoundException