ropensci / av

Working with Video in R
https://docs.ropensci.org/av
Other
92 stars 10 forks source link

Memory Bleed? #43

Open ColinChisholm opened 2 years ago

ColinChisholm commented 2 years ago

Thanks for this great package.

I am currently using it to extract the audio from ~1000 MP4 files. However, I suspect there may be some sort of memory-leak in av_audio_convert. With each subsequent video converted, the memory usage in my R session continues to climb until machine resources are maxed out.

for (i in 1:length(l)) {
  tryCatch({  
    av_audio_convert(l[i],        ## input
                     a_names[i])  ## output
  }, error=function(e){cat("ERROR :",conditionMessage(e), "\n")}
  )

Note: I attempted this using windows 10, and via linux (in a docker container). Both ran out of memory.