Hello,
I have an app to upload csv files for model training. When I tested it locally with small (2 MB) and large (200 MB) files uploaded, there was no issue. But after publishing it to shinyapps.io, I got the following error while uploading the large file:
<!doctype html> <!--[if lt IE 7 ]> <html lang="en" class="no-js ie6"
Code to upload files:
ui:
ui <-shinyUI(fluidPage(
titlePanel("File Input & Model Training"),
sidebarLayout(
sidebarPanel(
fileInput("file","Upload the training file"), # fileinput() function is used to get the file upload contorl option
helpText("Default max. file size is 600 MB"),
tags$hr(),
fileInput("file2","Upload the test file"), # fileinput() function is used to get the file upload contorl option
tags$hr(),
h5(helpText("Select the read.table parameters below")),
checkboxInput(inputId = 'header', label = 'Header', value = FALSE),
checkboxInput(inputId = "stringAsFactors", "stringAsFactors", FALSE),
br(),
radioButtons(inputId = 'sep', label = 'Separator', choices = c(Comma=',',Semicolon=';',Tab='\t', Space=''), selected = ','),
tags$hr(),....
Server:
server<-function(input,output){
data <- reactive({
file1 <- input$file
if(is.null(file1)){return()}
read.table(file=file1$datapath, sep=input$sep, header = input$header, stringsAsFactors = input$stringAsFactors)
})data2 <- reactive({
file3 <- input$file2
if(is.null(file3)){return()}
read.table(file=file3$datapath, sep=input$sep, header = input$header, stringsAsFactors = input$stringAsFactors)
})....
I am using a free account and there was no issue with uploading the smaller files.
Is it because I don't have enough memory to deal with file uploading? Or anything other thing I can do to fix it?
Thank you.