관리-도구
편집 파일: test_scalarbuffer.cpython-311.pyc
� �܋f� � � � d Z ddlZddlmZ ddlmZ ddlZddlm Z m Z mZ ej dfej dfej dfej d fej d fej dfej dfej d fej dfej dfej dfej dfej dfej dfej dfej dfej dfej dfgZ ee� \ Z Z! G d� d� � Z"dS )z2 Test scalar buffer interface adheres to PEP 3118 � N)�rational)�get_buffer_info)�assert_�assert_equal� assert_raises�?�b�h�i�l�q�B�H�I�L�Q�e�f�d�g�Zf�Zd�Zgc � � e Zd Zej � dee�� � d� � � Zej � dee�� � d� � � Z ej � de e�� � d� � � Zej � dee�� � d� � � Zd� Z d � Zd � Zej � d ej dd �� � ej dd�� � ej dd�� � g� � d� � � Zd� ZdS )�TestScalarPEP3118�scalar)�idsc �� � |� � }t j g t j |� � �� � }t |� � }t |� � }t |j |j � � d S )N��dtype)�np�arrayr � memoryviewr �format)�selfr �x�a�mv_x�mv_as �u/builddir/build/BUILD/cloudlinux-venv-1.0.6/venv/lib64/python3.11/site-packages/numpy/core/tests/test_scalarbuffer.py�test_scalar_match_arrayz)TestScalarPEP3118.test_scalar_match_array% s[ � ��F�H�H���H�R�r�x��/�/�0�0�0���!�}�}���!�}�}���T�[�$�+�.�.�.�.�.� c �8 � |� � }t |� � }t |j t j |� � j � � t |j d� � t |j d� � t |j d� � t |j d� � d S )Nr � ) r# r �itemsizer! r �ndim�shape�strides� suboffsets)r% r r&