U
    Ùf™  ã                   @   sJ   d dl Zd dlZd dlmZmZ ej dejefej	efg¡dd„ ƒZ
dS )é    N)ÚWeightVector32ÚWeightVector64zdtype, WeightVectorc                 C   sj   t j d¡ | ¡}t j d¡ | ¡}|||ƒ}t  |j¡jt  | ¡ksJt‚t  |j¡jt  | ¡ksft‚dS )z0Check the `dtype` consistency of `WeightVector`.éd   N)	ÚnpÚrandomZrandZastypeZasarrayÚwÚdtypeÚAssertionErrorZaw)r   ZWeightVectorÚweightsZaverage_weightsZweight_vector© r   úM/tmp/pip-target-lpfmz8o1/lib/python/sklearn/utils/tests/test_weight_vector.pyÚtest_type_invariance
   s
    	
r   )Únumpyr   ZpytestZsklearn.utils._weight_vectorr   r   ÚmarkZparametrizeZfloat32Zfloat64r   r   r   r   r   Ú<module>   s   þþ