# \donttest{
model <- ggml_model_sequential() |>
ggml_layer_dense(64, activation = "relu") |>
ggml_layer_dense(10, activation = "softmax")
# Freeze all layers
model <- ggml_freeze_weights(model)
# Freeze only the first layer
model <- ggml_freeze_weights(model, from = 1, to = 1)
# }
Run the code above in your browser using DataLab