johnmchambers / XRJulia

XR-style Interface to Julia (from "Extending R")
33 stars 2 forks source link

Problem using XRJulia on a sun grid engine (UGER) #17

Open scottlcarter79 opened 6 years ago

scottlcarter79 commented 6 years ago

Hello - I'm having a problem where my jobs using XRJulia crash when I submit them to my compute farm (even though they execute fine interactively).

Log from 1 example R job:


Loading required package: XR

Loading required package: XRJulia

Loading MSACS

Loading MSACS v0 [ALPHA]

Error in .setupMethodsTables(fdef, initialize = TRUE) : 

  trying to get slot "group" from an object of a basic class ("NULL") with no slots

Calls: <Anonymous> ... <Anonymous> -> as -> .getMethodsTable -> .setupMethodsTables

Execution halted

Does this error msg mean anything to you? Since I can't reproduce this in an interactive shell, I have no way to debug w. my limited skills.

Also - is it possible that this is due to my hacky implementation? I have not bothered set things up as a package, I'm just sourcing julia files on startup as follows:


XRJulia::findJulia(test = TRUE)
XRJulia::juliaUsing("Distributions")

XRJulia::juliaSource( paste0(pkg_dir, "/msacs/julia/onesegmulti-model.jl") )
XRJulia::juliaSource( paste0(pkg_dir, "/msacs/julia/MS_HMM_BM_call.jl") )
MS_HMM_BM_call = XRJulia::JuliaFunction(name="MS_HMM_BM_call" )
get_f_1d_grid_approx = XRJulia::JuliaFunction(name="get_f_1d_grid_approx" )
res = try(XRJulia::juliaImport("OneSegMulti"))
if( class(res)=="try-error") XRJulia::juliaImport("OneSegMulti")  ## trying this again works!!! don't ask why.

I never understood why the last import needs to be tried twice.

Thanks for your help!

Scott