# General Usage

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

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

**Page:** 31

---

## [Global Base.PROGRAM\_FILE does not exist](https://discourse.julialang.org/t/global-base-program-file-does-not-exist/133875)

<div class="topic-metadata">

**Author:** [@ohmsweetohm1](https://discourse.julialang.org/u/ohmsweetohm1)\
**Replies:** 1\
**Last updated:** [November 14, 2025, 12:30pm UTC](https://discourse.julialang.org/t/global-base-program-file-does-not-exist/133875 "2025-11-14T12:30:58Z")

</div>

I compiled an App using package compiler for v1.12.1 and run it using docker. I got this obscure error: fatal: error thrown and no exception handler available. ErrorException("Global Base.PROGRAM\_FILE does not exist and…

---

## [Running Colab in local vscode](https://discourse.julialang.org/t/running-colab-in-local-vscode/43702)

<div class="topic-metadata">

**Author:** [@FujiwaraTakumiEH](https://discourse.julialang.org/u/FujiwaraTakumiEH)\
**Replies:** 1\
**Last updated:** [November 13, 2025, 5:56pm UTC](https://discourse.julialang.org/t/running-colab-in-local-vscode/43702 "2025-11-13T17:56:23Z")

</div>

At the moment we have been able to configure it manually in Colab to support running Julia and we can also use the GPU provided by Colab. However in my work environment I prefer to use VS-Code. I would like to ask if it…

---

## [Stochastic Gradient Descent (SGD) in julia?](https://discourse.julialang.org/t/stochastic-gradient-descent-sgd-in-julia/133846)

<div class="topic-metadata">

**Author:** [@Sigmund](https://discourse.julialang.org/u/Sigmund)\
**Replies:** 3\
**Last updated:** [November 13, 2025, 12:18pm UTC](https://discourse.julialang.org/t/stochastic-gradient-descent-sgd-in-julia/133846 "2025-11-13T12:18:38Z")

</div>

Im trying to run the newest version of OptimizationManopt.jl together with NeuralPDE.jl. When trying to add NeuralPDE.jl to the environment i get a long stacktrace with unsatisfiable requirements. When adding both to an …

---

## [Understanding "random" serialization when using @spawn in a "parallel region"](https://discourse.julialang.org/t/understanding-random-serialization-when-using-spawn-in-a-parallel-region/133824)

<div class="topic-metadata">

**Author:** [@mmesiti](https://discourse.julialang.org/u/mmesiti)\
**Replies:** 11\
**Last updated:** [November 13, 2025, 11:59am UTC](https://discourse.julialang.org/t/understanding-random-serialization-when-using-spawn-in-a-parallel-region/133824 "2025-11-13T11:59:50Z")

</div>

I have some Julia (1.10.10) code that I am benchmarking on a HPC cluster node with 76 physical cores, running with 76 threads, and I am seeing HUGE variability between runs with everything equal (same hardware, same code…

---

## [Report: in.pkg.julialang.org not responsive from ph](https://discourse.julialang.org/t/report-in-pkg-julialang-org-not-responsive-from-ph/133809)

<div class="topic-metadata">

**Author:** [@JYB](https://discourse.julialang.org/u/JYB)\
**Replies:** 10\
**Last updated:** [November 13, 2025, 5:40am UTC](https://discourse.julialang.org/t/report-in-pkg-julialang-org-not-responsive-from-ph/133809 "2025-11-13T05:40:03Z")

</div>

Please help resolve the following. It could be similar to a need to restart the server. I get the following error when I update my packages. (@v1.12) pkg\> update ┌ Warning: could not download https://pkg.julialang.org/…

---

## [Question about precedence of operator ~ (bitwise not)](https://discourse.julialang.org/t/question-about-precedence-of-operator-bitwise-not/133760)

<div class="topic-metadata">

**Author:** [@CiccioPasticcio](https://discourse.julialang.org/u/CiccioPasticcio)\
**Replies:** 3\
**Last updated:** [November 12, 2025, 8:28pm UTC](https://discourse.julialang.org/t/question-about-precedence-of-operator-bitwise-not/133760 "2025-11-12T20:28:52Z")

</div>

I see that the precedence of operation is specified here and if i understand correctly the operations higer in the file have higer precedence, so ~ being at the top has higest precedence. Also using Base.operator\_precede…

---

## [Trim Examples](https://discourse.julialang.org/t/trim-examples/133818)

<div class="topic-metadata">

**Author:** [@andreeco](https://discourse.julialang.org/u/andreeco)\
**Replies:** 1\
**Last updated:** [November 12, 2025, 1:25pm UTC](https://discourse.julialang.org/t/trim-examples/133818 "2025-11-12T13:25:36Z")

</div>

Hi, I would like to see some (more) examples of code using the new trim functionality. I did experiment a little and found it difficult to get type stability correctly. Not all that is allowed in Julia JIT is allowed in …

---

## [\`rand(::MyType, N)\` allocates a lot, how to define return type properly?](https://discourse.julialang.org/t/rand-mytype-n-allocates-a-lot-how-to-define-return-type-properly/133807)

<div class="topic-metadata">

**Author:** [@tamasgal](https://discourse.julialang.org/u/tamasgal)\
**Replies:** 4\
**Last updated:** [November 12, 2025, 1:19pm UTC](https://discourse.julialang.org/t/rand-mytype-n-allocates-a-lot-how-to-define-return-type-properly/133807 "2025-11-12T13:19:48Z")

</div>

Apologies if this has been discussed before but I am a bit lost in the docs and examples out there regarding a type-safe implementation of a proper rand interface. I guess it’s OK to have yet another another topic on thi…

---

## [Errors about adding LineSearch.jl](https://discourse.julialang.org/t/errors-about-adding-linesearch-jl/133815)

<div class="topic-metadata">

**Author:** [@shatanzikou](https://discourse.julialang.org/u/shatanzikou)\
**Replies:** 4\
**Last updated:** [November 12, 2025, 12:53pm UTC](https://discourse.julialang.org/t/errors-about-adding-linesearch-jl/133815 "2025-11-12T12:53:03Z")

</div>

I use julia V1.12.1 to add LineSearch.jl with following code import Pkg Pkg.add("LineSearch") Then I received a error message, which is ERROR: Unsatisfiable requirements detected for package LinearAlgebra \[37e2e46d\]:…

---

## [Backup 1 line when using readline()](https://discourse.julialang.org/t/backup-1-line-when-using-readline/133826)

<div class="topic-metadata">

**Author:** [@Jake](https://discourse.julialang.org/u/Jake)\
**Replies:** 1\
**Last updated:** [November 12, 2025, 12:38pm UTC](https://discourse.julialang.org/t/backup-1-line-when-using-readline/133826 "2025-11-12T12:38:16Z")

</div>

I am going through a mixed binary/ASCII file implementing UFF58b file format in UFFFiles.jl. It will make my life easier if I can read a line using readline(), call a subroutine and then read the same line again. So I …

---

## [With DataFrames, best practice for applying function across columns, where we also need to reference, in a second argument, the same column for each function call?](https://discourse.julialang.org/t/with-dataframes-best-practice-for-applying-function-across-columns-where-we-also-need-to-reference-in-a-second-argument-the-same-column-for-each-function-call/127747)

<div class="topic-metadata">

**Author:** [@midnightgreen](https://discourse.julialang.org/u/midnightgreen)\
**Replies:** 12\
**Last updated:** [November 11, 2025, 11:28pm UTC](https://discourse.julialang.org/t/with-dataframes-best-practice-for-applying-function-across-columns-where-we-also-need-to-reference-in-a-second-argument-the-same-column-for-each-function-call/127747 "2025-11-11T23:28:01Z")

</div>

This is somewhat difficult to put into words, however, I have two examples of this type of operation and I am unsure how best to tackle it in Julia. Take a weighted sum of a column within a grouping variable; repeat th…

---

## [Coupling finite\`Union\` with \`T\` in \`NTuple{2, T} where {T}\`](https://discourse.julialang.org/t/coupling-finite-union-with-t-in-ntuple-2-t-where-t/133567)

<div class="topic-metadata">

**Author:** [@frankwswang](https://discourse.julialang.org/u/frankwswang)\
**Replies:** 7\
**Last updated:** [November 11, 2025, 10:48am UTC](https://discourse.julialang.org/t/coupling-finite-union-with-t-in-ntuple-2-t-where-t/133567 "2025-11-11T10:48:15Z")

</div>

We know that for UnionAll of Tuple that uses the same type parameter (e.g., T) for all the element types (in default) requires the element types to be the same concrete type: julia\> f1(a::Tuple{T, T}) where {T\<:Real} = …

---

## [Slowdown vs C++/Python for Eigen matrix multiplication via ccall](https://discourse.julialang.org/t/slowdown-vs-c-python-for-eigen-matrix-multiplication-via-ccall/133783)

<div class="topic-metadata">

**Author:** [@nrypkema](https://discourse.julialang.org/u/nrypkema)\
**Replies:** 2\
**Last updated:** [November 10, 2025, 11:54pm UTC](https://discourse.julialang.org/t/slowdown-vs-c-python-for-eigen-matrix-multiplication-via-ccall/133783 "2025-11-10T23:54:16Z")

</div>

I’m hoping someone can explain the performance degradation that I’m seeing with Eigen matrix multiplication (and other methods in the Eigen C++ library). I have a simple example here: The C++ file has a simple exampl…

---

## [Array addition of oneAPI.jl slower](https://discourse.julialang.org/t/array-addition-of-oneapi-jl-slower/133663)

<div class="topic-metadata">

**Author:** [@raman\_kumar](https://discourse.julialang.org/u/raman_kumar)\
**Replies:** 10\
**Last updated:** [November 10, 2025, 8:30pm UTC](https://discourse.julialang.org/t/array-addition-of-oneapi-jl-slower/133663 "2025-11-10T20:30:05Z")

</div>

Why oneAPI.jl array addition is slow? julia\> using BenchmarkTools, oneAPI julia\> c = rand(100,100); julia\> @btime $c.+1 4.950 μs (3 allocations: 78.21 KiB) julia\> a = oneArray(rand(100,100)); julia\> @btime $a.+1 4…

---

## [Topological sort (performance)](https://discourse.julialang.org/t/topological-sort-performance/17153)

<div class="topic-metadata">

**Author:** [@govorunov](https://discourse.julialang.org/u/govorunov)\
**Replies:** 43\
**Last updated:** [November 10, 2025, 5:36pm UTC](https://discourse.julialang.org/t/topological-sort-performance/17153 "2025-11-10T17:36:27Z")

</div>

Hi. I needed to implement a topological sort, so I found some implementations on the Internet here: Topological sort - Rosetta Code I initially needed it in Python and experimented with Julia just out of curiosity. Her…

---

## [What is the most fitting container in foreach](https://discourse.julialang.org/t/what-is-the-most-fitting-container-in-foreach/133775)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 6\
**Last updated:** [November 10, 2025, 2:02pm UTC](https://discourse.julialang.org/t/what-is-the-most-fitting-container-in-foreach/133775 "2025-11-10T14:02:29Z")

</div>

It’s a small question but I have an impulse to ask: I find that the generator is lazy julia\> const a = fill(0, 4); julia\> function f!(i) i == 3 && error() a\[i\] = i -i end; juli…

---

## [Extremly slow matrix multiplication with Hermitian(sparse())](https://discourse.julialang.org/t/extremly-slow-matrix-multiplication-with-hermitian-sparse/133774)

<div class="topic-metadata">

**Author:** [@tripo](https://discourse.julialang.org/u/tripo)\
**Replies:** 3\
**Last updated:** [November 10, 2025, 12:46pm UTC](https://discourse.julialang.org/t/extremly-slow-matrix-multiplication-with-hermitian-sparse/133774 "2025-11-10T12:46:40Z")

</div>

Hello everyone, I have a large sparse hermitian matrix in my code but the matrix multiplication is taking absolutely forever. Is it a bug ? M = rand(2000,2000); C = rand(2000,2000); @time M\*C; @time M\*Hermitian(C); @…

---

## [Can we get RealtimeSanitizer in Julia?](https://discourse.julialang.org/t/can-we-get-realtimesanitizer-in-julia/119330)

<div class="topic-metadata">

**Author:** [@GeorgeGkountouras](https://discourse.julialang.org/u/GeorgeGkountouras)\
**Replies:** 9\
**Last updated:** [November 9, 2025, 8:10pm UTC](https://discourse.julialang.org/t/can-we-get-realtimesanitizer-in-julia/119330 "2025-11-09T20:10:04Z")

</div>

Introduction At last year’s Audio Developer Conference, RealtimeSanitizer, a tool for detecting function calls that are unsafe in a realtime context, was presented. RTSan is now being upstreamed to LLVM 20 and will be pr…

---

## [Symbolics.jl: \`simplify\` is inconsistent when changing the number of terms](https://discourse.julialang.org/t/symbolics-jl-simplify-is-inconsistent-when-changing-the-number-of-terms/133751)

<div class="topic-metadata">

**Author:** [@JaydevSR](https://discourse.julialang.org/u/JaydevSR)\
**Replies:** 3\
**Last updated:** [November 9, 2025, 4:15pm UTC](https://discourse.julialang.org/t/symbolics-jl-simplify-is-inconsistent-when-changing-the-number-of-terms/133751 "2025-11-09T16:15:31Z")

</div>

I am using simplify for the below terms: for which I get the following result: As you can see that depending on the number of terms in the expressions, it gives inconsistent results. For some terms it’s able to c…

---

## [Will Julia exits only after all threads get their tasks done?](https://discourse.julialang.org/t/will-julia-exits-only-after-all-threads-get-their-tasks-done/133744)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 4\
**Last updated:** [November 9, 2025, 3:58pm UTC](https://discourse.julialang.org/t/will-julia-exits-only-after-all-threads-get-their-tasks-done/133744 "2025-11-09T15:58:26Z")

</div>

From this link Can the threads in the :interactive pool also undertake heavy computing tasks? - #9 by WalterMadelim I find that this behavior is puzzling: Define this file s.jl function bzwt(t) tdue = time\_ns(…

---

## [Integrating symbolic functions?](https://discourse.julialang.org/t/integrating-symbolic-functions/102545)

<div class="topic-metadata">

**Author:** [@GregVernon](https://discourse.julialang.org/u/GregVernon)\
**Replies:** 18\
**Last updated:** [November 9, 2025, 3:29pm UTC](https://discourse.julialang.org/t/integrating-symbolic-functions/102545 "2025-11-09T15:29:33Z")

</div>

I’m trying to perform indefinite and/or definite integrals using Symbolics.Integral(), but I can’t seem to find documentation on how to use it (though, most of Symbolics.jl methods appear undocumented). Currently, thro…

---

## [Can the threads in the :interactive pool also undertake heavy computing tasks?](https://discourse.julialang.org/t/can-the-threads-in-the-interactive-pool-also-undertake-heavy-computing-tasks/133725)

<div class="topic-metadata">

**Author:** [@WalterMadelim](https://discourse.julialang.org/u/WalterMadelim)\
**Replies:** 7\
**Last updated:** [November 8, 2025, 1:15am UTC](https://discourse.julialang.org/t/can-the-threads-in-the-interactive-pool-also-undertake-heavy-computing-tasks/133725 "2025-11-08T01:15:17Z")

</div>

(From a related issue Unsticky Tasks stick to threadpool since 1.10, causing issues since 1.12 · Issue #59936 · JuliaLang/julia · GitHub But here I’m not referring to the functional API Task, instead, I’m talking about @…

---

## [How to visualize NaNs in an array?](https://discourse.julialang.org/t/how-to-visualize-nans-in-an-array/133738)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 7\
**Last updated:** [November 7, 2025, 7:04pm UTC](https://discourse.julialang.org/t/how-to-visualize-nans-in-an-array/133738 "2025-11-07T19:04:03Z")

</div>

I have a 2D array of size 150x150, and for debugging purposes, I want to see in the REPL where the NaNs are in this array. How would you do that?

---

## [Parse with exponent D](https://discourse.julialang.org/t/parse-with-exponent-d/133715)

<div class="topic-metadata">

**Author:** [@Jake](https://discourse.julialang.org/u/Jake)\
**Replies:** 4\
**Last updated:** [November 7, 2025, 1:24pm UTC](https://discourse.julialang.org/t/parse-with-exponent-d/133715 "2025-11-07T13:24:04Z")

</div>

I tried parsing the values printed to file by some old Fortran code. This code uses the exponent D for double precision numbers, like 2.73150000000000003D+02. I can use the replace command to replace the “D” with “E”, …

---

## [Workspaces + Monorepo of unregistered packages](https://discourse.julialang.org/t/workspaces-monorepo-of-unregistered-packages/133005)

<div class="topic-metadata">

**Author:** [@nandoconde](https://discourse.julialang.org/u/nandoconde)\
**Replies:** 19\
**Last updated:** [November 6, 2025, 10:35pm UTC](https://discourse.julialang.org/t/workspaces-monorepo-of-unregistered-packages/133005 "2025-11-06T22:35:12Z")

</div>

Hello! I was reading the Julia v1.12 release blog post and read about the use of the workspace feature and how it can help with monorepos. Right now, I have several unregistered interdependent packages and the approach…

---

## [Threads.@threads on views into a vector doesn't give much of a speed-up](https://discourse.julialang.org/t/threads-threads-on-views-into-a-vector-doesnt-give-much-of-a-speed-up/133713)

<div class="topic-metadata">

**Author:** [@jlbosse](https://discourse.julialang.org/u/jlbosse)\
**Replies:** 3\
**Last updated:** [November 6, 2025, 9:16pm UTC](https://discourse.julialang.org/t/threads-threads-on-views-into-a-vector-doesnt-give-much-of-a-speed-up/133713 "2025-11-06T21:16:40Z")

</div>

I am trying to speed my code up using the Threads.@threads macro and splitting an array into multiple views so that each thread works on a separate view, but am not getting the performance gains I had hoped for. Conside…

---

## [Large allocations with MTK event](https://discourse.julialang.org/t/large-allocations-with-mtk-event/133680)

<div class="topic-metadata">

**Author:** [@klinders](https://discourse.julialang.org/u/klinders)\
**Replies:** 1\
**Last updated:** [November 5, 2025, 11:35pm UTC](https://discourse.julialang.org/t/large-allocations-with-mtk-event/133680 "2025-11-05T23:35:22Z")

</div>

Dear all, Recently, you helped me get events working in MTK. Thank you for all the help! Continuing on the topic, I ran into a performance issue with events. I have the following code to measure the time and allocation…

---

## [Fully Unique Combinations from Multiple Arrays](https://discourse.julialang.org/t/fully-unique-combinations-from-multiple-arrays/133626)

<div class="topic-metadata">

**Author:** [@wes648](https://discourse.julialang.org/u/wes648)\
**Replies:** 15\
**Last updated:** [November 5, 2025, 5:57pm UTC](https://discourse.julialang.org/t/fully-unique-combinations-from-multiple-arrays/133626 "2025-11-05T17:57:19Z")

</div>

Hello! I have a model with n terms and the ability to remove k of them. However each of the k removal options can only act on an arbitrary list of model terms. I want a memory-efficient way to generate every unique comb…

---

## [Regex interpolation](https://discourse.julialang.org/t/regex-interpolation/133683)

<div class="topic-metadata">

**Author:** [@healyp](https://discourse.julialang.org/u/healyp)\
**Replies:** 1\
**Last updated:** [November 5, 2025, 5:42pm UTC](https://discourse.julialang.org/t/regex-interpolation/133683 "2025-11-05T17:42:32Z")

</div>

I would like to match a string exactly (using word boundaries) against an interpolated Regex. Here’s what I have but the output looks wrong to me. Am I doing something wrong? julia\> k="t2" "t2" julia\> r = Regex("\\b$(…

---

## [Regression in REPL file path completion in 1.12?](https://discourse.julialang.org/t/regression-in-repl-file-path-completion-in-1-12/133573)

<div class="topic-metadata">

**Author:** [@johnomotani](https://discourse.julialang.org/u/johnomotani)\
**Replies:** 4\
**Last updated:** [November 5, 2025, 5:01pm UTC](https://discourse.julialang.org/t/regression-in-repl-file-path-completion-in-1-12/133573 "2025-11-05T17:01:16Z")

</div>

In versions of Julia up to 1.11, tab completion of file paths would work from anywhere in the line, e.g. hitting \<tab\> in the middle of a path like julia\> run\_something("input\_files/f\<tab\>/bar.toml"; some\_kwarg=true) w…

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

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