Closed elgabbas closed 2 years ago
Can you test this code? Is posible that you need the cl
object, with follow:
library(future)
workers <-rep("localhost",4)
cl <- makeClusterPSOCK(workers, revtunnel=TRUE, outfile="")
# starting worker pid=134xx on localhost:11xxx at 13:46:34.292
# starting worker pid=134xx on localhost:11xxx at 13:46:34.580
# starting worker pid=134xx on localhost:11xxx at 13:46:34.817
# starting worker pid=134xx on localhost:11xxx at 13:46:35.050
plan <- plan(list(future::tweak(cluster, workers=workers), multisession))
plan
If you dont't solve send us the short example for replicate and help you.
Erick
Hello,
Sometimes, I also receive this error
Fatal error: couldn't allocate memory for pointer stack Fatal error: couldn't allocate memory for pointer stack Error: cannot allocate vector of size 9 Kb
caught segfault address (nil), cause 'memory not mapped' An irrecoverable exception occurred. R is aborting now ...
caught segfault address (nil), cause 'memory not mapped' An irrecoverable exception occurred. R is aborting now ...
caught segfault address (nil), cause 'memory not mapped' An irrecoverable exception occurred. R is aborting now ...
caught segfault address (nil), cause 'memory not mapped' An irrecoverable exception occurred. R is aborting now ...
caught segfault address (nil), cause 'memory not mapped' Error: memory exhausted (limit reached?) Execution halted Error: memory exhausted (limit reached?) Execution halted Warning message: system call failed: Cannot allocate memory
caught segfault address 0x5555559b9568, cause 'invalid permissions' An irrecoverable exception occurred. R is aborting now ...
Thanks, Ahmed
Thanks @orozcoae89 for your reply. Here is the results of the script you provided.
workers <-rep("localhost",4)
cl <- makeClusterPSOCK(workers, revtunnel=TRUE, outfile="")
starting worker pid=175624 on localhost:11798 at 13:59:27.898 starting worker pid=175627 on localhost:11798 at 13:59:27.898 starting worker pid=175625 on localhost:11798 at 13:59:27.899 starting worker pid=175626 on localhost:11798 at 13:59:27.907
starting worker pid=134xx on localhost:11xxx at 13:46:34.292
starting worker pid=134xx on localhost:11xxx at 13:46:34.580
starting worker pid=134xx on localhost:11xxx at 13:46:34.817
starting worker pid=134xx on localhost:11xxx at 13:46:35.050
plan <- plan(list(future::tweak(cluster, workers=workers), multisession))
plan
List of future strategies:
- sequential:
- args: function (..., envir = parent.frame())
- tweaked: FALSE
- call: NULL
I will implement my code then and see if it works.
Cheers, Ahmed
This error is common when you don't have set the connections with remote machines. Can you give us more details about your code for help you?
Erick
After running my script, I receive similar error:
Error: Problem with
mutate()
columnPreds
. ℹPreds = future_map(...)
. ✖ ClusterFuture () failed to call gassign() on cluster RichSOCKnode #3 (PID 175879 on ‘localhost’). The reason reported was ‘error writing to connection’. Post-mortem diagnostic: The total size of the 15 globals exported is 72.55 MiB. The three largest globals are ‘...furrr_chunk_args’ (71.76 MiB of class ‘list’), ‘Models_WS’ (374.44 KiB of class ‘list’) and ‘predictMaxEnt’ (331.60 KiB of class ‘function’)
My code is simple. I am using future_map
function from the furrr
package to mutate
a new column. However, the data is huge and consists of ~1M observations. Nevertheless, the same script worked nicely using the RStudio server on the HPC (same specifications), but now I need to use the same script over different datasets and therefore need to batch the jobs using different R runs .
Cheers, Ahmed
Well, I think that you could improve your code, because this error is that you have a excedence in the globals fixed by default. More details: https://www.rdocumentation.org/packages/future/versions/1.24.0/topics/future.options
. Prove this solution:
options(future.globals.maxSize = ??)
Hello,
I am trying to use the
furrr
package, but I think I am having a problem related to the use offuture
.First, when I prepare to run the script in parallel using the following command, I receive these warnings. I am unsure if I should ignore them or there is an issue I need to solve.
plan(multisession, workers = 20)
Then, when I use
map
function from thefurrr
package, I receive the following error:Please note that I am running this code on an HPC computer (CentOS Linux 7 ), with a total of 110 GB ram and 36 nodes. I used conda to install R (v 4.1.2). The same code worked nicely on different R installations but failed on this computer. Here is the results of the session info:
sessionInfo()
The same issue occurred when using other strategies (multisession, multicore, cluster). I do not think this is due to a memory issue because the same code runs well on the same node specifications, but using an older version of R (not installed via conda). Is there something related to using conda?
Any suggestions?
Thanks in advance, Ahmed