Is there an easy way to send a function that is already defined to all worker processes? E.g.:

```
julia> f(x) = x + 1
julia> @everywhere f = $f
```

Is there an easy way to send a function that is already defined to all worker processes? E.g.:

```
julia> f(x) = x + 1
julia> @everywhere f = $f
```

2 Likes

Check out ParallelDataTransfer.jl

Sorry, but I cannot figure it out.

```
addprocs(2)
f(x) = 2x
sendto(workers(), f = f)
@everywhere print(f(3))
```

still complains that `f`

is not defined.