nipype / pydra

Pydra Dataflow Engine
https://nipype.github.io/pydra/
Other
120 stars 59 forks source link

`FuntionTask` with `splitter` on Windows #652

Open tanweihou opened 1 year ago

tanweihou commented 1 year ago

What version of Pydra are you using? 0.22 on Windows 10 What were you trying to do/What did you expect will happen? Tried the example on pydra-tutorial/notebooks/3_intro_functiontask_state.md What actually happened? Failed with examples of Task with States

Here's the error message

RuntimeError:
        An attempt has been made to start a new process before the
        current process has finished its bootstrapping phase.

        This probably means that you are not using fork to start your
        child processes and you have forgotten to use the proper idiom
        in the main module:

            if __name__ == '__main__':
                freeze_support()
                ...

        The "freeze_support()" line can be omitted if the program
        is not going to be frozen to produce an executable.
concurrent.futures.process.BrokenProcessPool: A process in the process pool was terminated abruptly while 
the future was running or pending.

Is it related to the issue mentioned in #622 ? I tried above example and it failed on my Windows laptop, but ran fine on my Linux server. Thanks.