# Is @distributed using local threads to further distribute?

**URL:** https://discourse.julialang.org/t/is-distributed-using-local-threads-to-further-distribute/111130
**Category:** Performance
**Tags:** multithreading, distributed
**Created:** [March 4, 2024, 12:33pm UTC](https://discourse.julialang.org/t/is-distributed-using-local-threads-to-further-distribute/111130 "2024-03-04T12:33:27Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![schlichtanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/schlichtanders/32/32145_2.png) [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)
#### Post date: [March 4, 2024, 12:33pm UTC](https://discourse.julialang.org/t/is-distributed-using-local-threads-to-further-distribute/111130/1 "2024-03-04T12:33:27Z")

</div>

I am looking for a `@distributed reducer for ...` version which simply parallelizes the function as large as possible.

I.e. using both available machines and available threads. Is `@distributed` already doing so?

if not, is there a package which supports this? (I looked into the Transducer ecosystem, but there both are also separated).

---

<div class="post-metadata">

### Author: ![carstenbauer](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/carstenbauer/32/4981_2.png) [@carstenbauer](https://discourse.julialang.org/u/carstenbauer)
#### Post date: [March 4, 2024, 3:28pm UTC](https://discourse.julialang.org/t/is-distributed-using-local-threads-to-further-distribute/111130/2 "2024-03-04T15:28:20Z")

</div>

Dagger.jl is your best (and only?) bet.

---

<div class="post-metadata">

### Author: ![schlichtanders](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/schlichtanders/32/32145_2.png) [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)
#### Post date: [March 4, 2024, 3:39pm UTC](https://discourse.julialang.org/t/is-distributed-using-local-threads-to-further-distribute/111130/3 "2024-03-04T15:39:05Z")

</div>

I thought so…

has someone build a @distributed like wrapper around `Dagger.jl`?  
I did a little research and it is not super straighforward. The best workaround is to take DTables.jl and do a reduce on it, but it is not exactly like distributed. I guess it would be nice to have such a functionality inside Dagger.jl itself.
