
    Q3j                     "    d Z ddlZddlmZ d Zy)z(Control sparse interface based on config    N)
get_configc                    t         j                  j                  |       s| S t               d   }|dk(  rNt         j                  j	                  |       r- t        t         j                  | j                  dz         |       S | S |dk(  rNt         j                  j	                  |       r| S  t        t         j                  | j                  dz         |       S t        d| d      )z
    Convert to sparse interface as set in config.

    Input can be dense or sparse.
    If sparse, convert to sparse_interface indicated by get_config.
    Otherwise, return X unchanged.
    sparse_interfacesparray_arrayspmatrix_matrixzConfig "sparse_interface" is z.. It should be either "sparray" or "spmatrix".)spsparseissparser   
isspmatrixgetattrformat
ValueError)Xconfig_sparse_interfaces     B/DATA/.local/lib/python3.12/site-packages/sklearn/utils/_sparse.py_align_api_if_sparser      s     99a (l+=> )+99":7299ahh&9:1==	 J	.99"H7wryy!((Y"67::+,C+D E; ;
 	
    )__doc__scipyr
   sklearn._configr   r    r   r   <module>r      s    .
  &
r   