rcannood / GillespieSSA2

Gillespie’s Stochastic Simulation Algorithm for Impatient People ⌛
https://rcannood.github.io/GillespieSSA2/
7 stars 0 forks source link

"R session aborted" when calling plos_ssa #11

Open pilopilota opened 2 years ago

pilopilota commented 2 years ago

Dears, I'd like to upgrade GillespieSSA to GillespieSSA2, but something goes wrong.

When I run the following script, reaching plot_ssa causes R session to abort:

library(GillespieSSA2)
sim_name <- "Decaying-Dimerizing Reaction Set"
final_time <- 10
params <- c(c1 = 1.0, c2 = 0.002, c3 = 0.5, c4 = 0.04)
initial_state <- c(s1 = 10000, s2 = 0, s3 = 0)

reactions <- list(
  reaction("c1 * s1",        c(s1 = -1)),
  reaction("c2 * s1 * s1",   c(s1 = -2, s2 = +1)),
  reaction("c3 * s2",        c(s1 = +2, s2 = -1)),
  reaction("c4 * s2",        c(s2 = -1, s3 = +1))
)

set.seed(1)
out <- ssa(
  initial_state = initial_state,
  reactions = reactions,
  params = params,
  final_time = final_time,
  method = ssa_exact(),
  sim_name = sim_name
)

plot_ssa(out)

The same happens when running ?plot_ssa or ?ssa.

This is the output of R.version

platform       x86_64-apple-darwin17.0     
arch           x86_64                      
os             darwin17.0                  
system         x86_64, darwin17.0          
status                                     
major          4                           
minor          0.3                         
year           2020                        
month          10                          
day            10                          
svn rev        79318                       
language       R                           
version.string R version 4.0.3 (2020-10-10)
nickname       Bunny-Wunnies Freak Out

If it can be helpful, I'll be happy to give further information. Thanks for your work! Paolo

pilopilota commented 2 years ago

The same happens now that I updated R to 4.1.2

rcannood commented 1 year ago

Hi Paolo!

Does the problem still persist? Have you tried reinstalling GillespieSSA2 from source?

At the moment, I can't reproduce it from my end. On the CRAN package checks, everything seems to be ok for Mac OS systems. Also the GitHub Actions Mac OS X runner seems to be working fine.

What kind of a computer do you have?