# Latest

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

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

**Page:** 1963

---

## [Is there something like ScipyOptimizer in Julia?](https://discourse.julialang.org/t/is-there-something-like-scipyoptimizer-in-julia/23251)

<div class="topic-metadata">

**Author:** [@vavrines](https://discourse.julialang.org/u/vavrines)\
**Replies:** 10\
**Last updated:** [July 11, 2019, 12:55pm UTC](https://discourse.julialang.org/t/is-there-something-like-scipyoptimizer-in-julia/23251 "2019-07-11T12:55:34Z")

</div>

Hi all, Recently, I’m turning to use Julia and Flux.jl to treat some differential equations in computational physics. I find it convenient and efficient indeed. However, I wonder if there is any high-order optimizatio…

---

## [What is wrong in my build.jl?](https://discourse.julialang.org/t/what-is-wrong-in-my-build-jl/26245)

<div class="topic-metadata">

**Author:** [@Tero\_Frondelius](https://discourse.julialang.org/u/Tero_Frondelius)\
**Replies:** 2\
**Last updated:** [July 11, 2019, 12:05pm UTC](https://discourse.julialang.org/t/what-is-wrong-in-my-build-jl/26245 "2019-07-11T12:05:34Z")

</div>

Dear all, This is probably a trivial error, but I cannot see it myself. Here is my build.jl: dependencies = \[ "https://github.com/JuliaPackaging/JuliaBuilder/releases/download/v1.0.0-2/build\_Julia.v1.0.0.jl", "…

---

## [Debugging Function-Like object under Juno](https://discourse.julialang.org/t/debugging-function-like-object-under-juno/26079)

<div class="topic-metadata">

**Author:** [@pixel27](https://discourse.julialang.org/u/pixel27)\
**Replies:** 2\
**Last updated:** [July 11, 2019, 11:43am UTC](https://discourse.julialang.org/t/debugging-function-like-object-under-juno/26079 "2019-07-11T11:43:27Z")

</div>

I suspect this is a bug, but I’d like a second opinion in case I’m doing something wrong. Julia version: Julia Version 1.1.1 Commit 55e36cc308 (2019-05-16 04:10 UTC) Platform Info: OS: Linux (x86\_64-pc-linux-gnu) C…

---

## [DataFrames and serialization](https://discourse.julialang.org/t/dataframes-and-serialization/26248)

<div class="topic-metadata">

**Author:** [@gdkrmr](https://discourse.julialang.org/u/gdkrmr)\
**Replies:** 0\
**Last updated:** [July 11, 2019, 11:33am UTC](https://discourse.julialang.org/t/dataframes-and-serialization/26248 "2019-07-11T11:33:14Z")

</div>

I had to send a DataFrame (ca. 7000x1500, in my opinion not even that large) to several worker processes (ca. 40) and and the whole process was a pain: @everywhere df = $df took 3 minutes! A colleague told me to write…

---

## [Flux unable to differentiate an embedding layer](https://discourse.julialang.org/t/flux-unable-to-differentiate-an-embedding-layer/26067)

<div class="topic-metadata">

**Author:** [@merckxiaan](https://discourse.julialang.org/u/merckxiaan)\
**Replies:** 3\
**Last updated:** [July 11, 2019, 10:11am UTC](https://discourse.julialang.org/t/flux-unable-to-differentiate-an-embedding-layer/26067 "2019-07-11T10:11:01Z")

</div>

I’ve made an embedding layer that should be able to embed a batched input. The forward pass seems to work great, I get back an array with the dimensions I expect. The backward pass however, doesn’t work. I get an error …

---

## [DistributedArray operation fails](https://discourse.julialang.org/t/distributedarray-operation-fails/26177)

<div class="topic-metadata">

**Author:** [@monty](https://discourse.julialang.org/u/monty)\
**Replies:** 3\
**Last updated:** [July 11, 2019, 8:24am UTC](https://discourse.julialang.org/t/distributedarray-operation-fails/26177 "2019-07-11T08:24:27Z")

</div>

da = DistributedArrays.distribute(rand(10,10)) da' \* da works. However, da \* da' fails. Any suggestions why and how it can be fixed? Thank you very much!

---

## [Destructuring & setindex!](https://discourse.julialang.org/t/destructuring-setindex/25475)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 10\
**Last updated:** [July 11, 2019, 7:11am UTC](https://discourse.julialang.org/t/destructuring-setindex/25475 "2019-07-11T07:11:20Z")

</div>

Tuple destructuring works even if the variables on the LHS are x\[i...\] expressions, eg g(y) = y, 2 \* y function foo!(x1, x2, y) for i in eachindex(y) x1\[i\], x2\[i\] = g(y\[i\]) end x1, x2 end x1 = zero…

---

## [Preferred method of loading binary files?](https://discourse.julialang.org/t/preferred-method-of-loading-binary-files/26213)

<div class="topic-metadata">

**Author:** [@Paethon](https://discourse.julialang.org/u/Paethon)\
**Replies:** 3\
**Last updated:** [July 11, 2019, 2:36am UTC](https://discourse.julialang.org/t/preferred-method-of-loading-binary-files/26213 "2019-07-11T02:36:58Z")

</div>

I am currently writing code to read from a binary file format. So the file has a structure and I have structs that mirror that structure and I would like to read the data from file and fill my structs with it. What is t…

---

## [Precompiling Caesar failes](https://discourse.julialang.org/t/precompiling-caesar-failes/26219)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 2\
**Last updated:** [July 11, 2019, 12:00am UTC](https://discourse.julialang.org/t/precompiling-caesar-failes/26219 "2019-07-11T00:00:30Z")

</div>

Dear all, I updated my packages, and precompiling Caesar now fails. It worked a few weeks ago. I am using Julia 1.1 on Linux (Ubuntu 18.04), 64 bits. Any idea? Precompiling Caesar \[ Info: Precompiling Caesar \[62eebf1…

---

## [Why does Base.retry return a function?](https://discourse.julialang.org/t/why-does-base-retry-return-a-function/26240)

<div class="topic-metadata">

**Author:** [@anon43133060](https://discourse.julialang.org/u/anon43133060)\
**Replies:** 1\
**Last updated:** [July 10, 2019, 11:16pm UTC](https://discourse.julialang.org/t/why-does-base-retry-return-a-function/26240 "2019-07-10T23:16:24Z")

</div>

I was expecting Base.retry(f) to just do the work, but instead it was Base.retry(f)(). Is this the only function in Base that returns another function?

---

## [Newbie question regarding Travis CI](https://discourse.julialang.org/t/newbie-question-regarding-travis-ci/26236)

<div class="topic-metadata">

**Author:** [@korowjev](https://discourse.julialang.org/u/korowjev)\
**Replies:** 2\
**Last updated:** [July 10, 2019, 8:48pm UTC](https://discourse.julialang.org/t/newbie-question-regarding-travis-ci/26236 "2019-07-10T20:48:24Z")

</div>

I am trying to use Travis in an Open Source project I started. I have some (very limited) experience with CI, but using C++. My build.jl file is this: https://github.com/korowjev/ArgData.jl/blob/master/deps/build.jl I …

---

## [PowerModels redirect output to file and weird output behavior using pmap()](https://discourse.julialang.org/t/powermodels-redirect-output-to-file-and-weird-output-behavior-using-pmap/26147)

<div class="topic-metadata">

**Author:** [@jchen975](https://discourse.julialang.org/u/jchen975)\
**Replies:** 2\
**Last updated:** [July 10, 2019, 8:30pm UTC](https://discourse.julialang.org/t/powermodels-redirect-output-to-file-and-weird-output-behavior-using-pmap/26147 "2019-07-10T20:30:47Z")

</div>

Hi, in PowerModels.jl, is there a way for me to either redirect the run\_ac\_pf and run\_dc\_pf outputs to a txt file or run in a non verbose mode altogether? Preferably I’d save the outputs to a file so that I can parse for…

---

## [Resizing REPL does major damage in Juno](https://discourse.julialang.org/t/resizing-repl-does-major-damage-in-juno/26051)

<div class="topic-metadata">

**Author:** [@Ross\_Boylan](https://discourse.julialang.org/u/Ross_Boylan)\
**Replies:** 5\
**Last updated:** [July 10, 2019, 8:14pm UTC](https://discourse.julialang.org/t/resizing-repl-does-major-damage-in-juno/26051 "2019-07-10T20:14:58Z")

</div>

Sometimes when I shrink the pane with the REPL horizontally it truncates the display and does not provide scrollbars. The material remains lost if I return the pane to its original size. Also, some of the material in t…

---

## [Metaprogramming](https://discourse.julialang.org/t/metaprogramming/26225)

<div class="topic-metadata">

**Author:** [@stu](https://discourse.julialang.org/u/stu)\
**Replies:** 6\
**Last updated:** [July 10, 2019, 7:31pm UTC](https://discourse.julialang.org/t/metaprogramming/26225 "2019-07-10T19:31:29Z")

</div>

Hello, (Apologies for the long post, issue is not that complex, I was just trying to be descriptive to make understanding it easier) As I understand it, metaprogramming is the tool that will help me achieve my objectiv…

---

## [PackageCompiler compile\_package works, but compile\_incremental fails on same runtests](https://discourse.julialang.org/t/packagecompiler-compile-package-works-but-compile-incremental-fails-on-same-runtests/26087)

<div class="topic-metadata">

**Author:** [@KestutisMa](https://discourse.julialang.org/u/KestutisMa)\
**Replies:** 6\
**Last updated:** [July 10, 2019, 5:28pm UTC](https://discourse.julialang.org/t/packagecompiler-compile-package-works-but-compile-incremental-fails-on-same-runtests/26087 "2019-07-10T17:28:02Z")

</div>

Hi, I want to pre-compile functions which I use frequently from REPL. I use PackageCompiler#sd-notomls. It works well with compile\_package("PyPlot"), but fails when list of precompiles is defined: compile\_incremental("/h…

---

## [Error "isjulia\_display not defined" while trying compile\_incremental PyPlot package](https://discourse.julialang.org/t/error-isjulia-display-not-defined-while-trying-compile-incremental-pyplot-package/26056)

<div class="topic-metadata">

**Author:** [@KestutisMa](https://discourse.julialang.org/u/KestutisMa)\
**Replies:** 2\
**Last updated:** [July 10, 2019, 4:39pm UTC](https://discourse.julialang.org/t/error-isjulia-display-not-defined-while-trying-compile-incremental-pyplot-package/26056 "2019-07-10T16:39:56Z")

</div>

HI, I am trying using PackageCompiler to compile\_incremental PyPlot package, using predefined snoopfile (runtests.jl), but got following error: Project.toml: name = "helloPkg" uuid = "04847676-9f50-11e9-38a1-b1b365cc1e…

---

## [When ArgumentError should be thrown?](https://discourse.julialang.org/t/when-argumenterror-should-be-thrown/26116)

<div class="topic-metadata">

**Author:** [@peters](https://discourse.julialang.org/u/peters)\
**Replies:** 4\
**Last updated:** [July 10, 2019, 4:09pm UTC](https://discourse.julialang.org/t/when-argumenterror-should-be-thrown/26116 "2019-07-10T16:09:58Z")

</div>

Recently, I had a chance to review error handling of a package and I found many error checking lines are throwing ArgumentError but in various reasons. Some lines are complaining about a argument value, some lines are ab…

---

## [What is the purpose of @inbounds in Julia?](https://discourse.julialang.org/t/what-is-the-purpose-of-inbounds-in-julia/26215)

<div class="topic-metadata">

**Author:** [@dsbsnyh](https://discourse.julialang.org/u/dsbsnyh)\
**Replies:** 4\
**Last updated:** [July 10, 2019, 3:41pm UTC](https://discourse.julialang.org/t/what-is-the-purpose-of-inbounds-in-julia/26215 "2019-07-10T15:41:23Z")

</div>

function sum(A::AbstractArray) r = zero(el type(A)) for i = 1: length(A) @inbounds r += A\[i\] end return r end @inbounds(blk) Eliminates array bounds checking within expressions. …

---

## [Cxx LLVM error](https://discourse.julialang.org/t/cxx-llvm-error/26226)

<div class="topic-metadata">

**Author:** [@hros](https://discourse.julialang.org/u/hros)\
**Replies:** 0\
**Last updated:** [July 10, 2019, 3:27pm UTC](https://discourse.julialang.org/t/cxx-llvm-error/26226 "2019-07-10T15:27:54Z")

</div>

I am wrapping a C++ math library (ntl) using Cxx. After successfully wrapping a major class, I encountered llvm errors in another class. The errors are: LLVM ERROR: Program used external function ‘\_\_emutls\_v.\_symbol’ …

---

## [Issue with ODE solver for solving Burgers equation using spectral method](https://discourse.julialang.org/t/issue-with-ode-solver-for-solving-burgers-equation-using-spectral-method/26224)

<div class="topic-metadata">

**Author:** [@henry2004y](https://discourse.julialang.org/u/henry2004y)\
**Replies:** 1\
**Last updated:** [July 10, 2019, 3:26pm UTC](https://discourse.julialang.org/t/issue-with-ode-solver-for-solving-burgers-equation-using-spectral-method/26224 "2019-07-10T15:26:04Z")

</div>

Hi all, I am trying to solve the 1D Burgers equation Burgers equation wiki using Fourier transform and the ODE package. Things works smoothly in Matlab, but not in Julia. I’m just wondering where I went wrong. Matlab …

---

## [How do you apply ceil/round function inside JuMP constraints, or can you force constraints to evaluate to Ints?](https://discourse.julialang.org/t/how-do-you-apply-ceil-round-function-inside-jump-constraints-or-can-you-force-constraints-to-evaluate-to-ints/26197)

<div class="topic-metadata">

**Author:** [@clausherther](https://discourse.julialang.org/u/clausherther)\
**Replies:** 4\
**Last updated:** [July 10, 2019, 2:29pm UTC](https://discourse.julialang.org/t/how-do-you-apply-ceil-round-function-inside-jump-constraints-or-can-you-force-constraints-to-evaluate-to-ints/26197 "2019-07-10T14:29:15Z")

</div>

Hi, I have this simple model that tries to maximize theoretical demand for a product given some SKU level inventory constraints and a probability distribution for SKU demand. In the first constraint I’d like to compare t…

---

## [Declaring state-dependent delay with DDEProblem; simulation gets slower?](https://discourse.julialang.org/t/declaring-state-dependent-delay-with-ddeproblem-simulation-gets-slower/26048)

<div class="topic-metadata">

**Author:** [@ANasc](https://discourse.julialang.org/u/ANasc)\
**Replies:** 7\
**Last updated:** [July 10, 2019, 1:15pm UTC](https://discourse.julialang.org/t/declaring-state-dependent-delay-with-ddeproblem-simulation-gets-slower/26048 "2019-07-10T13:15:33Z")

</div>

Dear All, I am having a hard time figuring out how to declare dependent\_lags that depend on one of the state variables in my DDE model (using DelayDiffEq.jl). It seems like it should be easy since the state variable i…

---

## [How to improve compilation time and loading time of packages?](https://discourse.julialang.org/t/how-to-improve-compilation-time-and-loading-time-of-packages/26183)

<div class="topic-metadata">

**Author:** [@tencnivel](https://discourse.julialang.org/u/tencnivel)\
**Replies:** 8\
**Last updated:** [July 10, 2019, 11:48am UTC](https://discourse.julialang.org/t/how-to-improve-compilation-time-and-loading-time-of-packages/26183 "2019-07-10T11:48:27Z")

</div>

EDIT: I was mistaking the compilation time of the utiity package with its loading. See message below: https://discourse.julialang.org/t/how-to-improve-compilation-time-and-loading-time-of-packages/26183/7 Original post…

---

## [\`Pkg\` fails to clone registry (SSL cert. error)](https://discourse.julialang.org/t/pkg-fails-to-clone-registry-ssl-cert-error/19652)

<div class="topic-metadata">

**Author:** [@skariel](https://discourse.julialang.org/u/skariel)\
**Replies:** 1\
**Last updated:** [July 10, 2019, 10:53am UTC](https://discourse.julialang.org/t/pkg-fails-to-clone-registry-ssl-cert-error/19652 "2019-07-10T10:53:13Z")

</div>

Using Julia 1.2 (happens also in 1.0.3), when running Pkg.update() I get: (v1.2) pkg\> update Cloning default registries into \`~/.julia\` Cloning registry from "https://github.com/JuliaRegistries/General.git" ERROR:…

---

## [For loop error](https://discourse.julialang.org/t/for-loop-error/26210)

<div class="topic-metadata">

**Author:** [@MuadhF](https://discourse.julialang.org/u/MuadhF)\
**Replies:** 7\
**Last updated:** [July 10, 2019, 9:46am UTC](https://discourse.julialang.org/t/for-loop-error/26210 "2019-07-10T09:46:56Z")

</div>

Hi, I’m still new to Julia, and am having problems with a for loop. I’m trying to create an array where each value is the former value minus another value. This is the code: for i = 1:T bal\[i\] = bal\[i-1\] - A\[i\] e…

---

## [Check bounds function in julia?](https://discourse.julialang.org/t/check-bounds-function-in-julia/26212)

<div class="topic-metadata">

**Author:** [@dsbsnyh](https://discourse.julialang.org/u/dsbsnyh)\
**Replies:** 5\
**Last updated:** [July 10, 2019, 9:43am UTC](https://discourse.julialang.org/t/check-bounds-function-in-julia/26212 "2019-07-10T09:43:21Z")

</div>

Hi, I have encountered this checkbounds function which confused me. Could anyone explain a bit what it does? a\_star\_algorithm(g::AbstractGraph{U}, s::Integer, …

---

## [Using vectors of vectors with CuArrays](https://discourse.julialang.org/t/using-vectors-of-vectors-with-cuarrays/25042)

<div class="topic-metadata">

**Author:** [@tanhevg](https://discourse.julialang.org/u/tanhevg)\
**Replies:** 2\
**Last updated:** [July 9, 2019, 8:43am UTC](https://discourse.julialang.org/t/using-vectors-of-vectors-with-cuarrays/25042 "2019-07-09T08:43:34Z")

</div>

Hello, I am trying to get the blstm example from Flux model zoo to work on GPU. The latest hurdle that I ran into is trying to convert the training data to GPU arrays. The example uses arrays of arrays to store the data…

---

## [How to create a private package registry](https://discourse.julialang.org/t/how-to-create-a-private-package-registry/11701)

<div class="topic-metadata">

**Author:** [@danielmatz](https://discourse.julialang.org/u/danielmatz)\
**Replies:** 14\
**Last updated:** [July 10, 2019, 5:26am UTC](https://discourse.julialang.org/t/how-to-create-a-private-package-registry/11701 "2019-07-10T05:26:48Z")

</div>

Is there any documentation explaining how to create a package repository for the new package manager? I want to set one up for use at my company for various packages that can’t be shared publicly.

---

## [Where to store custom packages?](https://discourse.julialang.org/t/where-to-store-custom-packages/25982)

<div class="topic-metadata">

**Author:** [@Luigi\_Marongiu](https://discourse.julialang.org/u/Luigi_Marongiu)\
**Replies:** 14\
**Last updated:** [July 10, 2019, 5:25am UTC](https://discourse.julialang.org/t/where-to-store-custom-packages/25982 "2019-07-10T05:25:02Z")

</div>

dear all, I am writing some scripts containing some functions that I could use in the future. Where shall I save the file? Can I simply load the script with using? Thank you

---

## [Performance of a type-unstable accumulator](https://discourse.julialang.org/t/performance-of-a-type-unstable-accumulator/26169)

<div class="topic-metadata">

**Author:** [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Replies:** 6\
**Last updated:** [July 10, 2019, 3:28am UTC](https://discourse.julialang.org/t/performance-of-a-type-unstable-accumulator/26169 "2019-07-10T03:28:59Z")

</div>

One of the general performance tips is to ensure that an accumulator has the same type as the data that you’re accumulating using the zero function. Apparently, there’s no visible effect in my performance tests below. H…

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

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