lkerr / groundfish-MSE

Development of Robust Management Strategies for Northeast Groundfish Fisheries in a Changing Climate
MIT License
4 stars 2 forks source link

ASAP3.EXE error #198

Closed mle2718 closed 2 years ago

mle2718 commented 2 years ago

I'm getting this error when I try to source "runSim.R"

ASAP3.EXE should be loaded in a directory EXE in the parent
directory of groundfish-MSE -- i.e., you need an EXE
directory in the same directory as Rlib and EXE must contain
ASAP3.EXE

I'm using a Linux Server, so the prospect of getting an ASAP.EXE installed are slim to none.

The code in "runSim.R" just chugs past the error message if I "run" it and the MPROC line I have is CAA, so I don't think this causes any problems for now.

Not sure who to flag on this issue.

mle2718 commented 2 years ago

maybe this:


if (platform == 'Linux'){
  if(!file.exists('../EXE/ASAP3.EXE')){
    stop(paste('ASAP3.EXE should be loaded in a directory EXE in the parent',
               'directory of groundfish-MSE -- i.e., you need an EXE',
               'directory in the same directory as Rlib and EXE must contain',
               'ASAP3.EXE', sep='\n'))
  }
  rand <- sample(1:10000, 1)
  tempwd <- getwd()
  rundir <- paste(tempwd, "/assessment/ASAP/Run", '_', rand, sep = "")
  dir.create(path = rundir)
  from.path <- paste('../EXE/ASAP3.EXE', sep = "")
  to.path   <- paste(rundir, sep= "")
  file.copy(from = from.path, to = to.path)

}

can be changed from stop() to warning() ?

lkerr commented 2 years ago

Yes, we can modify that to a warning. You are not running ASAP, but the statistical catch at age model written in TMB so you should be fine.

mle2718 commented 2 years ago

This whole if statement is a little weird: Do you have a way to run an .EXE on a linux platform?

samtruesdell commented 2 years ago

Hey Min-Yang -- When we were running this on the UMASS server we had to load the "wine" module to run ASAP.exe if that helps.

https://github.com/lkerr/groundfish-MSE/blob/48e241220fa61b2a0df4b3ecdd364dbb7649189f/functions/assessment/get_ASAP.R#L130

mle2718 commented 2 years ago

Thanks. It's unlikely that I'll be allowed to install wine on the NEFSC servers.

lkerr commented 2 years ago

Do you need capacity to run ASAP? I thought we had moved away from running ASAP in the econ model, but correct me if I am wrong, and were running the simpler SCAA model. Also, ASAP is the the most frequently used assessment model at the NEFSC so I would be surprised if there isn't a way to run this on the NEFSC server-I can reach out to Chris Legault to see what he suggests for getting this running if needed.

mle2718 commented 2 years ago

Do you need capacity to run ASAP? I thought we had moved away from running ASAP in the econ model, but correct me if I am wrong, and were running the simpler SCAA model. Also, ASAP is the the most frequently used assessment model at the NEFSC so I would be surprised if there isn't a way to run this on the NEFSC server-I can reach out to Chris Legault to see what he suggests for getting this running if needed.

I don't need to run ASAP. At least, I don't think I do -- unless someone makes me.

I'm comfortable closing this now that #199 has been merged into main.