
    BVh                     R    d Z ddlmZ  e       ZefdZ ed      eeeefd       Zy)a:  Directives are special no-op functions that serve as compilation markers.

They provide static information like type hints, compilation and TensorFlow
overrides.

These serve as annotations in the compiled code, allowing the user some control
over the compilation process. They have no functional role at runtime.
    )	tf_exportc                  
    ~ ~~y)a;  Indicates that the entity is expected hold items of specified type/shape.

  The staged TensorFlow ops will reflect and assert this data type. Ignored
  otherwise.

  Args:
    entity: The entity to annotate.
    dtype: TensorFlow dtype value to assert for entity.
    shape: Optional shape to assert for entity.
  N )entitydtypeshapes      [/home/dcms/DCMS/lib/python3.12/site-packages/tensorflow/python/autograph/lang/directives.pyset_element_typer
      s         z'autograph.experimental.set_loop_optionsc                      ~ ~~~y)ao  Specifies additional arguments to be passed to the enclosing while_loop.

  The parameters apply to and only to the immediately enclosing loop. It only
  has effect if the loop is staged as a TF while_loop; otherwise the parameters
  have no effect.

  Usage:

    >>> @tf.function(autograph=True)
    ... def f():
    ...   n = 0
    ...   for i in tf.range(10):
    ...     tf.autograph.experimental.set_loop_options(maximum_iterations=3)
    ...     n += 1
    ...   return n

    >>> @tf.function(autograph=True)
    ... def f():
    ...   v = tf.constant((0,))
    ...   for i in tf.range(3):
    ...     tf.autograph.experimental.set_loop_options(
    ...         shape_invariants=[(v, tf.TensorShape([None]))]
    ...     )
    ...     v = tf.concat((v, [i]), 0)
    ...   return v

  Also see tf.while_loop.

  Args:
    parallel_iterations: The maximum number of iterations allowed to run in
        parallel at any given time. Note that this does not guarantee parallel
        execution.
    swap_memory: Whether to store intermediate values needed for
        gradients on the CPU instead of GPU.
    maximum_iterations: Allows limiting the total number of iterations executed
        by the loop.
    shape_invariants: Allows controlling the argument with the same name passed
        to tf.while_loop. Unlike tf.while_loop, this is a list of
        `(tensor, shape)` pairs.
  Nr   )parallel_iterationsswap_memorymaximum_iterationsshape_invariantss       r	   set_loop_optionsr   -   s    \ r   N)__doc__ tensorflow.python.util.tf_exportr   objectUNSPECIFIEDr
   r   r   r   r	   <module>r      sF    7h +6   45#" 	0 60r   