How do you run deep learning models with parsnip?

271 views Asked by At

I have explored the models offered with the R parsnip package listed at https://www.tidymodels.org/find/parsnip/ but I cannot find how to execute a generic deep learning model (by which I mean a deep-layered neural network). The closest I can find are mlp and bag_mlp.

By contrast, I know that the caret package supports at least two deep learning packages: https://topepo.github.io/caret/available-models.html.

Does parsnip not offer deep learning (yet) or am I missing something?

1

There are 1 answers

0
topepo On BEST ANSWER

We don't have it via parsnip (at least not yet) since it is difficult to write a static set of tuning parameters for a network of arbitrary size and architecture.

If you want a tidy way to fit basic neural networks with multiple simple layers, the brulee package is helpful. brulee_mlp() can fit those (via torch) and has a recipes interface for easier preprocessing and feature engineering.

Also, though not part of tidymodels, there is the excellent luz package by Daniel Falbel. It's a nice interface to general deep learning models (also via torch).