[Python] Unable to install KMedoids within VSCode and Collab [duplicate]

Discussão em 'Python' iniciado por Stack, Junho 3, 2025.

  1. Stack

    Stack Membro Participativo

    I am getting the below error within my Collab notebook when I try to import KMedoids:


    from sklearn_extra.cluster import KMedoids​

    Error:

    ---------------------------------------------------------------------------

    ValueError Traceback (most recent call last)

    <ipython-input-20-036ed451da4d> in <cell line: 0>()
    17 from sklearn.mixture import GaussianMixture
    18
    ---> 19 from sklearn_extra.cluster import KMedoids
    20
    21 import warnings

    2 frames

    /usr/local/lib/python3.11/dist-packages/sklearn_extra/kernel_approximation/_fastfood.py in <module>
    9 from sklearn.utils import check_array, check_random_state
    10
    ---> 11 from ..utils._cyfht import fht2 as cyfht
    12
    13

    sklearn_extra/utils/_cyfht.pyx in init sklearn_extra.utils._cyfht()

    ValueError: numpy.dtype size changed, may indicate binary incompatibility. Expected 96 from C header, got 88 from PyObject


    I was facing this issue within VSCode so I switched to Google Collab. But I am seeing these issues there as well. Can anybody help? Thanks.

    Continue reading...

Compartilhe esta Página