SwissDataScienceCenter / mlschema-model-converters

Apache License 2.0
3 stars 0 forks source link

Explicitly test Pipelines #3

Open vigsterkr opened 4 years ago

chrisbarber commented 4 years ago

Hm, from the pipeline example in the docs, they use SelectKBest feature selection, which takes an arbitrary callable score function. When calling get_params on the overall Pipeline, it returns this callable in its original form. This complicates trying to make the mls be a nice declarative set of parameters which can be used to reconstruct the model with sklearn.

Could return some info about the callable. For example, if they are just passing in f_regression from sklearn as in the example, it would be very messy but sufficient to just spit out the source line from inspect; something like:

def f_regression(X, y, center=True):\n

@vigsterkr any thoughts?