Skip to content

Can progressr handlers receive partial results from future_lapply? #121

Answered by scottkosty
scottkosty asked this question in Q&A
Discussion options

You must be logged in to vote

The first "step" can be done as already done.

Do you mean that I should keep the code as is in #121 (reply in thread) where I manually split the chunks, and have an outer for loop (that is not parallelized) ? Or are you referring to your code, in the part if (i %% hook_freq == 0) { ?

Since you're doing it in parallel, the different parallel processes must not write to the same file, because then it is likely that they overwrite each other either completely or partially. The best is probably to write to separate files and then merge them in the second "step".

This makes me think you're talking about your code that uses if (i %% hook_freq == 0) { since I indeed understand that would cau…

Replies: 3 comments 4 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@scottkosty
Comment options

@HenrikBengtsson
Comment options

Comment options

You must be logged in to vote
2 replies
@HenrikBengtsson
Comment options

@scottkosty
Comment options

Answer selected by scottkosty
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants