# Latest

**URL:** https://discourse.julialang.org/latest.md?page=1814

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

**Page:** 1815

---

## [Compress many files](https://discourse.julialang.org/t/compress-many-files/35250)

<div class="topic-metadata">

**Author:** [@programista](https://discourse.julialang.org/u/programista)\
**Replies:** 3\
**Last updated:** [February 27, 2020, 8:58pm UTC](https://discourse.julialang.org/t/compress-many-files/35250 "2020-02-27T20:58:01Z")

</div>

How to Compress many files (no data) in Julia ? Specialy text files, if I saved txt data to jld or hdf5 was many time bigger then txt. Today I hvae lot of files txt and I must compress it and still using it some time. …

---

## [Warning: You are using Gtk on Windows which is currently not recommended](https://discourse.julialang.org/t/warning-you-are-using-gtk-on-windows-which-is-currently-not-recommended/34967)

<div class="topic-metadata">

**Author:** [@programista](https://discourse.julialang.org/u/programista)\
**Replies:** 7\
**Last updated:** [February 27, 2020, 9:45pm UTC](https://discourse.julialang.org/t/warning-you-are-using-gtk-on-windows-which-is-currently-not-recommended/34967 "2020-02-27T21:45:23Z")

</div>

What to do ? After adding Gtk is still the same Warning. Win 7 , I preparde special USER JuliaPro\_v1.3.1-1 for this instalation JPRO. In Atom was added uber-juno (@v1.3) pkg\> st Status \`C:\\Users\\JuliaPro\_v1.3.1-1\\…

---

## [Faster Bernoulli sampling](https://discourse.julialang.org/t/faster-bernoulli-sampling/35209)

<div class="topic-metadata">

**Author:** [@Adriel](https://discourse.julialang.org/u/Adriel)\
**Replies:** 7\
**Last updated:** [February 27, 2020, 9:31pm UTC](https://discourse.julialang.org/t/faster-bernoulli-sampling/35209 "2020-02-27T21:31:48Z")

</div>

I have a need for huge numbers of Bernoulli samples, so I tried to do better than the simple implementation in Distributions.jl (which just does rand() \< p), using a binary arithmetic decoder. Some timing results. juli…

---

## [Lightweight tasks, Julia vs Elixir/OTP](https://discourse.julialang.org/t/lightweight-tasks-julia-vs-elixir-otp/35082)

<div class="topic-metadata">

**Author:** [@pbayer](https://discourse.julialang.org/u/pbayer)\
**Replies:** 21\
**Last updated:** [February 27, 2020, 6:37pm UTC](https://discourse.julialang.org/t/lightweight-tasks-julia-vs-elixir-otp/35082 "2020-02-27T18:37:37Z")

</div>

I wanted to know, whether Julia can cope with Elixir/OTP lightweight tasks and made a comparison for chaining a lot of them following the example from “Programming in Elixir”. My Julia code is: function counter(next::…

---

## ["non-matching indices" error using TensorOperations](https://discourse.julialang.org/t/non-matching-indices-error-using-tensoroperations/35136)

<div class="topic-metadata">

**Author:** [@ssfrr](https://discourse.julialang.org/u/ssfrr)\
**Replies:** 7\
**Last updated:** [February 27, 2020, 8:11pm UTC](https://discourse.julialang.org/t/non-matching-indices-error-using-tensoroperations/35136 "2020-02-27T20:11:58Z")

</div>

I’m trying to simplify some code that does a lot of dropdims and mapslices, so I’m looking at some packages that do Einstein notation. I tried out Einsum.jl which seems pretty intuitive, but I also wanted to try out Tens…

---

## [Problem installing ImageCore in Julia 1.4.0 on Windows (Pkg bug?)](https://discourse.julialang.org/t/problem-installing-imagecore-in-julia-1-4-0-on-windows-pkg-bug/35236)

<div class="topic-metadata">

**Author:** [@cirocavani](https://discourse.julialang.org/u/cirocavani)\
**Replies:** 4\
**Last updated:** [February 27, 2020, 7:03pm UTC](https://discourse.julialang.org/t/problem-installing-imagecore-in-julia-1-4-0-on-windows-pkg-bug/35236 "2020-02-27T19:03:12Z")

</div>

Hi folks, I am trying to install ImageCore in Julia 1.4.0-rc2 on Windows 10. When I try add the first time, the result is an IOError: symlink: no such file or directory (ENOENT). When I try add the second time, it pass…

---

## [Optimization giving wildly different answers depending on box constraints](https://discourse.julialang.org/t/optimization-giving-wildly-different-answers-depending-on-box-constraints/35244)

<div class="topic-metadata">

**Author:** [@lesshaste](https://discourse.julialang.org/u/lesshaste)\
**Replies:** 2\
**Last updated:** [February 27, 2020, 5:54pm UTC](https://discourse.julialang.org/t/optimization-giving-wildly-different-answers-depending-on-box-constraints/35244 "2020-02-27T17:54:08Z")

</div>

I am trying to fit a skew normal distribution to some data. I only have data from the left tail. My code is as follow: using Optim using Distributions using QuadGK unction T(h, a) return 1/(2\*π) \* quadgk(x -\> exp(-(…

---

## [Request for testing: CUDA from BinaryBuilder](https://discourse.julialang.org/t/request-for-testing-cuda-from-binarybuilder/34856)

<div class="topic-metadata">

**Author:** [@maleadt](https://discourse.julialang.org/u/maleadt)\
**Replies:** 19\
**Last updated:** [February 27, 2020, 4:21pm UTC](https://discourse.julialang.org/t/request-for-testing-cuda-from-binarybuilder/34856 "2020-02-27T16:21:55Z")

</div>

Hi all, We are looking into using BinaryBuilder for installing CUDA when you use the Julia/CUDA stack, i.e. CuArrays or CUDAnative. The support for this has been merged to the master branches of the respective repositor…

---

## [Cassette hooks only for own module functions](https://discourse.julialang.org/t/cassette-hooks-only-for-own-module-functions/35239)

<div class="topic-metadata">

**Author:** [@Wikunia](https://discourse.julialang.org/u/Wikunia)\
**Replies:** 0\
**Last updated:** [February 27, 2020, 3:47pm UTC](https://discourse.julialang.org/t/cassette-hooks-only-for-own-module-functions/35239 "2020-02-27T15:47:56Z")

</div>

Is there a way to specify Cassette in such a way that there are only prehooks and posthooks for each function of my own module? Would like to get a high level stack trace with my function names, arguments and the return. …

---

## [Lazy countmap](https://discourse.julialang.org/t/lazy-countmap/35220)

<div class="topic-metadata">

**Author:** [@harven](https://discourse.julialang.org/u/harven)\
**Replies:** 3\
**Last updated:** [February 27, 2020, 3:27pm UTC](https://discourse.julialang.org/t/lazy-countmap/35220 "2020-02-27T15:27:27Z")

</div>

I am triaging elements in a list according to their values by some function f and compute the number of elements for each possible value as follows. countmap(map(f, list)) This returns a dict whose keys are unique va…

---

## [Julia Workshop: February 2020, Oulu, Finland](https://discourse.julialang.org/t/julia-workshop-february-2020-oulu-finland/35165)

<div class="topic-metadata">

**Author:** [@vjhaanpaa](https://discourse.julialang.org/u/vjhaanpaa)\
**Replies:** 3\
**Last updated:** [February 27, 2020, 3:22pm UTC](https://discourse.julialang.org/t/julia-workshop-february-2020-oulu-finland/35165 "2020-02-27T15:22:18Z")

</div>

Hi everybody, We recently hosted a three-day Julia workshop at the University of Oulu with @carstenbauer from the University of Cologne as the guest speaker. The workshop was based on another workshop that Carsten had g…

---

## [Registrator's usage instruction link is 404](https://discourse.julialang.org/t/registrators-usage-instruction-link-is-404/35231)

<div class="topic-metadata">

**Author:** [@paalon](https://discourse.julialang.org/u/paalon)\
**Replies:** 1\
**Last updated:** [February 27, 2020, 3:14pm UTC](https://discourse.julialang.org/t/registrators-usage-instruction-link-is-404/35231 "2020-02-27T15:14:26Z")

</div>

I am going to register my package to General but the Registrator’s instruction page is not exist. Is there a text what I should read?

---

## [Strange error when using Cbc for MILP =\> "This application has requested the Runtime to terminate it in an unusual way"](https://discourse.julialang.org/t/strange-error-when-using-cbc-for-milp-this-application-has-requested-the-runtime-to-terminate-it-in-an-unusual-way/3478)

<div class="topic-metadata">

**Author:** [@Jonathan\_Droxler](https://discourse.julialang.org/u/Jonathan_Droxler)\
**Replies:** 2\
**Last updated:** [February 27, 2020, 2:11pm UTC](https://discourse.julialang.org/t/strange-error-when-using-cbc-for-milp-this-application-has-requested-the-runtime-to-terminate-it-in-an-unusual-way/3478 "2020-02-27T14:11:04Z")

</div>

Dear all, Have got an error when using the Cbc solver for MILP problem (unit commitment for hydropower production). First, if I solve a problem with 3162 linear constraints 3628 variables : 1581 binary I got really …

---

## [Redefining a method used in a generated function](https://discourse.julialang.org/t/redefining-a-method-used-in-a-generated-function/35225)

<div class="topic-metadata">

**Author:** [@Sheemon7](https://discourse.julialang.org/u/Sheemon7)\
**Replies:** 2\
**Last updated:** [February 27, 2020, 2:06pm UTC](https://discourse.julialang.org/t/redefining-a-method-used-in-a-generated-function/35225 "2020-02-27T14:06:57Z")

</div>

I understand that generated functions are generated “on demand” and therefore all used methods have to be defined before: julia\> @generated g() = (@show f(1); nothing) g (generic function with 1 method) julia\> f(x) = x…

---

## [What computations are fine to do within \`Val\`?](https://discourse.julialang.org/t/what-computations-are-fine-to-do-within-val/35216)

<div class="topic-metadata">

**Author:** [@e3c6](https://discourse.julialang.org/u/e3c6)\
**Replies:** 7\
**Last updated:** [February 27, 2020, 2:05pm UTC](https://discourse.julialang.org/t/what-computations-are-fine-to-do-within-val/35216 "2020-02-27T14:05:31Z")

</div>

Here are two (highly artificial) examples: f(::Array{T,N}, ::Array{T,M}) where {T,N,M} = zeros(T, ntuple(i -\> 2, Val(N+M))) g(::Array{T,N}, ::Array{T,M}) where {T,N,M} = zeros(T, ntuple(i -\> 2, Val(round(Int, √abs(N+M))…

---

## [Plots & animation](https://discourse.julialang.org/t/plots-animation/35223)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 6\
**Last updated:** [February 27, 2020, 1:22pm UTC](https://discourse.julialang.org/t/plots-animation/35223 "2020-02-27T13:22:33Z")

</div>

I’m playing around with animation using Plots… Here is what I get: Question: Is it possible to suppress the plotting (IJulia, Windows 10) of the final plot (above the pink box with my black tipped masking of director…

---

## [Julia cheatsheet from julialang.org is outdated](https://discourse.julialang.org/t/julia-cheatsheet-from-julialang-org-is-outdated/35226)

<div class="topic-metadata">

**Author:** [@Iulian.Cioarca](https://discourse.julialang.org/u/Iulian.Cioarca)\
**Replies:** 1\
**Last updated:** [February 27, 2020, 12:50pm UTC](https://discourse.julialang.org/t/julia-cheatsheet-from-julialang-org-is-outdated/35226 "2020-02-27T12:50:18Z")

</div>

I was browsing through the Get started with Julia, Resources section and noticed that https://github.com/mitmath/1806/blob/master/julia/Julia-cheatsheet.pdf is a bit outdated (vector scalar operations lack the broadcasti…

---

## [Test-driven/test-heavy workflow?](https://discourse.julialang.org/t/test-driven-test-heavy-workflow/35173)

<div class="topic-metadata">

**Author:** [@mlhetland](https://discourse.julialang.org/u/mlhetland)\
**Replies:** 6\
**Last updated:** [February 27, 2020, 11:40am UTC](https://discourse.julialang.org/t/test-driven-test-heavy-workflow/35173 "2020-02-27T11:40:57Z")

</div>

How do people set things up in order to run their test suite often (whether test-driven or not)? Some options I’ve used: Run test/runtests.jl from command line. Tends to take a long time, and requires global installat…

---

## [Invalid redefinition of constant model](https://discourse.julialang.org/t/invalid-redefinition-of-constant-model/35162)

<div class="topic-metadata">

**Author:** [@Eldho.Ashna](https://discourse.julialang.org/u/Eldho.Ashna)\
**Replies:** 8\
**Last updated:** [February 27, 2020, 11:17am UTC](https://discourse.julialang.org/t/invalid-redefinition-of-constant-model/35162 "2020-02-27T11:17:09Z")

</div>

Hi everyone. I’m new to JUlia programming language. I was trying to create my own model for MNIST classification using Flux. Below is my code: model = Chain( Conv((2,2), 1=\>16, relu), x -\> maxpool(x, (2,2)), Con…

---

## [Clear results displays in Atom](https://discourse.julialang.org/t/clear-results-displays-in-atom/35186)

<div class="topic-metadata">

**Author:** [@squirrel](https://discourse.julialang.org/u/squirrel)\
**Replies:** 3\
**Last updated:** [February 27, 2020, 10:27am UTC](https://discourse.julialang.org/t/clear-results-displays-in-atom/35186 "2020-02-27T10:27:13Z")

</div>

Is there a way of clearing all of these displayed results in Atom? Doing ctrl + shift + enter will clear them, but it will also run all of the code in the file.

---

## [How to install CNNVisualize](https://discourse.julialang.org/t/how-to-install-cnnvisualize/35215)

<div class="topic-metadata">

**Author:** [@Eldho.Ashna](https://discourse.julialang.org/u/Eldho.Ashna)\
**Replies:** 5\
**Last updated:** [February 27, 2020, 10:26am UTC](https://discourse.julialang.org/t/how-to-install-cnnvisualize/35215 "2020-02-27T10:26:57Z")

</div>

Hi everyone. I want to install CNNVisualize. When I try to install it using import Pkg; Pkg.add("CNNVisualize") I’m getting the following error: The following package names could not be resolved: \* CNNVisualize (not…

---

## [How to read in a list of integers into an array](https://discourse.julialang.org/t/how-to-read-in-a-list-of-integers-into-an-array/35185)

<div class="topic-metadata">

**Author:** [@lesshaste](https://discourse.julialang.org/u/lesshaste)\
**Replies:** 16\
**Last updated:** [February 27, 2020, 10:24am UTC](https://discourse.julialang.org/t/how-to-read-in-a-list-of-integers-into-an-array/35185 "2020-02-27T10:24:19Z")

</div>

I have been a number of files, each contains one list of integers. I would just like to read in the contents into an array in Julia. Here is an example file: http://paste.ubuntu.com/p/pxmwPXkNNk/ How can I do that? I…

---

## [Fast type-stable tensor products](https://discourse.julialang.org/t/fast-type-stable-tensor-products/35159)

<div class="topic-metadata">

**Author:** [@e3c6](https://discourse.julialang.org/u/e3c6)\
**Replies:** 18\
**Last updated:** [February 27, 2020, 9:56am UTC](https://discourse.julialang.org/t/fast-type-stable-tensor-products/35159 "2020-02-27T09:56:51Z")

</div>

Let A and B be two multi-dimensional arrays. I want to form a product of them that contracts the last n dimensions of A with the first n dimensions of B. Calling this product C, one way to do it is with the following cod…

---

## [Sumation inside a for loop](https://discourse.julialang.org/t/sumation-inside-a-for-loop/35166)

<div class="topic-metadata">

**Author:** [@marouane1994](https://discourse.julialang.org/u/marouane1994)\
**Replies:** 8\
**Last updated:** [February 27, 2020, 8:32am UTC](https://discourse.julialang.org/t/sumation-inside-a-for-loop/35166 "2020-02-27T08:32:02Z")

</div>

i have tried to do a simple code for MCMC as you see below: traget(x)= (1/sqrt(2\*pi\*2^2))\*exp((-(x-10)^2)/(2\*2^2)) proposal(x)=Normal(x,1) initial=-40 result=\[\] Iteration=10000 chain=zeros(Iteration) accept\_rate= zeros(…

---

## [Usability idea for IDEs - dotting your way through](https://discourse.julialang.org/t/usability-idea-for-ides-dotting-your-way-through/35213)

<div class="topic-metadata">

**Author:** [@Impressium](https://discourse.julialang.org/u/Impressium)\
**Replies:** 1\
**Last updated:** [February 27, 2020, 8:28am UTC](https://discourse.julialang.org/t/usability-idea-for-ides-dotting-your-way-through/35213 "2020-02-27T08:28:59Z")

</div>

One very cool feature I’m still missing are the recommended function one can use with struct/(classes) in other languages. For these language it’s easy because they are statically typed and only use single dispatch. Wo…

---

## [Passing keyword arguments from a function to the other](https://discourse.julialang.org/t/passing-keyword-arguments-from-a-function-to-the-other/35190)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 3\
**Last updated:** [February 27, 2020, 8:12am UTC](https://discourse.julialang.org/t/passing-keyword-arguments-from-a-function-to-the-other/35190 "2020-02-27T08:12:25Z")

</div>

I need to replicate the following python code, where f1 is called with a function name, a positional argument and some keyword ones, and it passes to the function defined in its first argument the positional argument and…

---

## [Trace of broadcasting](https://discourse.julialang.org/t/trace-of-broadcasting/35210)

<div class="topic-metadata">

**Author:** [@tomtom](https://discourse.julialang.org/u/tomtom)\
**Replies:** 4\
**Last updated:** [February 27, 2020, 7:35am UTC](https://discourse.julialang.org/t/trace-of-broadcasting/35210 "2020-02-27T07:35:17Z")

</div>

docs said: f.(args...) is equivalent to broadcast(f, args...) however, I found that f.() is not calling broadcast(f, ): Base.broadcast(::typeof(exp), x) = println("exp ", x); x = \[1.0, 2.0\]; julia\> Base.broadcast…

---

## [Problem to start Julia in Atom](https://discourse.julialang.org/t/problem-to-start-julia-in-atom/35206)

<div class="topic-metadata">

**Author:** [@Ujku\_KU](https://discourse.julialang.org/u/Ujku_KU)\
**Replies:** 7\
**Last updated:** [February 27, 2020, 5:00am UTC](https://discourse.julialang.org/t/problem-to-start-julia-in-atom/35206 "2020-02-27T05:00:34Z")

</div>

Hi guys. I am new to Julia and Atom. Recently I experienced problems with Atom while running some Julia code. Hence I had to reinstall form the begging either Julia and Atom. I was aware of the fact that I had to add the…

---

## [Organizing structs and modules](https://discourse.julialang.org/t/organizing-structs-and-modules/34993)

<div class="topic-metadata">

**Author:** [@squirrel](https://discourse.julialang.org/u/squirrel)\
**Replies:** 11\
**Last updated:** [February 27, 2020, 2:27am UTC](https://discourse.julialang.org/t/organizing-structs-and-modules/34993 "2020-02-27T02:27:57Z")

</div>

I’m running into some trouble with organizing my files. I want to divide up my functions and structs into separate modules in separate files to keep them somewhat organized, and I don’t want to install them as Packages b…

---

## [How to avoid unneccessary memory allocation for inplace estimation of \`mean\`?](https://discourse.julialang.org/t/how-to-avoid-unneccessary-memory-allocation-for-inplace-estimation-of-mean/35146)

<div class="topic-metadata">

**Author:** [@vpetukhov](https://discourse.julialang.org/u/vpetukhov)\
**Replies:** 12\
**Last updated:** [February 27, 2020, 12:13am UTC](https://discourse.julialang.org/t/how-to-avoid-unneccessary-memory-allocation-for-inplace-estimation-of-mean/35146 "2020-02-27T00:13:58Z")

</div>

I’m doing micro-optimization of my code, and current bottleneck is a place, where I call mean millions of times on small 2d arrays. And it leads to huge number of allocations. Simply re-implementing mean removes them all…

[Previous page](https://discourse.julialang.org/latest.md?page=1813)

[Next page](https://discourse.julialang.org/latest.md?page=1815)
