Skip to content

sklearn_to_flow raises TypeError on simple flow #636

Closed

Description

@PGijsbers

I found that the following simple example does not convert to an OpenMLFlow with sklearn_to_flow . I do not know why this happens (lists of lists?). The definition of a flow in code is also quite unclear and has a lots of gaps left with "TODO: add documentation".

import openml
from sklearn.preprocessing import OrdinalEncoder
openml.flows.sklearn_to_flow(OrdinalEncoder(categories=[[0,1],[0,1]]))

raises

... traceback ...
  File "D:\repositories/openml-python\openml\flows\sklearn_converter.py", line 534, in _extract_information_from_model
    raise TypeError(msg)
TypeError: Second item of tuple does not match assumptions. Expected OpenMLFlow, got <class 'numpy.float32'>

Activity

  1. PGijsbers commented on Mar 6, 2019

    @PGijsbers
    MemberAuthor

    Fixed via #637.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions