o
    ¶2úhå  ã                   @   s$   d Z ddlZddlmZ dd„ ZdS )z#Functions for dealing with metrics.é    N)Úapi_pb2c                 C   sR   t | tƒsJ ‚t |tjƒsJ ‚tj | |j¡}| d¡r"|dd… }|j	}||fS )zÁReturns a (run,tag) tuple storing the evaluations of the specified
    metric.

    Args:
      session_name: str.
      metric_name: MetricName protobuffer.
    Returns: (run, tag) tuple.
    ú/Néÿÿÿÿ)
Ú
isinstanceÚstrr   Ú
MetricNameÚosÚpathÚjoinÚgroupÚendswithÚtag)Úsession_nameÚmetric_nameÚrunr   © r   ú^/var/www/html/chatgem/venv/lib/python3.10/site-packages/tensorboard/plugins/hparams/metrics.pyÚrun_tag_from_session_and_metric   s   	
r   )Ú__doc__r   Útensorboard.plugins.hparamsr   r   r   r   r   r   Ú<module>   s   