Closed isabelizimm closed 1 month ago
Notes:
import polars as pl from vetiver import VetiverModel, VetiverAPI from vetiver.data import mtcars from sklearn.linear_model import LinearRegression schema = { "mpg": pl.Float64, "cyl": pl.Int32, "disp": pl.Float32, "hp": int, "drat": float, "wt": float, "qsec": float, "vs": bool, "am": bool, "gear": pl.Int32, "carb": int, } mtcars = pl.DataFrame(mtcars, schema=schema) model = LinearRegression().fit(mtcars.drop(columns="mpg"), mtcars["mpg"]) v = VetiverModel(model, model_name = "cars_linear", prototype_data = mtcars.drop(columns="mpg")) VetiverAPI(v).run()
cyl
ValueError: could not convert string to float: 'hello'
polars
closing, potentially looking at pandera at a later point to support this instead
Notes:
cyl
: you getValueError: could not convert string to float: 'hello'
)polars
as a dependency