# Latest

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

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

**Page:** 1400

---

## [Combination of FormatLogger and FileLogger in LoggingExtras](https://discourse.julialang.org/t/combination-of-formatlogger-and-filelogger-in-loggingextras/60654)

<div class="topic-metadata">

**Author:** [@BambOoxX](https://discourse.julialang.org/u/BambOoxX)\
**Replies:** 2\
**Last updated:** [May 7, 2021, 7:21am UTC](https://discourse.julialang.org/t/combination-of-formatlogger-and-filelogger-in-loggingextras/60654 "2021-05-07T07:21:25Z")

</div>

Is it possible to combine the capabilities of a FormatLogger and of a FileLogger in LoggingExtras.jl? Quite obviously, the first one helps formatting logging messages with the other sends them to appropriate files. Thou…

---

## [Problem in Pluto](https://discourse.julialang.org/t/problem-in-pluto/60683)

<div class="topic-metadata">

**Author:** [@Vos](https://discourse.julialang.org/u/Vos)\
**Replies:** 1\
**Last updated:** [May 7, 2021, 7:17am UTC](https://discourse.julialang.org/t/problem-in-pluto/60683 "2021-05-07T07:17:12Z")

</div>

Good evening to all, I have a problem with my code. What I wrote is supposed to draw “lines” connecting the edge of the large rectangle with the edge of the small rectangle, like this: But sometimes it gives me th…

---

## [Running Julia (Jupyter) Notebooks inside VSCode](https://discourse.julialang.org/t/running-julia-jupyter-notebooks-inside-vscode/47421)

<div class="topic-metadata">

**Author:** [@stochastic\_guy](https://discourse.julialang.org/u/stochastic_guy)\
**Replies:** 16\
**Last updated:** [May 7, 2021, 6:47am UTC](https://discourse.julialang.org/t/running-julia-jupyter-notebooks-inside-vscode/47421 "2021-05-07T06:47:54Z")

</div>

Rather than a question, this is a simple trick I found myself that might be useful for the whole community. I couldn’t find this information anywhere posted, hence sharing it here. It is actually possible to run a jup…

---

## [Prefetch data in a separate thread (or why adding a single print leads to a 2x performance)](https://discourse.julialang.org/t/prefetch-data-in-a-separate-thread-or-why-adding-a-single-print-leads-to-a-2x-performance/60225)

<div class="topic-metadata">

**Author:** [@Alexander-Barth](https://discourse.julialang.org/u/Alexander-Barth)\
**Replies:** 5\
**Last updated:** [May 7, 2021, 6:37am UTC](https://discourse.julialang.org/t/prefetch-data-in-a-separate-thread-or-why-adding-a-single-print-leads-to-a-2x-performance/60225 "2021-05-07T06:37:08Z")

</div>

I am training a neural network where some significant time is spent on the data preparation on the CPU (data augmentation). This results in a relatively low GPU utilization overall because the GPU has to wait for the dat…

---

## [Ending @async task externally](https://discourse.julialang.org/t/ending-async-task-externally/60693)

<div class="topic-metadata">

**Author:** [@ligert123](https://discourse.julialang.org/u/ligert123)\
**Replies:** 1\
**Last updated:** [May 7, 2021, 6:19am UTC](https://discourse.julialang.org/t/ending-async-task-externally/60693 "2021-05-07T06:19:04Z")

</div>

Hello, does anyone know how to close an async task from within another thread? ive been trying to do it using methods like an endless loop with a bool array that is passed in externally but that doesnt seem to work. Any…

---

## [A bug in ForwardDiff?](https://discourse.julialang.org/t/a-bug-in-forwarddiff/60691)

<div class="topic-metadata">

**Author:** [@amrods](https://discourse.julialang.org/u/amrods)\
**Replies:** 2\
**Last updated:** [May 7, 2021, 3:45am UTC](https://discourse.julialang.org/t/a-bug-in-forwarddiff/60691 "2021-05-07T03:45:59Z")

</div>

Consider this: using ForwardDiff function f!(F, x) F\[1\] = (x\[1\]+3)\*(x\[2\]^3-7)+18 F\[2\] = sin(x\[2\]\*exp(x\[1\])-1) return F end F = Array{Float64}(undef, 2) x = \[1, 1\] Now let’s compute the Jacobian. The docum…

---

## [How to make standard Julia package with input/options parameters in non compiled Julia files](https://discourse.julialang.org/t/how-to-make-standard-julia-package-with-input-options-parameters-in-non-compiled-julia-files/60549)

<div class="topic-metadata">

**Author:** [@JosephPollacco](https://discourse.julialang.org/u/JosephPollacco)\
**Replies:** 8\
**Last updated:** [May 6, 2021, 11:37pm UTC](https://discourse.julialang.org/t/how-to-make-standard-julia-package-with-input-options-parameters-in-non-compiled-julia-files/60549 "2021-05-06T23:37:55Z")

</div>

I wrote a large scientific package SoilWater-ToolBox https://github.com/joseph-pollacco/SoilWaterToolbox and now it is time to compile the software into a Julia Package The question is that I have different options of …

---

## [Debugging with DifferentialEquations.jl](https://discourse.julialang.org/t/debugging-with-differentialequations-jl/60563)

<div class="topic-metadata">

**Author:** [@Fathya.Salih](https://discourse.julialang.org/u/Fathya.Salih)\
**Replies:** 1\
**Last updated:** [May 6, 2021, 11:35pm UTC](https://discourse.julialang.org/t/debugging-with-differentialequations-jl/60563 "2021-05-06T23:35:14Z")

</div>

I have been trying to debug an ODE solver code that looks something like this: u0 = zeros(100) function f(u, p, t) a, b, c, d = p println("t = ", t) # Applying BC and finding ODE RHS apply\_bc(u, a, b, c, d) en…

---

## [Best approach to smooth array? None of my approaches are very useful](https://discourse.julialang.org/t/best-approach-to-smooth-array-none-of-my-approaches-are-very-useful/17633)

<div class="topic-metadata">

**Author:** [@aramirezreyes](https://discourse.julialang.org/u/aramirezreyes)\
**Replies:** 18\
**Last updated:** [May 6, 2021, 10:23pm UTC](https://discourse.julialang.org/t/best-approach-to-smooth-array-none-of-my-approaches-are-very-useful/17633 "2021-05-06T22:23:23Z")

</div>

Hi! I´ve been trying this week to get something accomplished but I cannot get it done. Problem: I have group of variables coming from a NetCDF. When imported using NCDatasets, I get arrays of 64 bits with a size (128,1…

---

## [Detecting keypress](https://discourse.julialang.org/t/detecting-keypress/60612)

<div class="topic-metadata">

**Author:** [@rverdier](https://discourse.julialang.org/u/rverdier)\
**Replies:** 5\
**Last updated:** [May 6, 2021, 9:16pm UTC](https://discourse.julialang.org/t/detecting-keypress/60612 "2021-05-06T21:16:47Z")

</div>

For a Julia+Gtk course I’m writing, I need to process keys when pressed. This stripped-down example shows that this only works if the callback function, keycall, is defined inside, not outside, the keypresswindow functi…

---

## [Some observer's thoughts on developments of Julia packages and modules](https://discourse.julialang.org/t/some-observers-thoughts-on-developments-of-julia-packages-and-modules/60660)

<div class="topic-metadata">

**Author:** [@KZiemian](https://discourse.julialang.org/u/KZiemian)\
**Replies:** 8\
**Last updated:** [May 6, 2021, 8:46pm UTC](https://discourse.julialang.org/t/some-observers-thoughts-on-developments-of-julia-packages-and-modules/60660 "2021-05-06T20:46:22Z")

</div>

Recently excellent package DataFrames.jl arrived at version 1.0.0 (today it is v1.1.0), which make me wonder about time that such development takes. Complaining about not having it sooner, when you have such excellent, o…

---

## [Julia 1.6.0 package manager - error message "noise" in custom Docker image on add/update](https://discourse.julialang.org/t/julia-1-6-0-package-manager-error-message-noise-in-custom-docker-image-on-add-update/58037)

<div class="topic-metadata">

**Author:** [@twadleigh](https://discourse.julialang.org/u/twadleigh)\
**Replies:** 13\
**Last updated:** [May 6, 2021, 7:54pm UTC](https://discourse.julialang.org/t/julia-1-6-0-package-manager-error-message-noise-in-custom-docker-image-on-add-update/58037 "2021-05-06T19:54:24Z")

</div>

I just bumped the julia version to 1.6.0 in a Docker image we use in my organization. I now see repetitions of the same error message when doing package operations. For instance: (@v1.6) pkg\> update Updating registr…

---

## [Subtracting the values in one column from corresponding values in all other columns of a DataFrame](https://discourse.julialang.org/t/subtracting-the-values-in-one-column-from-corresponding-values-in-all-other-columns-of-a-dataframe/60675)

<div class="topic-metadata">

**Author:** [@Nash](https://discourse.julialang.org/u/Nash)\
**Replies:** 3\
**Last updated:** [May 6, 2021, 7:13pm UTC](https://discourse.julialang.org/t/subtracting-the-values-in-one-column-from-corresponding-values-in-all-other-columns-of-a-dataframe/60675 "2021-05-06T19:13:31Z")

</div>

I have two DataFrames. One contains simply one column. The other contains multiple columns. The DataFrames have the same number of rows. How do I subtract the values in the first DataFrame from the corresponding values …

---

## [JuMP only for formulation and CPLEX.jl (or Gurobi.jl) as callable library wrapper?](https://discourse.julialang.org/t/jump-only-for-formulation-and-cplex-jl-or-gurobi-jl-as-callable-library-wrapper/60662)

<div class="topic-metadata">

**Author:** [@rocarvaj](https://discourse.julialang.org/u/rocarvaj)\
**Replies:** 2\
**Last updated:** [May 6, 2021, 6:36pm UTC](https://discourse.julialang.org/t/jump-only-for-formulation-and-cplex-jl-or-gurobi-jl-as-callable-library-wrapper/60662 "2021-05-06T18:36:13Z")

</div>

Hello! I’ve read the documentation for both JuMP and CPLEX.jl (the readme page on Github) but I just want to be 100% if it is possible to do the following: Formulate a MILP (using only constraints supported by the sol…

---

## [Get list of columns from formula](https://discourse.julialang.org/t/get-list-of-columns-from-formula/60611)

<div class="topic-metadata">

**Author:** [@jzr](https://discourse.julialang.org/u/jzr)\
**Replies:** 1\
**Last updated:** [May 6, 2021, 6:33pm UTC](https://discourse.julialang.org/t/get-list-of-columns-from-formula/60611 "2021-05-06T18:33:09Z")

</div>

I want to make a dataframe that has only the columns that appear in the formula. How can I get the list of terms from a formula? @formula(y ~ a + b + c \* d + e + e ^ 2) cc @dave.f.kleinschmidt

---

## [Inlining of rand -- Vector vs nx1 Matrix](https://discourse.julialang.org/t/inlining-of-rand-vector-vs-nx1-matrix/60583)

<div class="topic-metadata">

**Author:** [@MeinAccount](https://discourse.julialang.org/u/MeinAccount)\
**Replies:** 5\
**Last updated:** [May 6, 2021, 5:58pm UTC](https://discourse.julialang.org/t/inlining-of-rand-vector-vs-nx1-matrix/60583 "2021-05-06T17:58:01Z")

</div>

Using the latest Distributions and BenchmarkTools I observed the following weird / unexpected behavior on Julia 1.6.1 with -O3: julia\> @benchmark rand(Beta(2, 2), rand(Poisson(10))) BenchmarkTools.Trial: memory estim…

---

## [\[ANN\] Announcing Utilitas.jl](https://discourse.julialang.org/t/ann-announcing-utilitas-jl/60651)

<div class="topic-metadata">

**Author:** [@ChetanVardhan](https://discourse.julialang.org/u/ChetanVardhan)\
**Replies:** 2\
**Last updated:** [May 6, 2021, 5:48pm UTC](https://discourse.julialang.org/t/ann-announcing-utilitas-jl/60651 "2021-05-06T17:48:19Z")

</div>

Announcing Utilitas.jl Just some methods for Package management

---

## [TimeSeries Analysis](https://discourse.julialang.org/t/timeseries-analysis/60670)

<div class="topic-metadata">

**Author:** [@statspy](https://discourse.julialang.org/u/statspy)\
**Replies:** 0\
**Last updated:** [May 6, 2021, 5:47pm UTC](https://discourse.julialang.org/t/timeseries-analysis/60670 "2021-05-06T17:47:03Z")

</div>

Hello, Whats the best package recommendation to work with time series in Julia? I checked Julia Observer but I didn’t find any consensus about it. Thanks

---

## [Why using \`+=\` instead of \`=\` generates slow code?](https://discourse.julialang.org/t/why-using-instead-of-generates-slow-code/60664)

<div class="topic-metadata">

**Author:** [@1115](https://discourse.julialang.org/u/1115)\
**Replies:** 5\
**Last updated:** [May 6, 2021, 5:02pm UTC](https://discourse.julialang.org/t/why-using-instead-of-generates-slow-code/60664 "2021-05-06T17:02:38Z")

</div>

I have two functions, their only difference is one uses += and another uses =, but are making a \> 4x performance difference. The + is much faster than sin and cos and I suppose the following two functions should not make…

---

## [Code runtime constantly increasing with time](https://discourse.julialang.org/t/code-runtime-constantly-increasing-with-time/60437)

<div class="topic-metadata">

**Author:** [@ff1991](https://discourse.julialang.org/u/ff1991)\
**Replies:** 16\
**Last updated:** [May 6, 2021, 5:00pm UTC](https://discourse.julialang.org/t/code-runtime-constantly-increasing-with-time/60437 "2021-05-06T17:00:56Z")

</div>

Hello Everyone, I am fairly new to Julia, so sorry if the problem I would like to ask about may seem a bit general. I have actually written a plasma simulation code which is unfortunately too much detailed and consisti…

---

## [How do you access a struct field name in a string](https://discourse.julialang.org/t/how-do-you-access-a-struct-field-name-in-a-string/60666)

<div class="topic-metadata">

**Author:** [@anon60034542](https://discourse.julialang.org/u/anon60034542)\
**Replies:** 1\
**Last updated:** [May 6, 2021, 4:11pm UTC](https://discourse.julialang.org/t/how-do-you-access-a-struct-field-name-in-a-string/60666 "2021-05-06T16:11:30Z")

</div>

Suppose I had the follow struct: struct Employee ID::Int32 name::String end Is it possible to access a field name while embedded in a string? svetlana = Employee(1,"Queen Svetlana") # prints Employee Name: svetlana.…

---

## [Remote development using VSCode tip](https://discourse.julialang.org/t/remote-development-using-vscode-tip/60522)

<div class="topic-metadata">

**Author:** [@jmair](https://discourse.julialang.org/u/jmair)\
**Replies:** 9\
**Last updated:** [May 6, 2021, 4:12pm UTC](https://discourse.julialang.org/t/remote-development-using-vscode-tip/60522 "2021-05-06T16:12:46Z")

</div>

I am currently using a HPC to work on my Julia code. I normally use VS Code and the remote development tools to SSH into the HPC, however, I have had some issues with the Julia intellisense when on a remote system. I ha…

---

## [How to measure energy consumption of computations?](https://discourse.julialang.org/t/how-to-measure-energy-consumption-of-computations/60578)

<div class="topic-metadata">

**Author:** [@scheidan1](https://discourse.julialang.org/u/scheidan1)\
**Replies:** 7\
**Last updated:** [May 6, 2021, 4:02pm UTC](https://discourse.julialang.org/t/how-to-measure-energy-consumption-of-computations/60578 "2021-05-06T16:02:51Z")

</div>

Developing models and running simulations is a core activity of our research department. Faster languages (Julia) and better algorithms result typically not in less computation, but in more ambitious targets. During a d…

---

## [3D Plot Title Issue (Makie.jl)](https://discourse.julialang.org/t/3d-plot-title-issue-makie-jl/60661)

<div class="topic-metadata">

**Author:** [@Arryk](https://discourse.julialang.org/u/Arryk)\
**Replies:** 4\
**Last updated:** [May 6, 2021, 3:56pm UTC](https://discourse.julialang.org/t/3d-plot-title-issue-makie-jl/60661 "2021-05-06T15:56:34Z")

</div>

I have some simple code to plot the earth in 3D using Makie.jl using GLMakie, FileIO, Colors, GeometryBasics # Plot related libraries # Earth Image const earth\_img = load(download("https://svs.gsfc.nasa.gov/vis/a000000…

---

## [Precompilation techniques for speeding up the first run (Heroku deployments and PackageCompiler)](https://discourse.julialang.org/t/precompilation-techniques-for-speeding-up-the-first-run-heroku-deployments-and-packagecompiler/29327)

<div class="topic-metadata">

**Author:** [@essenciary](https://discourse.julialang.org/u/essenciary)\
**Replies:** 18\
**Last updated:** [May 6, 2021, 3:19pm UTC](https://discourse.julialang.org/t/precompilation-techniques-for-speeding-up-the-first-run-heroku-deployments-and-packagecompiler/29327 "2021-05-06T15:19:20Z")

</div>

I’m using a Dockerfile to deploy a Genie app on a host and among other commands, I deploy the app with: RUN julia -e "using Pkg; pkg\\"activate . \\"; pkg\\"instantiate\\"; pkg\\"precompile\\"; " However, upon starting the a…

---

## [CUDNNError: CUDNN\_STATUS\_NOT\_INITIALIZED (code 1) during Pkg.test("CUDA")](https://discourse.julialang.org/t/cudnnerror-cudnn-status-not-initialized-code-1-during-pkg-test-cuda/60431)

<div class="topic-metadata">

**Author:** [@pfarndt](https://discourse.julialang.org/u/pfarndt)\
**Replies:** 5\
**Last updated:** [May 6, 2021, 2:37pm UTC](https://discourse.julialang.org/t/cudnnerror-cudnn-status-not-initialized-code-1-during-pkg-test-cuda/60431 "2021-05-06T14:37:38Z")

</div>

Using Julia v1.6.1 I get several error during testing the CUDA package (v3.1.0). Most of them go back to CUDNNError: CUDNN\_STATUS\_NOT\_INITIALIZED (code 1) - more details below. The corresponding test runs through witho…

---

## [Why is the exception not rethrown in logging?](https://discourse.julialang.org/t/why-is-the-exception-not-rethrown-in-logging/60658)

<div class="topic-metadata">

**Author:** [@findmyway](https://discourse.julialang.org/u/findmyway)\
**Replies:** 0\
**Last updated:** [May 6, 2021, 2:45pm UTC](https://discourse.julialang.org/t/why-is-the-exception-not-rethrown-in-logging/60658 "2021-05-06T14:45:22Z")

</div>

https://github.com/JuliaLang/julia/blob/ae1aa16bc0ee608568d799e25620ba9580110f9b/base/logging.jl#L339-L346 Can anyone explain why the exception is not rethrown here? We find that this will create something inconsistent…

---

## [Set inconsistencies with structs](https://discourse.julialang.org/t/set-inconsistencies-with-structs/60637)

<div class="topic-metadata">

**Author:** [@lklein](https://discourse.julialang.org/u/lklein)\
**Replies:** 4\
**Last updated:** [May 6, 2021, 2:36pm UTC](https://discourse.julialang.org/t/set-inconsistencies-with-structs/60637 "2021-05-06T14:36:33Z")

</div>

Hi all, I was working with sets and self defined structs and noticed the following: julia\> struct A a end Base.:(==)(a::A,b::A) = true set = Set{A}() push!(set, A(1)) Set{A} with 1 element: A(1) …

---

## [Indicate data outside the plotting area](https://discourse.julialang.org/t/indicate-data-outside-the-plotting-area/60646)

<div class="topic-metadata">

**Author:** [@feanor12](https://discourse.julialang.org/u/feanor12)\
**Replies:** 1\
**Last updated:** [May 6, 2021, 2:18pm UTC](https://discourse.julialang.org/t/indicate-data-outside-the-plotting-area/60646 "2021-05-06T14:18:12Z")

</div>

I was doing some boxplots using StatsPlots and I had some outliers. To show the boxes I used ylims! to better show their distribution, but the outliers were off the plot. Is it possible to show a marker at the side of…

---

## [Enbedding julia in C++ , how to call savefig function?](https://discourse.julialang.org/t/enbedding-julia-in-c-how-to-call-savefig-function/60648)

<div class="topic-metadata">

**Author:** [@dbertini](https://discourse.julialang.org/u/dbertini)\
**Replies:** 0\
**Last updated:** [May 6, 2021, 1:26pm UTC](https://discourse.julialang.org/t/enbedding-julia-in-c-how-to-call-savefig-function/60648 "2021-05-06T13:26:48Z")

</div>

Hi I am trying to use the julia C interface in orger to call Julia from within my C++ program. I would like to save some plots but it does not seems to work. Here is a snapshot of the code i used so far: { // here u…

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

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