pyiron / pympipool

up-scale python functions for high performance computing
https://pympipool.readthedocs.io
BSD 3-Clause "New" or "Revised" License
11 stars 3 forks source link

[feature] Dependencies between submitted functions #304

Closed jan-janssen closed 1 month ago

jan-janssen commented 1 month ago

Example:

def add_function(parameter_1, parameter_2):
    return parameter_1 + parameter_2

with Executor(max_cores=1) as exe:
    future_1 = exe.submit(add_function, 1, parameter_2=2)
    future_2 = exe.submit(add_function, 1, parameter_2=future_1)
    print(future_2.result())
jan-janssen commented 1 month ago

This could be just an Executor interface on top of the existing executor. Everything is happening in the same process, so there is no need to submit the dependencies to the queuing system.