관리-도구
편집 파일: test_linalg.cpython-311.pyc
� �܋f�/ � �� � d Z ddlZddlZddlZddlZddlZddlZddlZddlZ ddlm Z mZmZm Z mZmZmZmZ ddlmZ ddlmZmZmZmZ ddlmZ ddlmZmZmZmZmZ ddlm Z dd l!m"Z"m#Z#m$Z$m%Z%m&Z&m'Z'm(Z(m)Z)m*Z*m+Z+ d � Z,e&Z-d�d �Z&d� Z.d� Z/d� Z0h d�Z1 G d� d� � Z2d� Z3e j4 �5 d� � g Z6e6 e3d e2d e ddgddgge�� � e ddge�� � � � e2d e ddgddgge�� � e ddge�� � � � e2d e ddgddgge�� � e g d�g d �ge�� � � � e2d! e d"d#gd$d%gge �� � e d&d"ge �� � � � e2d' e d"d#gd$d%gge�� � e d&d"ge�� � � � e2d( e d"d#gd$d%gge�� � e g d)�g d*�ge�� � � � e2d+ e j7 d,e�� � e j7 d-e�� � d.h�/� � e2d0e j4 �8 d1d1� � e j4 �8 d1� � � � e2d2e j4 �8 d3d3� � e j4 �8 d3� � � � e2d4d3d5gd6d7ggd5d3g� � g � � z Z6e6 e3d8 e2d9 e g d:�g d �ge�� � e ddge�� � � � e2d; e ddgddgd<d=gge�� � e g d>�e�� � � � e2d? e g d:�g d �ge�� � e ddge�� � � � e2d@ e ddgddgd<d=gge�� � e g d>�e�� � � � e2dA e g dB�g dC�ge �� � e d&d"ge �� � � � e2dD e dEdFgdGdHgdIdJgge �� � e g dK�e �� � � � e2dL e g dB�g dC�ge�� � e d&d"ge�� � � � e2dM e dEdFgdGdHgdIdJgge�� � e g dK�e�� � � � e2dN e g dB�g dC�ge�� � e d&d"gdOdPgge�� � � � e2dQ e dEdFgdGdHgdIdJgge�� � e d&d"gdOdPgdOdPgge�� � � � e2dRe j4 �8 d1dS� � e j4 �8 d1� � � � e2dTe j4 �8 d3dU� � e j4 �8 d3� � � � e2dVe j4 �8 dUd3� � e j4 �8 dU� � � � e2dWe j4 �8 dd7� � e j4 �8 d� � d.h�/� � e2dXe j4 �8 d7d� � e j4 �8 d7� � d.h�/� � g� � z Z6e6 e3dY e2dZ e ddgddgge�� � d� � e2d[ e ddgddgge�� � d� � e2d\ e dd#gd]d3gge �� � d� � e2d^ e dd#gd]d3gge�� � d� � e2d_ e j7 d,e�� � dd.h�/� � e2d`d3d5gd5d3ggd� � e2da e ddgddgg� � d� � e2dbe j4 �8 d3d3� � d� � g� � z Z6dc� Z9e6 e9� � z Z6dd� Z:de� Z;e6 e;� � z Z6 G df� dg� � Z< G dh� die<� � Z= G dj� dke<� � Z> G dl� dme<� � Z? G dn� doe<� � Z@ G dp� dqe<� � ZA G dr� dse<� � ZBdt� ZCdu� ZD G dv� dwe=e@� � ZE G dx� dyeE� � ZF G dz� d{e=e@� � ZG G d|� d}eG� � ZH G d~� de=e@� � ZI G d�� d�eI� � ZJ G d�� d�e=e@� � ZK G d�� d�eK� � ZL G d�� d�� � ZM G d�� d�e=e@� � ZN G d�� d�eNeM� � ZO G d�� d�e?eB� � ZP G d�� d�ePeM� � ZQ G d�� d�e=e@� � ZR G d�� d�eR� � ZS G d�� d�e=e>e@eA� � ZT G d�� d�eT� � ZU G d�� d�e?eB� � ZV G d�� d�eV� � ZW G d�� d�e=e@� � ZX G d�� d�eX� � ZY G d�� d�e=e>� � ZZ G d�� d�eZ� � Z[ej\ �] d�d�� d�D � � � � G d�� d�� � � � Z^ G d�� d�e?eB� � Z_ G d�� d�� � Z` G d�� d�e?eB� � Za G d�� d�� � Zb G d�� d�� � Zc G d�� d�ec� � Zd G d�� d�ec� � Ze G d�� d�eeed� � Zf G d�� d�� � Zg G d�� d�ec� � Zh G d�� d�ec� � Zi G d�� d�ec� � Zj G d�� d�efeh� � Zk G dÄ d�efei� � Zl G dń d�efej� � Zm G dDŽ dȦ � ZndɄ Zo G dʄ d˦ � Zp G d̄ dͦ � Zqd΄ Zrej\ �s e+dϬЦ � dф � � Ztd҄ Zuej\ �s e+dӬЦ � ej\ jv dԄ � � � � Zw G dՄ d֦ � Zx G dׄ dئ � Zy G dل dڦ � Zzdۄ Z{ej\ �| dܬЦ � d݄ � � Z}ej\ �~ e* dެЦ � d߄ � � ZdS )�z# Test functions for linalg module � N)�array�single�double�csingle�cdouble�dot�identity�matmul)�swapaxes)�multiply� atleast_2d�inf�asarray)�linalg)�matrix_power�norm�matrix_rank� multi_dot�LinAlgError)�_multi_dot_matrix_chain_order) �assert_�assert_equal� assert_raises�assert_array_equal�assert_almost_equal�assert_allclose�suppress_warnings�assert_raises_regex�HAS_LAPACK64�IS_WASMc � � t | � � t |t j � � rt |� � nt j u S �N)�type� isinstance�np�ndarray)�out�in_s �q/builddir/build/BUILD/cloudlinux-venv-1.0.6/venv/lib64/python3.11/site-packages/numpy/linalg/tests/test_linalg.py�consistent_subclassr* s9 � � ��9�9�j��b�j�&A�&A� )��c���� �j�*� *� � � c �~ � t | � � j j t t fv r|}n|}t | |fd|i|�� d S )N�decimal)r �dtyper# r r �old_assert_almost_equal)�a�b�single_decimal�double_decimal�kwr/ s r) r r $ sM � ��q�z�z����� 1�1�1� ��� ���A�q�8�8�'�8�R�8�8�8�8�8r+ c �r � t t t t t t t t i| S r"