
    bIg                        d dl mZ d dlZd dlZd dlmZmZ  G d dej                        Zedk(  r ej                          yy)    )annotationsN)parserprinterc                      e Zd ZddZddZy)TestBasicFunctionsc                D   | j                  t        |j                        d       | j                  |j                  d   j                  d       | j                  |j                  d   j                  d       | j                  |j                  d   j                  d       y )N   r   MatMul   Add   Softmax)assertEquallennodeop_type)selfgraphs     S/var/www/html/answerous/venv/lib/python3.12/site-packages/onnx/test/printer_test.pycheck_graphzTestBasicFunctions.check_graph   st    UZZ!,A..9A..6A..	:    c                    d}t        j                  |      }t        j                  |      }t        j                  |      }t        j                  |      }| j	                  ||       | j                  |       y )Nz
           agraph (float[N, 128] X, float[128,10] W, float[10] B) => (float[N] C)
           {
              T = MatMul(X, W)
              S = Add(T, B)
              C = Softmax(S)
           }
           )r   parse_graphr   to_textr   r   )r   text0graph1text1graph2text2s         r   test_parse_graphz#TestBasicFunctions.test_parse_graph   sg     ##E*'##E*' 	& r   N)r   zonnx.GraphProtoreturnNone)r!   r"   )__name__
__module____qualname__r   r     r   r   r   r      s    ;!r   r   __main__)

__future__r   unittestonnxr   r   TestCaser   r#   mainr&   r   r   <module>r-      s?    #    !** !6 zHMMO r   