I am trying to publish to rstudio connect server a shiny app, which is a torch-based function. I use R package torch. When I deploy the function to rsconnect, it gives an error logging: "Lantern is not loaded. Please use install_torch()
to install additional dependencies." The server installs torch but not its dependencies "LibLantern". How to configure LibLatern installation in rsconnect?
The content of app.R is
embedding_model = torch::jit_load("./pretrainted_models/immune_metabolism/embedding_model_scripted.pt")
ui <- fluidPage()
server <- function(input, output) {}
shinyApp(ui, server)
The app is deployed at RStudio Connect