# Latest

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

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

**Page:** 614

---

## [Memory allocation, left-division operator](https://discourse.julialang.org/t/memory-allocation-left-division-operator/103111)

<div class="topic-metadata">

**Author:** [@AdaemmerP](https://discourse.julialang.org/u/AdaemmerP)\
**Replies:** 5\
**Last updated:** [August 24, 2023, 8:50am UTC](https://discourse.julialang.org/t/memory-allocation-left-division-operator/103111 "2023-08-24T08:50:22Z")

</div>

Why does the left-division operator allocates comparatively that much memory? # Data x = \[ones(1000) rand(1000)\] y = rand(1000) # Benchmark I (left-divison) @btime ($x \\ $y) 4.089 μs (29 allocations: 91.67 KiB) 2-ele…

---

## [Generating Julia binaries with JuMP issue](https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072)

<div class="topic-metadata">

**Author:** [@Rajender\_Mudigonda](https://discourse.julialang.org/u/Rajender_Mudigonda)\
**Replies:** 2\
**Last updated:** [August 24, 2023, 7:55am UTC](https://discourse.julialang.org/t/generating-julia-binaries-with-jump-issue/103072 "2023-08-24T07:55:05Z")

</div>

I want to create an executable for the julia file., for this i try to follow the instructions from link Creating a binary from Julia code · PackageCompiler when i try the below command on windows with julia version 1.9.…

---

## [OneAPI FPGA support](https://discourse.julialang.org/t/oneapi-fpga-support/103126)

<div class="topic-metadata">

**Author:** [@smartalecH](https://discourse.julialang.org/u/smartalecH)\
**Replies:** 3\
**Last updated:** [August 24, 2023, 7:43am UTC](https://discourse.julialang.org/t/oneapi-fpga-support/103126 "2023-08-24T07:43:48Z")

</div>

It seems like the julia bindings for OneAPI have come a long way (very cool!) I noticed that the current framework is validated to work with the Intel Compute Framework (which includes various Intel GPUs). Does anyone k…

---

## [Compute gradients in neuralODE with Zygote](https://discourse.julialang.org/t/compute-gradients-in-neuralode-with-zygote/103106)

<div class="topic-metadata">

**Author:** [@tommy\_J](https://discourse.julialang.org/u/tommy_J)\
**Replies:** 3\
**Last updated:** [August 24, 2023, 7:50am UTC](https://discourse.julialang.org/t/compute-gradients-in-neuralode-with-zygote/103106 "2023-08-24T07:50:41Z")

</div>

Hello everyone, I would like to know how to check the gradients for a single batch in this example. After the computation of l1 I did: batch1 = train\_loader.data\[1\] time1 = train\_loader.data\[2\] loss, back = Zygote.…

---

## [Can the CPU function be a multi-process parallel function when using the Threads.@spawn command to perform overlapping operations between the GPU and the CPU?](https://discourse.julialang.org/t/can-the-cpu-function-be-a-multi-process-parallel-function-when-using-the-threads-spawn-command-to-perform-overlapping-operations-between-the-gpu-and-the-cpu/103098)

<div class="topic-metadata">

**Author:** [@fred\_wu](https://discourse.julialang.org/u/fred_wu)\
**Replies:** 3\
**Last updated:** [August 24, 2023, 7:45am UTC](https://discourse.julialang.org/t/can-the-cpu-function-be-a-multi-process-parallel-function-when-using-the-threads-spawn-command-to-perform-overlapping-operations-between-the-gpu-and-the-cpu/103098 "2023-08-24T07:45:01Z")

</div>

Hi, When the CPU performs compute-intensive tasks, it never yields, so the Threads.@spawn command assigns CPU and GPU operations to different threads to achieve overlap and shorten the overall running time. However, can…

---

## [Set flushing mode for output stream](https://discourse.julialang.org/t/set-flushing-mode-for-output-stream/102546)

<div class="topic-metadata">

**Author:** [@ryofurue](https://discourse.julialang.org/u/ryofurue)\
**Replies:** 10\
**Last updated:** [August 23, 2023, 8:38am UTC](https://discourse.julialang.org/t/set-flushing-mode-for-output-stream/102546 "2023-08-23T08:38:10Z")

</div>

Is there a way either 1) to specify the flushing mode of an existing output stream or 2) to create a new stream that has the desired flushing mode? \[Edit: the output stream needs to be connected to the “screen” (console)…

---

## [Status of BFloat16](https://discourse.julialang.org/t/status-of-bfloat16/103109)

<div class="topic-metadata">

**Author:** [@Tomas\_Pevny](https://discourse.julialang.org/u/Tomas_Pevny)\
**Replies:** 4\
**Last updated:** [August 24, 2023, 6:57am UTC](https://discourse.julialang.org/t/status-of-bfloat16/103109 "2023-08-24T06:57:06Z")

</div>

Hello, I have tried Llama2 large language model in Julia following https://github.com/chengchingwen/Transformers.jl/blob/master/example/Llama2\_example.ipynb. This works really nice and smoothly, but, the example uses Fl…

---

## [Basic Package Extension Example](https://discourse.julialang.org/t/basic-package-extension-example/102969)

<div class="topic-metadata">

**Author:** [@TI36XPro](https://discourse.julialang.org/u/TI36XPro)\
**Replies:** 6\
**Last updated:** [August 24, 2023, 4:56am UTC](https://discourse.julialang.org/t/basic-package-extension-example/102969 "2023-08-24T04:56:03Z")

</div>

Hello, I’m having some trouble getting a basic example of package extensions working. I might’ve missed it, but there is no “starting from zero” example of how to create package extensions in the docs here. So hopefully…

---

## [Iterative completion of PDE solutions](https://discourse.julialang.org/t/iterative-completion-of-pde-solutions/103118)

<div class="topic-metadata">

**Author:** [@Knud\_Sorensen](https://discourse.julialang.org/u/Knud_Sorensen)\
**Replies:** 2\
**Last updated:** [August 24, 2023, 2:24am UTC](https://discourse.julialang.org/t/iterative-completion-of-pde-solutions/103118 "2023-08-24T02:24:05Z")

</div>

Hi. I have been reading this article, https://papers.ssrn.com/sol3/papers.cfm?abstract\_id=3736505 Where they iteratively complete a solution symbolically. It is possible to do something similar numerical in Julia ? I…

---

## [Can I use a categorical x/y variable in Makie?](https://discourse.julialang.org/t/can-i-use-a-categorical-x-y-variable-in-makie/103129)

<div class="topic-metadata">

**Author:** [@bertulli](https://discourse.julialang.org/u/bertulli)\
**Replies:** 2\
**Last updated:** [August 23, 2023, 11:18pm UTC](https://discourse.julialang.org/t/can-i-use-a-categorical-x-y-variable-in-makie/103129 "2023-08-23T23:18:01Z")

</div>

Hi, I’d like to plot an heatmap using Makie (I don’t care about the backend). The data are stored in a 2D matrix, and the x/y dimensions are actually categorical, represented with a vector of strings. In Plots, I can do …

---

## [Strange behavior of \`struct\` definition in REPL](https://discourse.julialang.org/t/strange-behavior-of-struct-definition-in-repl/103116)

<div class="topic-metadata">

**Author:** [@pao](https://discourse.julialang.org/u/pao)\
**Replies:** 5\
**Last updated:** [August 23, 2023, 10:53pm UTC](https://discourse.julialang.org/t/strange-behavior-of-struct-definition-in-repl/103116 "2023-08-23T22:53:24Z")

</div>

This does not seem correct to me … Tried anything, also using a development module. I’m using Julia-1.10.0.beta2 or Version 1.9.2 Same results. I’m in a deadlock !! Any clue? help?\> Main.HPC No documentation fou…

---

## [Reducing monthly data to yearly](https://discourse.julialang.org/t/reducing-monthly-data-to-yearly/103087)

<div class="topic-metadata">

**Author:** [@yvikhlya](https://discourse.julialang.org/u/yvikhlya)\
**Replies:** 9\
**Last updated:** [August 23, 2023, 10:25pm UTC](https://discourse.julialang.org/t/reducing-monthly-data-to-yearly/103087 "2023-08-23T22:25:23Z")

</div>

Hello All. I have a geospatial data in netCDF format with monthly frequency. Time variable is an array of DateTime objects. I want a selected variable var\[LAT, LON, DEPTH, MONTH\] to be reduced to var\[LAT, LON, DEPTH, YEA…

---

## [JuliaFormatter and VSCode - how to change options?](https://discourse.julialang.org/t/juliaformatter-and-vscode-how-to-change-options/72667)

<div class="topic-metadata">

**Author:** [@gobs](https://discourse.julialang.org/u/gobs)\
**Replies:** 14\
**Last updated:** [August 18, 2023, 10:22am UTC](https://discourse.julialang.org/t/juliaformatter-and-vscode-how-to-change-options/72667 "2023-08-18T10:22:07Z")

</div>

I understand that the VSCode extension now uses the JuliaFormatter.jl package. This is great, but I’m a little perplexed as to where I’m supposed to put my .JuliaFormatter.toml since I can’t change it from the VSCode set…

---

## [Some Dagger.jl beginner questions](https://discourse.julialang.org/t/some-dagger-jl-beginner-questions/102704)

<div class="topic-metadata">

**Author:** [@fabiangans](https://discourse.julialang.org/u/fabiangans)\
**Replies:** 6\
**Last updated:** [August 23, 2023, 9:22pm UTC](https://discourse.julialang.org/t/some-dagger-jl-beginner-questions/102704 "2023-08-23T21:22:22Z")

</div>

Hi all, I recently started working with Dagger.jl and have a few questions about controlling the scheduler and merging shards. In my workflow I am doing a mapreduce-like operation over hierarchical data. An abstract ver…

---

## [Fresh install failed to build GR](https://discourse.julialang.org/t/fresh-install-failed-to-build-gr/103134)

<div class="topic-metadata">

**Author:** [@Yly](https://discourse.julialang.org/u/Yly)\
**Replies:** 0\
**Last updated:** [August 23, 2023, 9:06pm UTC](https://discourse.julialang.org/t/fresh-install-failed-to-build-gr/103134 "2023-08-23T21:06:22Z")

</div>

I just installed the latest version of Julia (1.9.2) on a windows machine, which has version 1.7.3 already installed. I ran the new version of Julia and immediately installed Pluto, Plots, and a few other packages. Plo…

---

## [Pydeck julia binding](https://discourse.julialang.org/t/pydeck-julia-binding/89507)

<div class="topic-metadata">

**Author:** [@ctrebbau](https://discourse.julialang.org/u/ctrebbau)\
**Replies:** 1\
**Last updated:** [August 23, 2023, 8:26pm UTC](https://discourse.julialang.org/t/pydeck-julia-binding/89507 "2023-08-23T20:26:54Z")

</div>

I’m unable to set up the PyCall binding to pydeck shown here tutorial Basically yarn bootstrap exits with an error Command failed with exit code 1 trying to build pydeck/julia-pycall-binding branch. I’ve cloned the rep…

---

## [PackageCompiler compilation time \> 2h](https://discourse.julialang.org/t/packagecompiler-compilation-time-2h/101910)

<div class="topic-metadata">

**Author:** [@martin.d.maas](https://discourse.julialang.org/u/martin.d.maas)\
**Replies:** 15\
**Last updated:** [August 23, 2023, 8:22pm UTC](https://discourse.julialang.org/t/packagecompiler-compilation-time-2h/101910 "2023-08-23T20:22:53Z")

</div>

I’m trying to compile my project to a standalone executable with PackageCompiler.jl. I have used PackageCompiler before just for toying around, and I remember compilation times were slow, but now with a real codebase (2…

---

## [Plots/GR in IJulia, larger file](https://discourse.julialang.org/t/plots-gr-in-ijulia-larger-file/103127)

<div class="topic-metadata">

**Author:** [@Paul\_Soderlind](https://discourse.julialang.org/u/Paul_Soderlind)\
**Replies:** 0\
**Last updated:** [August 23, 2023, 7:38pm UTC](https://discourse.julialang.org/t/plots-gr-in-ijulia-larger-file/103127 "2023-08-23T19:38:19Z")

</div>

Since the latest Plots.jl update my ipynb notebooks with plots are much larger (was 200kB, is now 700kB). Any suggestions? (btw. something similar happened before some years ago and was later fixed.)

---

## [How can I change the fontsize of the colorbar's label in Plots.jl?](https://discourse.julialang.org/t/how-can-i-change-the-fontsize-of-the-colorbars-label-in-plots-jl/103108)

<div class="topic-metadata">

**Author:** [@bertulli](https://discourse.julialang.org/u/bertulli)\
**Replies:** 6\
**Last updated:** [August 23, 2023, 5:55pm UTC](https://discourse.julialang.org/t/how-can-i-change-the-fontsize-of-the-colorbars-label-in-plots-jl/103108 "2023-08-23T17:55:55Z")

</div>

Hi all, I have a 2D matrix that I want to plot as an heatmap. It is quite big though (58x58), so plotting it with function pairwise\_difference(v::Vector)::Matrix \[x - y for x in v, y in v\] end measures\_vec = \[t.mea…

---

## [Using Pkg.build() within another build script](https://discourse.julialang.org/t/using-pkg-build-within-another-build-script/103121)

<div class="topic-metadata">

**Author:** [@joegilkes](https://discourse.julialang.org/u/joegilkes)\
**Replies:** 0\
**Last updated:** [August 23, 2023, 4:42pm UTC](https://discourse.julialang.org/t/using-pkg-build-within-another-build-script/103121 "2023-08-23T16:42:14Z")

</div>

I’m trying to write a build script for a package that depends on PyCall.jl. In this build script, a new Conda environment gets created for PyCall to then bind to. PyCall binds to a specific Python executable by calling P…

---

## [REPL crash from attempting a heatmap plot with a large dataset](https://discourse.julialang.org/t/repl-crash-from-attempting-a-heatmap-plot-with-a-large-dataset/103112)

<div class="topic-metadata">

**Author:** [@CosmicSpittle](https://discourse.julialang.org/u/CosmicSpittle)\
**Replies:** 3\
**Last updated:** [August 23, 2023, 4:09pm UTC](https://discourse.julialang.org/t/repl-crash-from-attempting-a-heatmap-plot-with-a-large-dataset/103112 "2023-08-23T16:09:20Z")

</div>

I seemed to be up against a limit on the size of dataset that CairoMakie can handle. I am trying to plot a heatmap of a large spectrogram from DSP.jl. I’ve reduced the problem I’m having to a size issue. Oddly, I was …

---

## [How to detect memory leak in Julia?](https://discourse.julialang.org/t/how-to-detect-memory-leak-in-julia/103110)

<div class="topic-metadata">

**Author:** [@gitboy16](https://discourse.julialang.org/u/gitboy16)\
**Replies:** 0\
**Last updated:** [August 23, 2023, 12:50pm UTC](https://discourse.julialang.org/t/how-to-detect-memory-leak-in-julia/103110 "2023-08-23T12:50:43Z")

</div>

Hi, Just would like to know whether there is a tool to detect memory leak in a script, package or Julia itself? If yes, could you please provide an example for a simple script? Thank you

---

## [Assistance in speeding up Array operations and summations](https://discourse.julialang.org/t/assistance-in-speeding-up-array-operations-and-summations/102989)

<div class="topic-metadata">

**Author:** [@ahmed](https://discourse.julialang.org/u/ahmed)\
**Replies:** 12\
**Last updated:** [August 23, 2023, 12:01pm UTC](https://discourse.julialang.org/t/assistance-in-speeding-up-array-operations-and-summations/102989 "2023-08-23T12:01:00Z")

</div>

I have a problem where I have arrays of matrices that I do operations on and then sum the result. I wonder if I can optimize this part of my code as it will be used repeatedly. Please find below an MWE that reproduces my…

---

## [How to let a function return some numerical values and a graph simutaneously?](https://discourse.julialang.org/t/how-to-let-a-function-return-some-numerical-values-and-a-graph-simutaneously/103101)

<div class="topic-metadata">

**Author:** [@WuSiren](https://discourse.julialang.org/u/WuSiren)\
**Replies:** 1\
**Last updated:** [August 23, 2023, 4:48am UTC](https://discourse.julialang.org/t/how-to-let-a-function-return-some-numerical-values-and-a-graph-simutaneously/103101 "2023-08-23T04:48:49Z")

</div>

For example: using UnicodePlots function func(n) r = randn(n) s = sum(r) hist = histogram(r, nbins=10, closed=:left) r, s, hist end If I call this function in the REPL, it returns: julia\> func(10) (\[1…

---

## [Appending julia objects to a file (JLD)](https://discourse.julialang.org/t/appending-julia-objects-to-a-file-jld/103099)

<div class="topic-metadata">

**Author:** [@cstjean](https://discourse.julialang.org/u/cstjean)\
**Replies:** 0\
**Last updated:** [August 23, 2023, 3:20am UTC](https://discourse.julialang.org/t/appending-julia-objects-to-a-file-jld/103099 "2023-08-23T03:20:13Z")

</div>

I quite like the JSONL format (have a file just be one JSON blob after the other). It’s useful for appending results, logging etc. What would be the equivalent in the julia ecosystem? I want to open("somefile", "a+") do…

---

## [Numerical stability in Turing.jl](https://discourse.julialang.org/t/numerical-stability-in-turing-jl/103035)

<div class="topic-metadata">

**Author:** [@boogiewoogie](https://discourse.julialang.org/u/boogiewoogie)\
**Replies:** 7\
**Last updated:** [August 23, 2023, 2:56am UTC](https://discourse.julialang.org/t/numerical-stability-in-turing-jl/103035 "2023-08-23T02:56:32Z")

</div>

I went through Computational Tricks with Turing \<br/\> (Non-Centered Parametrization \<br/\> and QR Decomposition), where it’s suggested to decorrelate the posterior in a Bayesian regression model by a QR decomposition of t…

---

## [Implementing argument ownership on my own function](https://discourse.julialang.org/t/implementing-argument-ownership-on-my-own-function/103096)

<div class="topic-metadata">

**Author:** [@minetest2048](https://discourse.julialang.org/u/minetest2048)\
**Replies:** 2\
**Last updated:** [August 23, 2023, 1:09am UTC](https://discourse.julialang.org/t/implementing-argument-ownership-on-my-own-function/103096 "2023-08-23T01:09:58Z")

</div>

I want my function to take ownership of the arguments, like how String constructor takes ownership of the UInt8\[\] array: julia\> mybytes = UInt8.(\[125, 119, 48, 126, 40\]); julia\> mystring = String(mybytes) "}w0~(" juli…

---

## [Dispatching on module to prove ownership in package extensions](https://discourse.julialang.org/t/dispatching-on-module-to-prove-ownership-in-package-extensions/103037)

<div class="topic-metadata">

**Author:** [@goerz](https://discourse.julialang.org/u/goerz)\
**Replies:** 7\
**Last updated:** [August 23, 2023, 1:09am UTC](https://discourse.julialang.org/t/dispatching-on-module-to-prove-ownership-in-package-extensions/103037 "2023-08-23T01:09:17Z")

</div>

I was watching @kristoffer.carlsson’s JuliCon talk on Package Extensions and I was quite interested in the discussion about “proving” dependencies to ensure that a user explicitly loads the package for which there is a p…

---

## [Dual y axis appears on the same side in a Pluto notebook with Plots](https://discourse.julialang.org/t/dual-y-axis-appears-on-the-same-side-in-a-pluto-notebook-with-plots/99240)

<div class="topic-metadata">

**Author:** [@PeX](https://discourse.julialang.org/u/PeX)\
**Replies:** 4\
**Last updated:** [August 23, 2023, 12:29am UTC](https://discourse.julialang.org/t/dual-y-axis-appears-on-the-same-side-in-a-pluto-notebook-with-plots/99240 "2023-08-23T00:29:15Z")

</div>

I’m trying to make a plot with dual y axis using Plots in a Pluto notebook. begin plot(randn(100), ylabel="y1", leg=:topright) plot!(twinx(), randn(100)\*10, c=:red, ylabel="y2", leg=:bottomright, size=(6…

---

## [Warning: Method definition f(Any) overwritten](https://discourse.julialang.org/t/warning-method-definition-f-any-overwritten/103060)

<div class="topic-metadata">

**Author:** [@afyon](https://discourse.julialang.org/u/afyon)\
**Replies:** 10\
**Last updated:** [August 22, 2023, 10:45pm UTC](https://discourse.julialang.org/t/warning-method-definition-f-any-overwritten/103060 "2023-08-22T22:45:17Z")

</div>

Hi everyone, I am trying to make a function that would look like this: function create\_f(flag::Bool) if flag f(x) = x^2 else f(x) = x^3 end return f end And, when I create this function, I got …

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

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