Closed Kucharssim closed 3 years ago
Thanks for the really helpful analysis of the issue!
There have been some recent issues around upgrading package versions and having to install Prophet from source. For future reference with this class of issues, @seanjtaylor had some package version issues and found devtools::clean_dll()
was helpful, and #1628 provided another possible workaround. More broadly, I'm not really sure what the broader solution is. We don't build the Mac OS binary ourselves, CRAN builds it. There's probably something we can do to avoid this issue besides requiring a source install, but we'll have to figure out still what that is.
Hello,
tldr; tip for users of prophet on Catalina who cannot run
prophet
but theirrstan
is working: tryinstall.packages("prophet", type = "source")
I am having issues with running prophet on Catalina - they are related to issues like https://github.com/facebook/prophet/issues/300, https://github.com/facebook/prophet/issues/1554, https://github.com/facebook/prophet/issues/1325, etc. Basically all the issues that seem somehow related to the recent problems of MacOS Catalina with RStan. However, I think I found some additional info (which I have not seen in the related issues yet). I hope it's useful.
Problem
The MAP estimation gives me
Error in sampler$call_sampler(c(args, dotlist)): empty_nested() must be true before calling recover_memory()
, whereas MCMC gives meError in matrix(m$params[[name]], nrow = n.iteration): 'data' must be of a vector type, was 'NULL'
.If I run:
and proceed until I get to fitting the model, I got the infamous
Error in sampler$call_sampler(c(args, dotlist)) : c++ exception (unknown reason)
.Some additional info
I had problems with
rstan
previously, but this has been solved on my computer for a while (and the test program at https://github.com/stan-dev/rstan/wiki/Catalina-problems works), so it was weird to see these issues.So I exported the object that is used as the
data
argument insidefit.prophet()
(the code to recreate the object is attached - create_stan_data.zip) and try to fit the model directly withrstan
:only to get
c++ exception (unknown reason)
again.But again, my
rstan
is currently working fine with my models, not experiencing these exceptions issues, so I tried to recompile the model and run it:which worked just fine. So this lead me to believe there is something in the precompiled prophet model that causes these issues.
Solution and suggestion
Reinstalling
prophet
withinstall.packages("prophet", type = "source")
solves the problem on my computer.Now I am not sure whether this is stupid or not, but would it make sense to ensure that the prophet package is shipped with a freshly precompiled model? Perhaps that would solve this problem for people who do not have issues with
rstan
/Rcpp
, butprophet
does not work them?sessionInfo