
    ^j                    $    d dl mZ  G d d      Zy)    )annotationsc                  8    e Zd ZdddZddZd	dZed	d       Zy)
	IdCounterc                    || _         | j                   | j                  k  rt        d| j                         | j                          y)z
        Initialize the ID counter.

        Args:
            start_id: The starting integer for the counter.

        Raises:
            ValueError: If start_id is less than or equal to -1.
        zstart_id must be greater than N)start_idNO_ID
ValueErrorreset)selfr   s     q/var/www/ramen.bs-engineer-server.com/venv/lib/python3.12/site-packages/supervision/tracker/byte_tracker/utils.py__init__zIdCounter.__init__   s;     !==DJJ&=djj\JKK

    c                &    | j                   | _        y)z*Reset the counter to the initial start_id.N)r   _idr   s    r   r
   zIdCounter.reset   s    ==r   c                H    | j                   }| xj                   dz  c_         |S )zt
        Get the current ID and increment the counter.

        Returns:
            The newly assigned ID.
           )r   )r   returned_ids     r   new_idzIdCounter.new_id   s      hhAr   c                     y)N r   s    r   r   zIdCounter.NO_ID#   s    r   N)r   )r   int)returnNone)r   r   )__name__
__module____qualname__r   r
   r   propertyr   r   r   r   r   r      s%    !	  r   r   N)
__future__r   r   r   r   r   <module>r!      s    "! !r   