# Latest

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

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

**Page:** 447

---

## [Why is push! still so slow?](https://discourse.julialang.org/t/why-is-push-still-so-slow/112170)

<div class="topic-metadata">

**Author:** [@PatrickHaecker](https://discourse.julialang.org/u/PatrickHaecker)\
**Replies:** 39\
**Last updated:** [March 29, 2024, 4:10pm UTC](https://discourse.julialang.org/t/why-is-push-still-so-slow/112170 "2024-03-29T16:10:08Z")

</div>

push! will always have some performance burden if the reserved memory is not large enough. This is to be expected. Here, I am focusing on the case where the new values will fit into the already reserved memory. With Jul…

---

## [CairoMakie stop splitting line into segments when using varying colour along line](https://discourse.julialang.org/t/cairomakie-stop-splitting-line-into-segments-when-using-varying-colour-along-line/112234)

<div class="topic-metadata">

**Author:** [@p\_f](https://discourse.julialang.org/u/p_f)\
**Replies:** 6\
**Last updated:** [March 29, 2024, 3:58pm UTC](https://discourse.julialang.org/t/cairomakie-stop-splitting-line-into-segments-when-using-varying-colour-along-line/112234 "2024-03-29T15:58:27Z")

</div>

When you have a line with varying colour, CairoMakie splits the line up into segments defined by your data points. Is there a way to avoid this? code to produce fig: using CairoMakie f = Figure() ax = Axis(f\[1, 1\]) x…

---

## [How to embed Julia in interactive mode](https://discourse.julialang.org/t/how-to-embed-julia-in-interactive-mode/112264)

<div class="topic-metadata">

**Author:** [@droodman](https://discourse.julialang.org/u/droodman)\
**Replies:** 4\
**Last updated:** [March 29, 2024, 1:50pm UTC](https://discourse.julialang.org/t/how-to-embed-julia-in-interactive-mode/112264 "2024-03-29T13:50:42Z")

</div>

Another in my continuing series of questions about how to embed Julia… @mkitti and @GunnarFarneback have been very helpful in the past. I am embedding Julia in another program and am trying to approximately simulate th…

---

## [Turing.jl for geophysical applications](https://discourse.julialang.org/t/turing-jl-for-geophysical-applications/107197)

<div class="topic-metadata">

**Author:** [@Alejandro\_Quiaro\_San](https://discourse.julialang.org/u/Alejandro_Quiaro_San)\
**Replies:** 5\
**Last updated:** [March 29, 2024, 1:29pm UTC](https://discourse.julialang.org/t/turing-jl-for-geophysical-applications/107197 "2024-03-29T13:29:07Z")

</div>

Hello everyone. I am writing this post with the hope that It helps people with background in physics, and want to learn about probabilistic programming using Turing.jl. My background is geophysics, and I only have a cou…

---

## [Does Julia libraries exists?](https://discourse.julialang.org/t/does-julia-libraries-exists/112278)

<div class="topic-metadata">

**Author:** [@KZiemian](https://discourse.julialang.org/u/KZiemian)\
**Replies:** 2\
**Last updated:** [March 29, 2024, 11:26am UTC](https://discourse.julialang.org/t/does-julia-libraries-exists/112278 "2024-03-29T11:26:23Z")

</div>

It may be stupid noob question. I watched Low Level Learning episode Why rust libraries may never exist, which say something like that. Normal C library is external binary that we can linked in different ways, to use wit…

---

## [Macros not evaluating as per expectation](https://discourse.julialang.org/t/macros-not-evaluating-as-per-expectation/112252)

<div class="topic-metadata">

**Author:** [@kishaloy](https://discourse.julialang.org/u/kishaloy)\
**Replies:** 12\
**Last updated:** [March 29, 2024, 11:21am UTC](https://discourse.julialang.org/t/macros-not-evaluating-as-per-expectation/112252 "2024-03-29T11:21:01Z")

</div>

I am facing a problem in understanding why my macro works the way it does. I have the following macro macro create\_m(m) y = :(a + b \* c + 1) y.args\[3\].args\[2\] = :(2 \* $m) dxr = m global dxy = 2 \* m …

---

## [Memory usage blow up on julia 1.9](https://discourse.julialang.org/t/memory-usage-blow-up-on-julia-1-9/103869)

<div class="topic-metadata">

**Author:** [@cstjean](https://discourse.julialang.org/u/cstjean)\
**Replies:** 5\
**Last updated:** [March 29, 2024, 10:32am UTC](https://discourse.julialang.org/t/memory-usage-blow-up-on-julia-1-9/103869 "2024-03-29T10:32:10Z")

</div>

Our in-house application has been seeing huge memory usage spikes since our upgrade to 1.9 (5x what was used before). Has anyone else experienced that? The new feature is a likely culprit, but we’re still early in our in…

---

## [Packages with \`\_\_init()\_\_\` screws up PackageCompiler.jl?](https://discourse.julialang.org/t/packages-with-init-screws-up-packagecompiler-jl/112243)

<div class="topic-metadata">

**Author:** [@biona001](https://discourse.julialang.org/u/biona001)\
**Replies:** 2\
**Last updated:** [March 29, 2024, 9:50am UTC](https://discourse.julialang.org/t/packages-with-init-screws-up-packagecompiler-jl/112243 "2024-03-29T09:50:46Z")

</div>

Cross-posted on PackageCompiler.jl. I’m building binaries with PackageCompiler.create\_app(), but I get an alarming warning message whenever a dependency has an \_\_init()\_\_ function that includes a @require block, exempli…

---

## [Using local namespaces in Pluto](https://discourse.julialang.org/t/using-local-namespaces-in-pluto/112238)

<div class="topic-metadata">

**Author:** [@user23804985096787](https://discourse.julialang.org/u/user23804985096787)\
**Replies:** 2\
**Last updated:** [March 29, 2024, 9:15am UTC](https://discourse.julialang.org/t/using-local-namespaces-in-pluto/112238 "2024-03-29T09:15:11Z")

</div>

Very basic question: I am writing some code in Pluto and can’t work out how to properly use local modules/namespaces. When using Jupyter notebooks, I can create local modules (either inside the notebook or in a local fi…

---

## [Testing a string macro](https://discourse.julialang.org/t/testing-a-string-macro/112244)

<div class="topic-metadata">

**Author:** [@GHTaarn](https://discourse.julialang.org/u/GHTaarn)\
**Replies:** 10\
**Last updated:** [March 29, 2024, 9:12am UTC](https://discourse.julialang.org/t/testing-a-string-macro/112244 "2024-03-29T09:12:30Z")

</div>

The code using Test xx = Dict{String,String}() macro x\_str(str,suf) return str \* xx\[suf\] end @testset "a" begin xx\["a"\] = "apple" @test x"tasty "a == "tasty apple" end Throws an error: ERROR: LoadError:…

---

## [JuliaCon 2024 Early Bird Tickets are Limited](https://discourse.julialang.org/t/juliacon-2024-early-bird-tickets-are-limited/112267)

<div class="topic-metadata">

**Author:** [@mkitti](https://discourse.julialang.org/u/mkitti)\
**Replies:** 0\
**Last updated:** [March 29, 2024, 5:24am UTC](https://discourse.julialang.org/t/juliacon-2024-early-bird-tickets-are-limited/112267 "2024-03-29T05:24:43Z")

</div>

Hi everyone, JuliaCon 2024 early bird tickets are selling quickly and are available on a limited basis until the schedule is announced, which is very soon. Since we’re already looking nearly complete schedule drafts, I …

---

## [GSoC projects 2024](https://discourse.julialang.org/t/gsoc-projects-2024/110994)

<div class="topic-metadata">

**Author:** [@fracton](https://discourse.julialang.org/u/fracton)\
**Replies:** 1\
**Last updated:** [March 29, 2024, 4:22am UTC](https://discourse.julialang.org/t/gsoc-projects-2024/110994 "2024-03-29T04:22:27Z")

</div>

Hi! I’ve been looking to apply for GSoC 2024 and, wanted to know if there are any projects for julia. I’ve found this list on julialang.org and, was wondering if there’s any mentors here who’d like to chat about their p…

---

## [Fast implementation of incomplete extended gamma function, QuadGK?](https://discourse.julialang.org/t/fast-implementation-of-incomplete-extended-gamma-function-quadgk/112239)

<div class="topic-metadata">

**Author:** [@mleprovost](https://discourse.julialang.org/u/mleprovost)\
**Replies:** 4\
**Last updated:** [March 29, 2024, 3:10am UTC](https://discourse.julialang.org/t/fast-implementation-of-incomplete-extended-gamma-function-quadgk/112239 "2024-03-29T03:10:42Z")

</div>

Hello, I am interested in developing a fast routine to compute the following extended incomplete gamma function for various pairs (x, q). \\gamma(\\alpha, \\kappa, p, q)(x) = \\int\_{0}^x t^{\\alpha-1} \\exp( -\\frac{t^\\kappa}…

---

## [The improvement of memory management in multithreading Julia 1.10beta is amazing!](https://discourse.julialang.org/t/the-improvement-of-memory-management-in-multithreading-julia-1-10beta-is-amazing/102468)

<div class="topic-metadata">

**Author:** [@liuyxpp](https://discourse.julialang.org/u/liuyxpp)\
**Replies:** 6\
**Last updated:** [March 29, 2024, 2:30am UTC](https://discourse.julialang.org/t/the-improvement-of-memory-management-in-multithreading-julia-1-10beta-is-amazing/102468 "2024-03-29T02:30:54Z")

</div>

I am so happy and can not help to share here. I have a multithreading script that reads tons of CSV files, processes them, and saves each back to disk. before 1.10, I see a continuous growing of memory usage like insanel…

---

## [How can we create more basic Enzyme custom rules?](https://discourse.julialang.org/t/how-can-we-create-more-basic-enzyme-custom-rules/112174)

<div class="topic-metadata">

**Author:** [@ToPo](https://discourse.julialang.org/u/ToPo)\
**Replies:** 3\
**Last updated:** [March 27, 2024, 3:37pm UTC](https://discourse.julialang.org/t/how-can-we-create-more-basic-enzyme-custom-rules/112174 "2024-03-27T15:37:37Z")

</div>

I am trying to create custom rules for Enzyme. I looked at the examples on Enzyme’s official website, but unfortunately could not fully understand them due to difficulty. As a very simple example to try, I created a pr…

---

## [Sparse matrix error with forward diff](https://discourse.julialang.org/t/sparse-matrix-error-with-forward-diff/108170)

<div class="topic-metadata">

**Author:** [@slwu89](https://discourse.julialang.org/u/slwu89)\
**Replies:** 16\
**Last updated:** [March 29, 2024, 1:53am UTC](https://discourse.julialang.org/t/sparse-matrix-error-with-forward-diff/108170 "2024-03-29T01:53:38Z")

</div>

Hi all. I have the following MWE. I get a stackoverflow error when using a sparse matrix in a function that I am using ForwardDiff to find the gradient of. When using a dense matrix (i.e. change W1s to W1d in the anonymo…

---

## [How to speed up dense-sparse matrix multiplication where the sparse matrix is in CSC?](https://discourse.julialang.org/t/how-to-speed-up-dense-sparse-matrix-multiplication-where-the-sparse-matrix-is-in-csc/112260)

<div class="topic-metadata">

**Author:** [@yhuang](https://discourse.julialang.org/u/yhuang)\
**Replies:** 0\
**Last updated:** [March 28, 2024, 11:32pm UTC](https://discourse.julialang.org/t/how-to-speed-up-dense-sparse-matrix-multiplication-where-the-sparse-matrix-is-in-csc/112260 "2024-03-28T23:32:14Z")

</div>

For a sparse matrix stored in CSC format, without using MKLSparse, left multiplying it by a dense matrix is faster than right multiplying it by a dense matrix. This is quite intuitive because the sparse matrix is in CSC,…

---

## [More allocation in for loop than broadcast](https://discourse.julialang.org/t/more-allocation-in-for-loop-than-broadcast/112257)

<div class="topic-metadata">

**Author:** [@yuehao](https://discourse.julialang.org/u/yuehao)\
**Replies:** 4\
**Last updated:** [March 28, 2024, 11:09pm UTC](https://discourse.julialang.org/t/more-allocation-in-for-loop-than-broadcast/112257 "2024-03-28T23:09:12Z")

</div>

I am new to Julia and writing a simulation code to track the particle motion. Here is a simplified version of my code: using BenchmarkTools using StructArrays using StaticArrays struct ps3d # 6D phase space x::Flo…

---

## [NeuralPDE issue trying to use LuxAMDGPU](https://discourse.julialang.org/t/neuralpde-issue-trying-to-use-luxamdgpu/111567)

<div class="topic-metadata">

**Author:** [@mre](https://discourse.julialang.org/u/mre)\
**Replies:** 15\
**Last updated:** [March 28, 2024, 10:40pm UTC](https://discourse.julialang.org/t/neuralpde-issue-trying-to-use-luxamdgpu/111567 "2024-03-28T22:40:17Z")

</div>

Hi everyone, as a Julia newbie, I tried to solve a simple bvp with NeuralPDE and GPUs. Using LuxCUDA on nvidia hardware, everything was fine. After switching to LuxAMDGPU (and AMD hardware) the code did not work any…

---

## [Forcing format for Float in TOML file](https://discourse.julialang.org/t/forcing-format-for-float-in-toml-file/112253)

<div class="topic-metadata">

**Author:** [@shiroghost](https://discourse.julialang.org/u/shiroghost)\
**Replies:** 0\
**Last updated:** [March 28, 2024, 8:51pm UTC](https://discourse.julialang.org/t/forcing-format-for-float-in-toml-file/112253 "2024-03-28T20:51:20Z")

</div>

Hi all, Is there a way to force that, when writting a TOML file, all Float are written as %24.12e (or any other specific format)? Thanks, A.

---

## [Plotting text with GLMakie](https://discourse.julialang.org/t/plotting-text-with-glmakie/112230)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 22\
**Last updated:** [March 28, 2024, 6:34pm UTC](https://discourse.julialang.org/t/plotting-text-with-glmakie/112230 "2024-03-28T18:34:23Z")

</div>

I am trying to plot text in a GLMakie window. My code: import GLMakie fig = GLMakie.Figure(size = (400, 400)) ax = GLMakie.Axis(fig\[1,1\]) GLMakie.text!(0, 20; text="Hello", show\_axis = false, fontsize =…

---

## [Discriminate between NaN and Inf in plots](https://discourse.julialang.org/t/discriminate-between-nan-and-inf-in-plots/112171)

<div class="topic-metadata">

**Author:** [@Fourier](https://discourse.julialang.org/u/Fourier)\
**Replies:** 7\
**Last updated:** [March 28, 2024, 6:13pm UTC](https://discourse.julialang.org/t/discriminate-between-nan-and-inf-in-plots/112171 "2024-03-28T18:13:05Z")

</div>

I have a plot where some values originate from devision by 0 and some originate from 0/0, I would like to add new colours to the heatmap to descriminate between them. Does anyone have an idea on how to do this in plots.…

---

## [\[ann\] FinEtoolsMultithreading](https://discourse.julialang.org/t/ann-finetoolsmultithreading/112245)

<div class="topic-metadata">

**Author:** [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Replies:** 0\
**Last updated:** [March 28, 2024, 6:08pm UTC](https://discourse.julialang.org/t/ann-finetoolsmultithreading/112245 "2024-03-28T18:08:05Z")

</div>

A package parallelizing finite element matrix assembly for the FinEtools application packages on multicore machines is now generally usable. A paper has been submitted and is under review. (Link https://dx.doi.org/10.2…

---

## [Is it type-piracy to define \`Base.parse(::Type{Tuple}, str)\`?](https://discourse.julialang.org/t/is-it-type-piracy-to-define-base-parse-type-tuple-str/112229)

<div class="topic-metadata">

**Author:** [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)\
**Replies:** 5\
**Last updated:** [March 28, 2024, 5:41pm UTC](https://discourse.julialang.org/t/is-it-type-piracy-to-define-base-parse-type-tuple-str/112229 "2024-03-28T17:41:05Z")

</div>

type piracy is a thing in julia. I am wondering whether or under which circumstances it is fine to define something like Base.parse(::Type{Tuple}, str) = ... i.e. a Base function for a Base Type. Or should you better …

---

## [ANN: StringUnits.jl](https://discourse.julialang.org/t/ann-stringunits-jl/112202)

<div class="topic-metadata">

**Author:** [@mnemnion](https://discourse.julialang.org/u/mnemnion)\
**Replies:** 8\
**Last updated:** [March 28, 2024, 5:28pm UTC](https://discourse.julialang.org/t/ann-stringunits-jl/112202 "2024-03-28T17:28:00Z")

</div>

Inspired by this lengthy thread, which I jumped into somewhat later, I’ve implemented the idea as StringUnits.jl. Pretty straightforward: julia\> "aβc∅👨🏻‍🌾efg"\[2ch:4ch\] "βc∅" julia\> "aβc∅👨🏻‍🌾efg"\[5gr\] "👨🏻‍🌾" julia\> "a…

---

## [Accessing children nodes in the SDDP package](https://discourse.julialang.org/t/accessing-children-nodes-in-the-sddp-package/112140)

<div class="topic-metadata">

**Author:** [@heiwie](https://discourse.julialang.org/u/heiwie)\
**Replies:** 8\
**Last updated:** [March 28, 2024, 5:22pm UTC](https://discourse.julialang.org/t/accessing-children-nodes-in-the-sddp-package/112140 "2024-03-28T17:22:37Z")

</div>

I have an optimization problem where one of the constraints is a convex non-linear constraint on the following form: Here w, eta and x are decision variables. All variables with an m index are variables corresponding …

---

## [\[Workgroup\] JuliaHealth Meeting (Americas/Europe/Africa) -- March 28th, 2024](https://discourse.julialang.org/t/workgroup-juliahealth-meeting-americas-europe-africa-march-28th-2024/111980)

<div class="topic-metadata">

**Author:** [@TheCedarPrince](https://discourse.julialang.org/u/TheCedarPrince)\
**Replies:** 2\
**Last updated:** [March 28, 2024, 4:07pm UTC](https://discourse.julialang.org/t/workgroup-juliahealth-meeting-americas-europe-africa-march-28th-2024/111980 "2024-03-28T16:07:49Z")

</div>

Hi folks :wave: I am thrilled to announce this month’s agenda for the Americas/Africa/Europe call! We have some exciting topics to cover including a guest talk from Dr. Katherine Rosenfeld from the Bill and Melinda Gate…

---

## [Struct containing differently-sized Static Vectors](https://discourse.julialang.org/t/struct-containing-differently-sized-static-vectors/112231)

<div class="topic-metadata">

**Author:** [@leapsheep](https://discourse.julialang.org/u/leapsheep)\
**Replies:** 4\
**Last updated:** [March 28, 2024, 2:13pm UTC](https://discourse.julialang.org/t/struct-containing-differently-sized-static-vectors/112231 "2024-03-28T14:13:18Z")

</div>

I want to define a struct for a cluster of particles that each have a position and orientation in space. I would like my representation to work for both 2D and 3D, which is a bit tricky since in 2D I represent orientatio…

---

## [\`Spy\` function behavior with sparse matrices](https://discourse.julialang.org/t/spy-function-behavior-with-sparse-matrices/112232)

<div class="topic-metadata">

**Author:** [@fimiller](https://discourse.julialang.org/u/fimiller)\
**Replies:** 2\
**Last updated:** [March 28, 2024, 1:58pm UTC](https://discourse.julialang.org/t/spy-function-behavior-with-sparse-matrices/112232 "2024-03-28T13:58:18Z")

</div>

I am trying to generate sparsity patterns for some matrices for a project. However, I cannot seem to find the necessary command to make all the sparsity patterns the same size. Below is an example and the output: A = sp…

---

## [Strange situation RF Classification: perfect train, test prediction all one category](https://discourse.julialang.org/t/strange-situation-rf-classification-perfect-train-test-prediction-all-one-category/112222)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 2\
**Last updated:** [March 28, 2024, 1:45pm UTC](https://discourse.julialang.org/t/strange-situation-rf-classification-perfect-train-test-prediction-all-one-category/112222 "2024-03-28T13:45:49Z")

</div>

I am puzzled by an issue with a boolean classification task using RF on a large dimensional dataset (1680 obs x 110 dim) and moderate imbalance (431 vs 1249). train/test partition is random (0.8,0.2) When I train the R…

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

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