# General Usage

**URL:** https://discourse.julialang.org/c/usage/6.md?page=65

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

**Page:** 66

---

## [Use an internal struct of an extension \`ABExt\` in another extension \`ABCExt\`](https://discourse.julialang.org/t/use-an-internal-struct-of-an-extension-abext-in-another-extension-abcext/128797)

<div class="topic-metadata">

**Author:** [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Replies:** 0\
**Last updated:** [May 7, 2025, 2:08pm UTC](https://discourse.julialang.org/t/use-an-internal-struct-of-an-extension-abext-in-another-extension-abcext/128797 "2025-05-07T14:08:50Z")

</div>

For context, the full example I am working on are the two extensions Manopt.jl/ext/ManoptJuMPExt.jl at kellertuer/JuMP-vectorize · JuliaManifolds/Manopt.jl · GitHub Manopt.jl/ext/ManoptJuMPManifoldsExt.jl at kellertuer…

---

## [Updating many curves in Makie simultaneously](https://discourse.julialang.org/t/updating-many-curves-in-makie-simultaneously/128796)

<div class="topic-metadata">

**Author:** [@xor0110](https://discourse.julialang.org/u/xor0110)\
**Replies:** 0\
**Last updated:** [May 7, 2025, 1:31pm UTC](https://discourse.julialang.org/t/updating-many-curves-in-makie-simultaneously/128796 "2025-05-07T13:31:46Z")

</div>

As the Makie documentation points out, things are pretty straight-forward if you’re just changing one plot from one scrollbar, but it can become weird working with observables if there are many interdependecies. I’m c…

---

## [Avoiding segfault on exit when using QML.jl](https://discourse.julialang.org/t/avoiding-segfault-on-exit-when-using-qml-jl/128737)

<div class="topic-metadata">

**Author:** [@Tetrakai](https://discourse.julialang.org/u/Tetrakai)\
**Replies:** 11\
**Last updated:** [May 7, 2025, 11:02am UTC](https://discourse.julialang.org/t/avoiding-segfault-on-exit-when-using-qml-jl/128737 "2025-05-07T11:02:51Z")

</div>

My real code runs great, but for some reason gives a segfault when exiting the Julia REPL. Then I saw JuliaPropertyMaps should be a function in the docs . I modified the doc example to show my problem (I need “Hi” to be…

---

## [Possible speedup in matrix-diagonal products?](https://discourse.julialang.org/t/possible-speedup-in-matrix-diagonal-products/68474)

<div class="topic-metadata">

**Author:** [@jishnub](https://discourse.julialang.org/u/jishnub)\
**Replies:** 6\
**Last updated:** [May 7, 2025, 9:11am UTC](https://discourse.julialang.org/t/possible-speedup-in-matrix-diagonal-products/68474 "2025-05-07T09:11:24Z")

</div>

Right multiplication by a Diagonal matrix effectively scales the columns of a matrix. Currently the default Matrix-Diagonal product appears to use copy\_similar: (\*)(A::AbstractMatrix, D::Diagonal) = rmul!(copy\_simil…

---

## [Are there a Chordal sparse matrix function?](https://discourse.julialang.org/t/are-there-a-chordal-sparse-matrix-function/21611)

<div class="topic-metadata">

**Author:** [@erikfilias](https://discourse.julialang.org/u/erikfilias)\
**Replies:** 1\
**Last updated:** [May 7, 2025, 1:03am UTC](https://discourse.julialang.org/t/are-there-a-chordal-sparse-matrix-function/21611 "2025-05-07T01:03:50Z")

</div>

I work in Convex Optimization, and I look for any function like a Python’s Chordal Matrix Package. Are there something like that in JuliaLang?

---

## [Is there a collection of matrices like Matlab's gallery?](https://discourse.julialang.org/t/is-there-a-collection-of-matrices-like-matlabs-gallery/128770)

<div class="topic-metadata">

**Author:** [@HMegh](https://discourse.julialang.org/u/HMegh)\
**Replies:** 2\
**Last updated:** [May 6, 2025, 10:37pm UTC](https://discourse.julialang.org/t/is-there-a-collection-of-matrices-like-matlabs-gallery/128770 "2025-05-06T22:37:12Z")

</div>

Hi everyone, Since Julia is very suitable for experimenting with new numerical methods, I was wondering if there is a collection of “famous” matrices somewhere. I am thinking of something like Matlab’s gallery of matric…

---

## [Passing a BigInt (mpz\_t for GMP) array to C](https://discourse.julialang.org/t/passing-a-bigint-mpz-t-for-gmp-array-to-c/123622)

<div class="topic-metadata">

**Author:** [@Questioner](https://discourse.julialang.org/u/Questioner)\
**Replies:** 20\
**Last updated:** [May 6, 2025, 8:36pm UTC](https://discourse.julialang.org/t/passing-a-bigint-mpz-t-for-gmp-array-to-c/123622 "2025-05-06T20:36:14Z")

</div>

Lately, I’ve managed to pass a BigInt to C and back (Passing GMP variables from C(++) to Julia - #10 by Questioner). Now suppose I want to generate Fibonacci numbers in C and pass them to Julia. I thought I just take the…

---

## [NonlinearSolve.jl with Sparse Jacobian: J isn't square?!](https://discourse.julialang.org/t/nonlinearsolve-jl-with-sparse-jacobian-j-isnt-square/128768)

<div class="topic-metadata">

**Author:** [@luke-kiernan](https://discourse.julialang.org/u/luke-kiernan)\
**Replies:** 0\
**Last updated:** [May 6, 2025, 8:22pm UTC](https://discourse.julialang.org/t/nonlinearsolve-jl-with-sparse-jacobian-j-isnt-square/128768 "2025-05-06T20:22:15Z")

</div>

I’m trying to use NonlinearSolve.jl’s LevenbergMarquardt solver on a powerflow. The solve call yields an error: LoadError: ArgumentError: KLU only accepts square matrices. That seems nonsensical: J0 is square. I expect t…

---

## [Removing directory contents recursively](https://discourse.julialang.org/t/removing-directory-contents-recursively/128761)

<div class="topic-metadata">

**Author:** [@floswald](https://discourse.julialang.org/u/floswald)\
**Replies:** 6\
**Last updated:** [May 6, 2025, 4:31pm UTC](https://discourse.julialang.org/t/removing-directory-contents-recursively/128761 "2025-05-06T16:31:50Z")

</div>

Hi all, still struggling with this. I want to run command rm -rf /path/to/dir/\*, so that I delete the content but not the dir itself. I get this julia\> Base.run(\`rm -rf $(ReproData.root())/code/"\*"\`) Process(\`rm -rf '/…

---

## [Quoting in shell commands](https://discourse.julialang.org/t/quoting-in-shell-commands/6781)

<div class="topic-metadata">

**Author:** [@harven](https://discourse.julialang.org/u/harven)\
**Replies:** 5\
**Last updated:** [October 30, 2017, 6:46pm UTC](https://discourse.julialang.org/t/quoting-in-shell-commands/6781 "2017-10-30T18:46:27Z")

</div>

I don’t understand the new behavior of the shell wrt quotation. Assuming that there are files in the current directory starting by img, how do I execute the following shell command from julia? $ ls -l img\* The foll…

---

## [Calling module specific method with same type signature (AbstractFFT, FFTW, FFTA)](https://discourse.julialang.org/t/calling-module-specific-method-with-same-type-signature-abstractfft-fftw-ffta/128750)

<div class="topic-metadata">

**Author:** [@jtravs](https://discourse.julialang.org/u/jtravs)\
**Replies:** 1\
**Last updated:** [May 6, 2025, 2:59pm UTC](https://discourse.julialang.org/t/calling-module-specific-method-with-same-type-signature-abstractfft-fftw-ffta/128750 "2025-05-06T14:59:12Z")

</div>

Consider the following example. If I run using FFTA a = rand(ComplexF64, 128) p = FFTA.plan\_fft(a) typeof(p) I get FFTA.FFTAPlan\_cx{ComplexF64, 1} but if I run using FFTA, FFTW a = rand(ComplexF64, 128) p = FFTA.pl…

---

## [Latency discrepancy in a busy loop with IO and without](https://discourse.julialang.org/t/latency-discrepancy-in-a-busy-loop-with-io-and-without/128718)

<div class="topic-metadata">

**Author:** [@Dmitry\_Vels](https://discourse.julialang.org/u/Dmitry_Vels)\
**Replies:** 2\
**Last updated:** [May 6, 2025, 2:56pm UTC](https://discourse.julialang.org/t/latency-discrepancy-in-a-busy-loop-with-io-and-without/128718 "2025-05-06T14:56:03Z")

</div>

Hi! I am trying to use Julia in the same domain where previously I used C/C++ (low latency) In general if you avoid allocations, and do everything proper (type stable) the speed is impressive, and comparable with C++. …

---

## [HTTP.jl client layer](https://discourse.julialang.org/t/http-jl-client-layer/128098)

<div class="topic-metadata">

**Author:** [@ohmsweetohm1](https://discourse.julialang.org/u/ohmsweetohm1)\
**Replies:** 4\
**Last updated:** [May 6, 2025, 2:44pm UTC](https://discourse.julialang.org/t/http-jl-client-layer/128098 "2025-05-06T14:44:21Z")

</div>

I’m trying to implement an auth layer for HTTP.jl module ApiClient import HTTP import Dates import JSON Base.@kwdef struct TokenInfo access\_token::String = "" expires\_at::Dates.DateTime = Dates.now(Dates.UTC) …

---

## [Why \`∋\` (\`\\ni\`) is not a method of \`contains\`?](https://discourse.julialang.org/t/why-ni-is-not-a-method-of-contains/128748)

<div class="topic-metadata">

**Author:** [@heliosdrm](https://discourse.julialang.org/u/heliosdrm)\
**Replies:** 3\
**Last updated:** [May 6, 2025, 2:30pm UTC](https://discourse.julialang.org/t/why-ni-is-not-a-method-of-contains/128748 "2025-05-06T14:30:15Z")

</div>

in(x) is a convenient function generator to check whether other variables are contained in x (e.g. for filtering). I was looking for a generator of functions that do the opposite (check if other variables contain x), and…

---

## [Patient Level Prediction in Julia Blog Series](https://discourse.julialang.org/t/patient-level-prediction-in-julia-blog-series/128758)

<div class="topic-metadata">

**Author:** [@TheCedarPrince](https://discourse.julialang.org/u/TheCedarPrince)\
**Replies:** 0\
**Last updated:** [May 6, 2025, 1:42pm UTC](https://discourse.julialang.org/t/patient-level-prediction-in-julia-blog-series/128758 "2025-05-06T13:42:18Z")

</div>

NOTE: JuliaHealth contributor, @kosuri-indu, wrote a great series on Patient Level Prediction Julia workflows! She can’t post links to Discourse so I am posting her work below! Introduction Hello everyone! I’m Kosuri …

---

## [Cannot open REPL in VSCode or on command line this morning (after long weekend)](https://discourse.julialang.org/t/cannot-open-repl-in-vscode-or-on-command-line-this-morning-after-long-weekend/128749)

<div class="topic-metadata">

**Author:** [@TimG](https://discourse.julialang.org/u/TimG)\
**Replies:** 3\
**Last updated:** [May 6, 2025, 11:52am UTC](https://discourse.julialang.org/t/cannot-open-repl-in-vscode-or-on-command-line-this-morning-after-long-weekend/128749 "2025-05-06T11:52:12Z")

</div>

Using Alt-J, Alt-O usually opens the REPL in VS-Code. This morning, it generates the below error, which was hard to capture because it disappears a fraction of a second after appearing. If I open a Julia REPL at the com…

---

## [Profile results contains no samples from my code](https://discourse.julialang.org/t/profile-results-contains-no-samples-from-my-code/128630)

<div class="topic-metadata">

**Author:** [@xor0110](https://discourse.julialang.org/u/xor0110)\
**Replies:** 2\
**Last updated:** [May 6, 2025, 7:52am UTC](https://discourse.julialang.org/t/profile-results-contains-no-samples-from-my-code/128630 "2025-05-06T07:52:25Z")

</div>

I’m trying to profile my code, the analysis takes a minute or so to run with the cpu at 50%. But no matter what I do, running @profile or @profview gives me results that seem to have no samples from my code. For instance…

---

## [\`rev\_cumsum\_exp!()\` optimization](https://discourse.julialang.org/t/rev-cumsum-exp-optimization/128664)

<div class="topic-metadata">

**Author:** [@lrnv](https://discourse.julialang.org/u/lrnv)\
**Replies:** 12\
**Last updated:** [May 6, 2025, 6:24am UTC](https://discourse.julialang.org/t/rev-cumsum-exp-optimization/128664 "2025-05-06T06:24:16Z")

</div>

Another weird operation to be optimized: function rev\_cumsum\_exp!(A,B,source) # This is equivalent to : # A .= exp(source) # B .= 1 ./ reverse(cumsum(reverse(A)))) s = zero(eltype(A)) fo…

---

## [Using standard library modules in packages](https://discourse.julialang.org/t/using-standard-library-modules-in-packages/128719)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 2\
**Last updated:** [May 6, 2025, 1:23am UTC](https://discourse.julialang.org/t/using-standard-library-modules-in-packages/128719 "2025-05-06T01:23:10Z")

</div>

Hello, as result of the stlib excision effort, packages that now (Julia 1.11 ??) want to import a module from the standard library, they need to declare the corresponding package in their Project.toml, right?

---

## [How to get the exif tags of a Tiff images using Julia](https://discourse.julialang.org/t/how-to-get-the-exif-tags-of-a-tiff-images-using-julia/128697)

<div class="topic-metadata">

**Author:** [@Mend-Amar\_Badral](https://discourse.julialang.org/u/Mend-Amar_Badral)\
**Replies:** 4\
**Last updated:** [May 6, 2025, 1:22am UTC](https://discourse.julialang.org/t/how-to-get-the-exif-tags-of-a-tiff-images-using-julia/128697 "2025-05-06T01:22:37Z")

</div>

Hello, I have few drone images and want to read the exif tags. I can do that easily with command line exiftool application but haven’t managed to find a package that reads exif from TIF files. The Exifviewer.jl package o…

---

## [ContinuousCallback does not work for backward integration](https://discourse.julialang.org/t/continuouscallback-does-not-work-for-backward-integration/128736)

<div class="topic-metadata">

**Author:** [@xiaoming](https://discourse.julialang.org/u/xiaoming)\
**Replies:** 2\
**Last updated:** [May 5, 2025, 11:08pm UTC](https://discourse.julialang.org/t/continuouscallback-does-not-work-for-backward-integration/128736 "2025-05-05T23:08:13Z")

</div>

An MME: using StaticArrays, OrdinaryDiffEq f(x, p, t) = SA\[x\[2\], -x\[1\]\] function affect!(integrator) (u0, u1) = integrator.u integrator.u = SA\[u0, -u1\] end function condition(u, t, integrator) u\[1\] end cb = …

---

## [Equality of unwrapped unionalls](https://discourse.julialang.org/t/equality-of-unwrapped-unionalls/128716)

<div class="topic-metadata">

**Author:** [@cshen](https://discourse.julialang.org/u/cshen)\
**Replies:** 3\
**Last updated:** [May 5, 2025, 2:51pm UTC](https://discourse.julialang.org/t/equality-of-unwrapped-unionalls/128716 "2025-05-05T14:51:03Z")

</div>

Say you have the following struct struct MyArr{T,N} arr::Array{T,N} end I was then wondering why the following equality does not hold: unwrap\_arr\_field = fieldtypes(Base.unwrap\_unionall(MyArr))\[1\] unwrap\_arr\_manual …

---

## [Revise type annotations without edits?](https://discourse.julialang.org/t/revise-type-annotations-without-edits/128700)

<div class="topic-metadata">

**Author:** [@Benny](https://discourse.julialang.org/u/Benny)\
**Replies:** 0\
**Last updated:** [May 5, 2025, 4:16am UTC](https://discourse.julialang.org/t/revise-type-annotations-without-edits/128700 "2025-05-05T04:16:03Z")

</div>

Because of the upcoming world age-partitioned semantics (PR #57253), Revise can pull off type redefinitions by reassigning the const name (Issue #18). Let’s say we start with: julia\> begin struct X{T} x::T end; …

---

## [Statically Compiled Julia for (Python) Library Development (at PyData Global 2024) - Jeff Bezanson](https://discourse.julialang.org/t/statically-compiled-julia-for-python-library-development-at-pydata-global-2024-jeff-bezanson/128703)

<div class="topic-metadata">

**Author:** [@mkitti](https://discourse.julialang.org/u/mkitti)\
**Replies:** 0\
**Last updated:** [May 5, 2025, 5:49am UTC](https://discourse.julialang.org/t/statically-compiled-julia-for-python-library-development-at-pydata-global-2024-jeff-bezanson/128703 "2025-05-05T05:49:17Z")

</div>

Statically Compiled Julia for Library Development (at PyData Global 2024) @jeff.bezanson Jeff Bezanson gave a talk about static compilation of Julia for library development at PyData Global 2024 in Decembe…

---

## [How to reuse parent Project.toml information](https://discourse.julialang.org/t/how-to-reuse-parent-project-toml-information/128690)

<div class="topic-metadata">

**Author:** [@Abhro](https://discourse.julialang.org/u/Abhro)\
**Replies:** 2\
**Last updated:** [May 4, 2025, 4:11pm UTC](https://discourse.julialang.org/t/how-to-reuse-parent-project-toml-information/128690 "2025-05-04T16:11:49Z")

</div>

In the makedocs() call of docs/Project.toml, how do I use package information, say the authors, from its Project.toml? MWE: using MyPackage using Documenter makedocs(; modules = \[MyPackage\], authors = get\_auth…

---

## [Simulating keystrokes to external program](https://discourse.julialang.org/t/simulating-keystrokes-to-external-program/128229)

<div class="topic-metadata">

**Author:** [@theogf](https://discourse.julialang.org/u/theogf)\
**Replies:** 3\
**Last updated:** [May 4, 2025, 12:08pm UTC](https://discourse.julialang.org/t/simulating-keystrokes-to-external-program/128229 "2025-05-04T12:08:39Z")

</div>

Hi! I have a package that makes a heavy use of fzf. I would like to test things more thoroughly but this requires interactive actions on fzf itself. I am aware of GitHub - Keno/VT100.jl: Terminal Emulation for terminal…

---

## [Checking strided array storage order](https://discourse.julialang.org/t/checking-strided-array-storage-order/128685)

<div class="topic-metadata">

**Author:** [@stemann](https://discourse.julialang.org/u/stemann)\
**Replies:** 1\
**Last updated:** [May 4, 2025, 11:18am UTC](https://discourse.julialang.org/t/checking-strided-array-storage-order/128685 "2025-05-04T11:18:08Z")

</div>

Is strides(array) == Base.size\_to\_strides(1, size(array)...) a sane way to check if a strided array is in column-major (alias co-lexicographic, alias Fortran, alias Julia) order, storage-wise? Cf. julia/base/abstracta…

---

## [Difference between vector of functions typed explicitly or via list comprehension](https://discourse.julialang.org/t/difference-between-vector-of-functions-typed-explicitly-or-via-list-comprehension/128671)

<div class="topic-metadata">

**Author:** [@hawahe](https://discourse.julialang.org/u/hawahe)\
**Replies:** 4\
**Last updated:** [May 4, 2025, 10:16am UTC](https://discourse.julialang.org/t/difference-between-vector-of-functions-typed-explicitly-or-via-list-comprehension/128671 "2025-05-04T10:16:51Z")

</div>

Are the following two ways to make a vector of functions equivalent? The latter gives both anonymous functions the name #1 when I expected to see #1 and #2. julia\> Function\[(x) -\> x^2, (x) -\> x^3\] 2-element Vector{Funct…

---

## [Adding method to function in macro](https://discourse.julialang.org/t/adding-method-to-function-in-macro/128613)

<div class="topic-metadata">

**Author:** [@PatrickHaecker](https://discourse.julialang.org/u/PatrickHaecker)\
**Replies:** 14\
**Last updated:** [May 4, 2025, 4:49am UTC](https://discourse.julialang.org/t/adding-method-to-function-in-macro/128613 "2025-05-04T04:49:53Z")

</div>

I have a package which defines a function and some methods for this function when the package gets loaded. In addition, the package defines a macro which returns an expression which defines additional methods to this fu…

---

## [Plots.jl, colorbar tick labels](https://discourse.julialang.org/t/plots-jl-colorbar-tick-labels/69632)

<div class="topic-metadata">

**Author:** [@Gravlax](https://discourse.julialang.org/u/Gravlax)\
**Replies:** 4\
**Last updated:** [May 3, 2025, 10:32pm UTC](https://discourse.julialang.org/t/plots-jl-colorbar-tick-labels/69632 "2025-05-03T22:32:44Z")

</div>

Hi everyone, I was wondering whether there is a possibility to define colorbar tick labels manually with Plots.j? By this, I mean something like this: The possibility of passing a Dict that maps numerical values to …

[Previous page](https://discourse.julialang.org/c/usage/6.md?page=64)

[Next page](https://discourse.julialang.org/c/usage/6.md?page=66)
