Help building a Custom Python Model with kmodes

Juan Esteban
Juan Esteban Registered, Frontrunner 2022 Participant Posts: 4 ✭✭✭✭✭

We are trying to run k-prototypes as a Custom Python Model, the model comes from the library kmodes.

When running the Custom Python Model, the following mistake appears:

<type 'exceptions.ImportError'>: No module named kmodes.kmodes.

We would like to see the same metrics as other clustering models.

Any help would be appreciated.

Answers

  • Alexandru
    Alexandru Dataiker, Dataiku DSS Core Designer, Dataiku DSS ML Practitioner, Dataiku DSS Adv Designer, Registered Posts: 1,399 Dataiker

    Hi,

    The error suggests either kmodes is not installed in the code environment used.

    Or a naming conflict as suggested in this thread.

  • Juan Esteban
    Juan Esteban Registered, Frontrunner 2022 Participant Posts: 4 ✭✭✭✭✭

    Thank you @AlexT
    , we solved it by working in a Python Environment, not the Lab option

  • CoreyS
    CoreyS Dataiker Alumni, Dataiku DSS Core Designer, Dataiku DSS Core Concepts, Registered Posts: 1,149 ✭✭✭✭✭✭✭✭✭

    Thank you for sharing your solution with the rest of the community @juan_delacalle
    !

Setup Info
    Tags
      Help me…