IQVIA-ML / TreeParzen.jl

TreeParzen.jl, a pure Julia hyperparameter optimiser with MLJ integration
Other
35 stars 5 forks source link

Use MLJTuning.jl for ranges #100

Open MilesCranmer opened 1 year ago

MilesCranmer commented 1 year ago

It would be really nice if MLJTuning.jl's ranges worked out of the box: https://alan-turing-institute.github.io/MLJ.jl/dev/tuning_models/. Right now it looks like one needs to manually translate the ranges from, e.g.,

range(model, :x, lower=-5, upper=5)

to

Dict(:x => HP.Uniform(:x, -5., 5.))

But since all of the other tuning packages use the first API it would be better if one could just switch between the other tuning packages and this one!

Cheers, Miles

kainkad commented 4 months ago

hi @MilesCranmer thanks for raising the issue. I looked at what it takes to implement the MLJTuning ranges API but there seem to be several limitations for implementing this method in MLJTreeParzen:

Even if considering those limitations, we would probably be looking at some sort of error prone expression parsing involved to read those fields from the range() syntax and pass onto tree-parzen structure.

I'm not closing the issue as it's something to keep in view but given the above it doesn't seem feasible.