Function: set_op_execute_time_out

Applicability

Product

Supported (√/x)

Atlas A3 training products/Atlas A3 inference products

Atlas A2 training products/Atlas A2 inference products

Atlas training products

Atlas inference products

Atlas 200I/500 A2 inference products

Function Usage

Sets the timeout interval for operator execution.

Prototype

  • C Prototype
    1
    aclError aclrtSetOpExecuteTimeOut(uint32_t timeout)
    
  • Python Function
    1
    ret = acl.rt.set_op_execute_time_out(timeout)
    

Parameter Description

Parameter

Description

timeout

Int, timeout interval, in seconds. 0 means to use the maximum timeout interval.

Return Value Description

Return Value

Description

ret

Int, error code: 0 on success; else, failure.

Restrictions

  • If this API is not called, the default timeout interval for operator execution is as follows.

    Version

    Default Timeout Interval of AI Core Operators

    Default Timeout Interval of AI CPU Operators

      

    547 seconds

    28 seconds

      

    68 seconds

    28 seconds

      

    1091 seconds

    28 seconds

      

    1091 seconds

    28 seconds

      

    1091 seconds

    60

  • If this API is called for multiple times in a process, setting of the last time is used. The maximum time that can be set is as follows.

    Version

    Maximum Timeout Interval of AI Core Operators

    Maximum Timeout Interval of AI CPU Operators

      

    547 seconds

    Not supported

      

    2176 seconds

    2176 seconds

      

    1091 seconds

    1091 seconds

      

    1091 seconds

    1091 seconds

      

    1091 seconds

    1091 seconds