
      i                     \    d dl Z d dlmZ  G d de      Z G d de      Zdeded	ed
dfdZ	y)    N)MisconfigurationExceptionc                       e Zd ZdZy)SIGTERMExceptiona  Exception used when a :class:`signal.SIGTERM` is sent to a process.

    This exception is raised by the loops at specific points. It can be used to write custom logic in the
    :meth:`pytorch_lightning.callbacks.callback.Callback.on_exception` method.

    For example, you could use the :class:`pytorch_lightning.callbacks.fault_tolerance.OnExceptionCheckpoint` callback
    that saves a checkpoint for you when this exception is raised.

    N__name__
__module____qualname____doc__     {/Volumes/fast/ai/experiments/voice-extract-mac/.venv/lib/python3.12/site-packages/pytorch_lightning/utilities/exceptions.pyr   r      s    r   r   c                       e Zd ZdZy)_TunerExitExceptionz*Exception used to exit early while tuning.Nr   r   r   r   r   r      s    4r   r   	exceptionpatternnew_messagereturnc                 P    t        fd| j                  D              | _        y )Nc              3      K   | ]=  }t        |t              r't        j                  |t        j                        rn| ? y w)N)
isinstancestrrematchDOTALL).0argr   r   s     r   	<genexpr>z#_augment_message.<locals>.<genexpr>$   s9      ft_bz#s+#ryy0QWZZfts   AA)tupleargs)r   r   r   s    ``r   _augment_messager    #   s"     foftft INr   )
r   %lightning_fabric.utilities.exceptionsr   
SystemExitr   	Exceptionr   BaseExceptionr   r    r   r   r   <module>r%      sG    
 K	z 	5) 5  # RV r   