r descr_models("mlp", "keras")

Tuning Parameters

defaults <- 
  tibble::tibble(parsnip = c("hidden_units", "penalty", "dropout", "epochs", "activation"),
                 default = c("5L", "0.0", "0.0", "20L", "'softmax'"))

param <-
  mlp() %>% 
  set_engine("keras") %>% 
  make_parameter_list(defaults)

This model has r nrow(param) tuning parameters:

param$item

Translation from parsnip to the original package (regression)

mlp(
  hidden_units = integer(1),
  penalty = double(1),
  dropout = double(1),
  epochs = integer(1),
  activation = character(1)
) %>%  
  set_engine("keras") %>% 
  set_mode("regression") %>% 
  translate()

Translation from parsnip to the original package (classification)

mlp(
  hidden_units = integer(1),
  penalty = double(1),
  dropout = double(1),
  epochs = integer(1),
  activation = character(1)
) %>% 
  set_engine("keras") %>% 
  set_mode("classification") %>% 
  translate()

Preprocessing requirements



Case weights


Saving fitted model objects


Examples

The "Fitting and Predicting with parsnip" article contains examples for mlp() with the "keras" engine.

References



topepo/parsnip documentation built on April 16, 2024, 3:23 a.m.