Displaying 4 results from an estimated 4 matches for "dectectcores".
Did you mean:
detectcores
2015 Mar 25
2
nested parallel workers
...) : error reading from connection
This example is from Martin and may be a different problem.
~/tmp >cat test1.R
## like mclapply
## should run 'forever' but terminates semi-randomly
library(parallel)
children <- parallel:::children
while (TRUE) {
n <- 8 ## n == dectectCores()
jobs <- lapply(seq_len(n), function(i) mcparallel(Sys.sleep(20)))
mccollect(children(jobs), FALSE)
parallel:::mckill(children(jobs), tools::SIGTERM)
leni <- length(mccollect(children(jobs)))
message("leni: ", leni)
}
~/tmp >R-dev --vanilla --slave -f t...
2015 Mar 30
2
nested parallel workers
...ifferent problem.
>>
>> ~/tmp >cat test1.R
>> ## like mclapply
>> ## should run 'forever' but terminates semi-randomly
>> library(parallel)
>> children <- parallel:::children
>>
>> while (TRUE) {
>> n <- 8 ## n == dectectCores()
>> jobs <- lapply(seq_len(n), function(i) mcparallel(Sys.sleep(20)))
>> mccollect(children(jobs), FALSE)
>> parallel:::mckill(children(jobs), tools::SIGTERM)
>> leni <- length(mccollect(children(jobs)))
>> message("leni: ", leni)
&...
2015 Mar 26
0
nested parallel workers
...ample is from Martin and may be a different problem.
>
> ~/tmp >cat test1.R
> ## like mclapply
> ## should run 'forever' but terminates semi-randomly
> library(parallel)
> children <- parallel:::children
>
> while (TRUE) {
> n <- 8 ## n == dectectCores()
> jobs <- lapply(seq_len(n), function(i) mcparallel(Sys.sleep(20)))
> mccollect(children(jobs), FALSE)
> parallel:::mckill(children(jobs), tools::SIGTERM)
> leni <- length(mccollect(children(jobs)))
> message("leni: ", leni)
> }
>
> ~/tmp &g...
2015 Mar 30
0
nested parallel workers
...gt;> ~/tmp >cat test1.R
>>> ## like mclapply
>>> ## should run 'forever' but terminates semi-randomly
>>> library(parallel)
>>> children <- parallel:::children
>>>
>>> while (TRUE) {
>>> n <- 8 ## n == dectectCores()
>>> jobs <- lapply(seq_len(n), function(i) mcparallel(Sys.sleep(20)))
>>> mccollect(children(jobs), FALSE)
>>> parallel:::mckill(children(jobs), tools::SIGTERM)
>>> leni <- length(mccollect(children(jobs)))
>>> message("leni:...