Ë
    BÆVh–	  ã                   óH   — d Z ddlZddlZd„ Z ej
                  d«      Zd„ Zy)z3Testing utilities for tfdbg command-line interface.é    Nc           	      ó<  — | j                  t        |«      t        |«      dt        |«      t        |«      fz  «       t        ||«      D ]Q  \  }}| j                  dj                  |j	                  «       «      dj                  |j	                  «       «      «       ŒS y)a  Assert equality in lines, ignoring all whitespace.

  Args:
    test: An instance of unittest.TestCase or its subtypes (e.g.,
      TensorFlowTestCase).
    expected_lines: Expected lines as an iterable of strings.
    actual_lines: Actual lines as an iterable of strings.
  z)Mismatch in the number of lines: %d vs %dÚ N)ÚassertEqualÚlenÚzipÚjoinÚsplit)ÚtestÚexpected_linesÚactual_linesÚexpected_lineÚactual_lines        úZ/home/dcms/DCMS/lib/python3.12/site-packages/tensorflow/python/debug/cli/cli_test_utils.pyÚ&assert_lines_equal_ignoring_whitespacer      s‘   € ð ×ÑÜ	ˆ.Óœ3˜|Ó,Ø1Ü
ˆnÓ
œs <Ó0ð52ñ 2ô3ô %(¨¸Ó$Eò 3Ñ €m[Ø×ÑR—W‘W˜]×0Ñ0Ó2Ó3Ø—W‘W˜[×.Ñ.Ó0Ó1õ3ñ3ó    z(array|\(|\[|\]|\)|\||,)c                 óþ   — g }|D ]C  }t        j                  t        d|«      }|j                  d„ |j	                  «       D «       «       ŒE | j                  t        j                  |«      j                  «       |«       y)aÝ  Assert that the array value represented by lines is close to expected.

  Note that the shape of the array represented by the `array_lines` is ignored.

  Args:
    test: An instance of TensorFlowTestCase.
    expected_array: Expected value of the array.
    array_lines: A list of strings representing the array.
      E.g., "array([[ 1.0, 2.0 ], [ 3.0, 4.0 ]])"
      Assumes that values are separated by commas, parentheses, brackets, "|"
      characters and whitespace.
  ú c              3   ó2   K  — | ]  }t        |«      –— Œ y ­w)N)Úfloat)Ú.0Úss     r   ú	<genexpr>z+assert_array_lines_close.<locals>.<genexpr><   s   è ø€ Ò3 ”E˜!—HÑ3ùs   ‚N)	ÚreÚsubÚ_ARRAY_VALUE_SEPARATOR_REGEXÚextendr	   ÚassertAllCloseÚnpÚarrayÚflatten)r
   Úexpected_arrayÚarray_linesÚelementsÚlines        r   Úassert_array_lines_closer%   ,   sg   € ð €(Øò 4€dÜ6‰6Ô.°°TÓ:€DØ‡OOÑ3 d§j¡j£lÔ3Õ3ð4ð ×Ñ”b—h‘h˜~Ó.×6Ñ6Ó8¸(ÕCr   )Ú__doc__r   Únumpyr   r   Úcompiler   r%   © r   r   ú<module>r*      s/   ðñ :Û 	ã ò3ð(  *˜rŸz™zÐ*EÓFÐ óDr   