Open asoplata opened 9 years ago
A much simpler explanation of this issue is: because ~/research/modeling/database
is hardcoded in and used when running simulations on the cluster, if you have new, custom mechanisms and want to use them in a cluster simulation, right now you must add them directly into ~/research/modeling/database
for them to be found by a cluster simulation.
I found a bug in the script below (since it's directly related to the CLI workflow):
If I clone a new dnsim copy etc. to
~/dnsim
, and run cluster sims using this scriptmatlab -r dnsim_batch_example
, it works. BUT when I add a new mechanism to~/dnsim/database
and try to run a sim on the cluster using this new mechanism, it can't find that new mechanism (yes, I have $DNSIM exported correctly in my .bashrc as in https://github.com/jsherfey/dnsim README). In the~/batchdirs/whatever/pbsout/job1.out
it saysIn
dnsim/matlab/functions/get_mechlist.m
it appears that DBPATH, which defaults to~/research/modeling/database
(which of course doesn't necessarily exist!), is, when run on the cluster, not getting a BIOSIMROOT to pull from. DBPATH appears to be the database directory that is ultimately used.This wouldn't be a problem if I could say, set BIOSIMROOT=
~/dnsim
in my run script or startup.m or whatever, but even though BIOSIMROOT is used as a global variable, it appears that it can't just be set anywhere: I tried the above, and I still get this problem. Weirdly, when I run the script over SSH and print out BIOSIMROOT in the main session where i'm calling/running the script, it seems that it's my current directory (unsure if this is always the case), but when I look at the cluster logs, it's empty (as inBIOSIMROOT = []
) in the MATLAB output for the cluster run! During the initial SSH run script, it successfully finds all the files since it's looking in the current working directory, and BIOSIMROOT is set right to it (in this case,~/dnsim
). Is BIOSIMROOT supposed to work as a bash-environment variable? That could get complicated since the cluster isn't necessarily using the same ~/.bashrc as your account's desktop/VM.What works:
load('~/dnsim/database/TC-RE-debug.mat')
in the run script DOES work.dnsim/matlab/functions/get_mechlist.m
and hardcodedly- replacing the~/research/modeling/database
with whatever my new database is, like~/dnsim/database
, or hardcoding in my BIOSIMROOT in there. But this IS hardcoding.script: