# Seriously incorrect computation in Juno REPL?

**URL:** https://discourse.julialang.org/t/seriously-incorrect-computation-in-juno-repl/33050
**Category:** Juno
**Created:** [January 7, 2020, 5:45am UTC](https://discourse.julialang.org/t/seriously-incorrect-computation-in-juno-repl/33050 "2020-01-07T05:45:21Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![jaynick](https://avatars.discourse-cdn.com/v4/letter/j/71c47a/32.png) [@jaynick](https://discourse.julialang.org/u/jaynick)
#### Post date: [January 7, 2020, 5:45am UTC](https://discourse.julialang.org/t/seriously-incorrect-computation-in-juno-repl/33050/1 "2020-01-07T05:45:21Z")

</div>

See this  
[https://discourse.julialang.org/t/alarming-incorrect-computation-in-flux-juno/33017](https://discourse.julialang.org/t/alarming-incorrect-computation-in-flux-juno/33017)  
But I am flagging it here because it seems to be a problem in Juno, and is very serious. Someone here should have a look as well.

The results of this simple computation (below) should be deterministic,  
and seem to be outside of Juno, but in the Juno REPL there is a big error (far beyond flowing point numerics).

The simplest way to reporduce it:

```julia
    using Flux
    batchsize = 2
    ii = randn(Float32, 5,4,3,batchsize)
    ll = Conv((3,3), 3=>3)
    maximum(ll(ii)-ll(ii))

```

It is just creating a random matrix ii, then passing it through a small convolution, twice, and looking at the maximum difference in results. Which should be zero, but sometimes is a huge value like 5.

Repeat the last line about 10 times to see the problem.

This occurs in an Atom 1.42 installed two days ago, Julia1.3.1+Flux 0.9,

but does not happen when running the same Julia in the terminal, as described in the linked post.

---

<div class="post-metadata">

### Author: ![jaynick](https://avatars.discourse-cdn.com/v4/letter/j/71c47a/32.png) [@jaynick](https://discourse.julialang.org/u/jaynick)
#### Post date: [January 7, 2020, 5:51am UTC](https://discourse.julialang.org/t/seriously-incorrect-computation-in-juno-repl/33050/2 "2020-01-07T05:51:29Z")

</div>

OK, I may be wrong. Though it does not happen in the terminal, someone said it did happen for them.

So maybe not a Juno problem!

---

<div class="post-metadata">

### Author: ![kristoffer.carlsson](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kristoffer.carlsson/32/22_2.png) [@kristoffer.carlsson](https://discourse.julialang.org/u/kristoffer.carlsson)
#### Post date: [January 7, 2020, 8:21am UTC](https://discourse.julialang.org/t/seriously-incorrect-computation-in-juno-repl/33050/3 "2020-01-07T08:21:52Z")

</div>

It is a thread safety issue: [Conv layers with CPU backend randomly mixes up batch dimensions · Issue #982 · FluxML/Flux.jl · GitHub](https://github.com/FluxML/Flux.jl/issues/982#issuecomment-571471224)
