+
    Y°³j  ã                   óž  a € R t"0 t R t^ RIt^ RIt^ RIHt ^ RIHt ^ RIH	t	 ^ RI
t^ RIHt ^ RIHt ^ RIHu Hu H
t ^ RIHtHt ^ RIHt RRR	R
 l35tRRR	R l35t]P4                  P7                  RR4      t] ^ k ]P4                  P7                  RR4      t ! R R]P<                  4      t]! ^d4      RR R ll4       t RR/R R llt!R# )z|
Override functions from array_api_compat, for use by array-api-extra
and internally.

See also _array_api_compat_vendor.py
N)Ú	lru_cache)Ú
ModuleType©ÚAny)Úarray_api_compat)Úis_array_api_objÚis_jax_array)Ú	SparseABCÚArray)é   c                ó    € V ^8„  d   Qh\         # ©é   r   ©Ú.formats   "Ú_/home/luca/screen-checking/.venv/lib/python3.14/site-packages/scipy/_lib/_array_api_override.pyr
   r
      s   € × Ð ŒSÐ ó    Ú	ArrayLikec                óJ   € V ^8„  d   Qh\         \        P                  ,          # r   )r
   Únptr   r   s   "r   r   r      s   € × &Ð &”œŸ™Õ&Ð &r   ÚSCIPY_ARRAY_APIFÚSCIPY_DEVICEÚcpuc                   ó&   € ] tR t^ t^ t^t^t^tRtR# )Ú_ArrayClsInfo© N)	Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__ÚskipÚnumpyÚ
array_likeÚunknownÚ__static_attributes__r   r   r   r   r       s   † Ø€DØ€EØ€JØ„Gr   r   c                ó0   € V ^8„  d   QhR\         R\        /# )r   ÚclsÚreturn)Útyper   )Úformats   "r   Ú__annotate__r*   (   s   € ÷ !ñ !œTð !´}ñ !r   c                 óò  € \        V \        \        ,          4      '       d   \        P                  # \        V \
        4      '       d&   V'       g   R p\        V4      h\        P                  # \        V \        P                  P                  4      '       d   \        R4      h\        V \        P                  4      '       d   \        R4      h\        V \        P                  \        P                  ,          4      '       d   \        P                  # \        V \        \         ,          \"        ,          \$        ,          \'        R4      ,          4      '       d   \        P(                  # \        P*                  # )z�Sparse arrays/matrices are not supported by this function. Perhaps one of the `scipy.sparse.linalg` functions would work instead.z8Inputs of type `numpy.ma.MaskedArray` are not supported.z0Inputs of type `numpy.matrix` are not supported.N)Ú
issubclassÚlistÚtupler   r"   r	   Ú
ValueErrorr!   ÚnpÚmaÚMaskedArrayÚ	TypeErrorÚmatrixÚndarrayÚgenericÚintÚfloatÚcomplexÚboolr(   r    r#   )r&   Ú	sparse_okÚmsgs   && r   Ú_validate_array_clsr=   '   sö   € ä�#”tœe•|×$Ò$Ü×'Ñ'Ð'ô �#”y×!Ò!ßð*ˆCô ˜S“/Ð!ô ×"Ñ"Ð"ä�#”r—u‘u×(Ñ(×)Ò)ÜÐRÓSÐSä�#”r—y‘y×!Ò!ÜÐJÓKÐKä�#”r—z‘z¤B§J¡JÕ.×/Ò/Ü×"Ñ"Ð"ô
 �#”sœU•{¤WÕ,¬tÕ3´d¸4³jÕ@×AÒAÜ×!Ñ!Ð!ä× Ñ Ð r   r;   c                ó0   € V ^8„  d   QhR\         R\        /# )r   Úarraysr'   )r
   r   )r)   s   "r   r*   r*   I   s"   € ÷ SHñ SHœUð SH¼
ñ SHr   c                ó€  € \         '       g   \        # . p. pV EFa  p\        \        V4      V R7      pV\        P
                  J d   K0  V\        P                  J dˆ   VP                  P                  R9   d   VP                  V4       Kr  VP                  P                  R8X  d%   \        V4      '       d   VP                  V4       K±  \        RVP                  : R24      hV\        P                  J d&   \        V4      '       d   VP                  V4       EK   \        P                  ! V4      pTP                  P                  R9  d   \        RTP                  : R24      hTP                  T4       EKd  	  V'       g   \        # \         P"                  ! . VOVO5!  #   \         d    \        R4      hi ; i)ay  Get the array API compatible namespace for the arrays xs.

Parameters
----------
*arrays : sequence of array_like
    Arrays used to infer the common namespace.
sparse_ok : bool
    ``True`` if `scipy.sparse` arrays should be accepted where the
    namespace would otherwise be NumPy. Default: ``False``.

Returns
-------
namespace : module
    Common namespace.

Notes
-----
Wrapper around `array_api_compat.array_namespace`.

1. Check for the global switch `SCIPY_ARRAY_API`. If disabled, just
   return array_api_compat.numpy namespace and skip all compliance checks.

2. Check for known-bad array classes.
   The following subclasses are not supported and raise and error:

   - `numpy.ma.MaskedArray`
   - `numpy.matrix`
   - NumPy arrays which do not have a boolean or numerical dtype

3. Coerce array-likes to NumPy arrays and check their dtype.
   Note that non-scalar array-likes can't be mixed with non-NumPy Array
   API objects; e.g.

   - `array_namespace([1, 2])` returns NumPy namespace;
   - `array_namespace(np.asarray([1, 2], [3, 4])` returns NumPy namespace;
   - `array_namespace(cp.asarray([1, 2], [3, 4])` raises an error.
)r;   ÚiufcbÚVzAn argument has dtype `z3`; only boolean and numerical dtypes are supported.zCAn argument is neither array API compatible nor coercible by NumPy.)r   Ú	np_compatr=   r(   r   r    r!   ÚdtypeÚkindÚappendr   r3   r#   r   r0   Ú
asanyarrayr   Úarray_namespace)r;   r?   Únumpy_arraysÚ
api_arraysÚarrayÚarr_infos   $*    r   rH   rH   I   s•  € ÷L ‹?äÐà€LØ€JäˆÜ&¤t¨E£{¸iÔHˆØ”}×)Ñ)Ó)Ùàœ×,Ñ,Ó,Ø�{‰{×Ñ 7Ô*Ø×#Ñ# EÖ*Ø—‘×!Ñ! SÔ(¬\¸%×-@Ò-@ð ×!Ñ! %Ö(äÐ"9¸%¿+¹+¹ð ISð !Só Tð Tð œ×.Ñ.Ó.Ô3CÀE×3JÒ3JØ×Ñ˜e×$ð7ÜŸš eÓ,�ð �{‰{×Ñ wÔ.ÜÐ"9¸%¿+¹+¹ð ISð !Só Tð Tà×Ñ ×&ñ; ÷B ÜÐô ×+Ò+ÐG¨\ÐG¸JÓGÐGøô ô 7Üð !6ó 7ð 7ð7ús   ÄF&Æ&F=c                óV   € V ^8„  d   Qh/ ^ \         9   d   \        \        ,          ;R&   # )r   r   )Ú__conditional_annotations__Ústrr:   )r)   s   "r   r*   r*      s#   € ÷ ñ ÷4 GÒ F””t•Ñ Fò5r   )F)#rN   Ú__doc__ÚenumÚosÚ	functoolsr   Útypesr   Útypingr   r!   r0   Únumpy.typingr   Úscipy._externalr   Ú&scipy._external.array_api_compat.numpyÚ	_externalrC   Ú scipy._external.array_api_compatr   r   Úscipy._lib._sparser	   r
   r   ÚenvironÚgetr   r   ÚEnumr   r=   rH   r*   )rN   s   @r   Ú<module>r_      s­   øðöó Û 	å Ý Ý ã Ý å ,ß :Ó :ß KÝ (÷ Ð ß &Ð &ð !Ÿj™jŸn™nÐ->ÀÓF€Ó Fà�z‰z�~‰~˜n¨eÓ4€ô�D—I‘Iô ñ ˆ3ƒö!ó ð!ðBSH¨e÷ SHñ SHr   