# Latest

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

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

**Page:** 814

---

## [How to achieve perfect scaling with Threads (Julia 1.7.1)](https://discourse.julialang.org/t/how-to-achieve-perfect-scaling-with-threads-julia-1-7-1/92603)

<div class="topic-metadata">

**Author:** [@Salmon](https://discourse.julialang.org/u/Salmon)\
**Replies:** 33\
**Last updated:** [January 13, 2023, 11:07am UTC](https://discourse.julialang.org/t/how-to-achieve-perfect-scaling-with-threads-julia-1-7-1/92603 "2023-01-13T11:07:20Z")

</div>

Hi everyone, I am currently investigating a scaling bottleneck in one of my codes which seems a bit elusive to me. In my investigation to get a MWE, I have tried to produce a somewhat representative example, which shou…

---

## [Starting Julia with multiple threads on Mac M1](https://discourse.julialang.org/t/starting-julia-with-multiple-threads-on-mac-m1/92906)

<div class="topic-metadata">

**Author:** [@sajjad\_khan](https://discourse.julialang.org/u/sajjad_khan)\
**Replies:** 16\
**Last updated:** [January 13, 2023, 9:45am UTC](https://discourse.julialang.org/t/starting-julia-with-multiple-threads-on-mac-m1/92906 "2023-01-13T09:45:24Z")

</div>

How to setup multiple threads in Mac M1. The versioninfo() prints 6 virtual cores and when I set using Base.Threads Threads.nthreads()=6 and query # of set threads using nthreads(), I get 6 but when I want to use t…

---

## [Segfault in DataStructures.jl](https://discourse.julialang.org/t/segfault-in-datastructures-jl/92913)

<div class="topic-metadata">

**Author:** [@Joseph\_Bradley](https://discourse.julialang.org/u/Joseph_Bradley)\
**Replies:** 0\
**Last updated:** [January 13, 2023, 9:44am UTC](https://discourse.julialang.org/t/segfault-in-datastructures-jl/92913 "2023-01-13T09:44:01Z")

</div>

I am getting the following segfault in the midst of some other code: signal (11): Segmentation fault: 11 in expression starting at REPL\[67\]:1 gc\_mark\_loop at /Applications/Julia-1.8.app/Contents/Resources/julia/lib/juli…

---

## [How to Plot Cycloid with Plots?](https://discourse.julialang.org/t/how-to-plot-cycloid-with-plots/92909)

<div class="topic-metadata">

**Author:** [@Freya\_the\_Goddess](https://discourse.julialang.org/u/Freya_the_Goddess)\
**Replies:** 1\
**Last updated:** [January 13, 2023, 8:02am UTC](https://discourse.julialang.org/t/how-to-plot-cycloid-with-plots/92909 "2023-01-13T08:02:50Z")

</div>

Hi all, I want to plot the cycloid, with PartialCircle, I think it is not working… Here is my code / MWE: using Plots, LaTeXStrings; gr() # To plot a circle of radius 2 centered at (0, 0) θ = 0:0.01:2π x = 0 .+ 2c…

---

## [Zip folder using Julia](https://discourse.julialang.org/t/zip-folder-using-julia/69565)

<div class="topic-metadata">

**Author:** [@RaulDurand](https://discourse.julialang.org/u/RaulDurand)\
**Replies:** 8\
**Last updated:** [January 13, 2023, 7:41am UTC](https://discourse.julialang.org/t/zip-folder-using-julia/69565 "2023-01-13T07:41:47Z")

</div>

Hi! How to zip an entire folder using Julia? I tried using ZipFile with no success. Thanks.

---

## [Why isn't SnoopPrecompile being able to fully compile the calls in this case?](https://discourse.julialang.org/t/why-isnt-snoopprecompile-being-able-to-fully-compile-the-calls-in-this-case/92849)

<div class="topic-metadata">

**Author:** [@jishnub](https://discourse.julialang.org/u/jishnub)\
**Replies:** 10\
**Last updated:** [January 13, 2023, 7:36am UTC](https://discourse.julialang.org/t/why-isnt-snoopprecompile-being-able-to-fully-compile-the-calls-in-this-case/92849 "2023-01-13T07:36:49Z")

</div>

I have a PR to BandedMatrices with the following SnoopPrecompile instructions: @precompile\_setup begin vs = (\[1.0\], Float32\[1.0\], ComplexF32\[1.0\], ComplexF64\[1.0\]) Bs = Any\[BandedMatrix(0 =\> v) for v in vs\] @precompi…

---

## [Extremely tiny font in pyplot windows](https://discourse.julialang.org/t/extremely-tiny-font-in-pyplot-windows/92863)

<div class="topic-metadata">

**Author:** [@jishnub](https://discourse.julialang.org/u/jishnub)\
**Replies:** 2\
**Last updated:** [January 13, 2023, 6:51am UTC](https://discourse.julialang.org/t/extremely-tiny-font-in-pyplot-windows/92863 "2023-01-13T06:51:07Z")

</div>

This is a somewhat unusual issue that I’m facing: the font sizes in the matplotlib windows is far too small: I’m using PyPlot.jl for my plots, and trying to save the plot from the icon in the plot window. Does anyon…

---

## [Gurobi- failed to precompile](https://discourse.julialang.org/t/gurobi-failed-to-precompile/44606)

<div class="topic-metadata">

**Author:** [@MJMB](https://discourse.julialang.org/u/MJMB)\
**Replies:** 9\
**Last updated:** [January 13, 2023, 4:47am UTC](https://discourse.julialang.org/t/gurobi-failed-to-precompile/44606 "2023-01-13T04:47:40Z")

</div>

Hello, I have problem with gurobi, i am using MacBook Pro and suddenly it show me error that it failed to precompile, i have tried to remove it and add it again but it doesn’t work. my license is valid and i am using G…

---

## [Good coding practices: How to cluster many variables in function argument](https://discourse.julialang.org/t/good-coding-practices-how-to-cluster-many-variables-in-function-argument/92855)

<div class="topic-metadata">

**Author:** [@physh](https://discourse.julialang.org/u/physh)\
**Replies:** 7\
**Last updated:** [January 13, 2023, 2:46am UTC](https://discourse.julialang.org/t/good-coding-practices-how-to-cluster-many-variables-in-function-argument/92855 "2023-01-13T02:46:01Z")

</div>

Hello there, I’m still fairly new to julia, but I guess it is anyway a general programming question. In my code there are several physical parameters, e.g. mass,speed,height,… as well as numerical parameters for differ…

---

## [Why CRC32c but missing CRC32](https://discourse.julialang.org/t/why-crc32c-but-missing-crc32/92075)

<div class="topic-metadata">

**Author:** [@jling](https://discourse.julialang.org/u/jling)\
**Replies:** 10\
**Last updated:** [January 13, 2023, 1:52am UTC](https://discourse.julialang.org/t/why-crc32c-but-missing-crc32/92075 "2023-01-13T01:52:30Z")

</div>

I just found out that CRC32 and CRC32c are two different things, and the latter we have in stdlib: CRC32c · The Julia Language julia\> using CRC32c julia\> CRC32c.crc32c(UInt8\[1,0,1,0,0,0,0,0,0,0\]) 0x61b7f6e9 julia\> CRC…

---

## [How to update individual sparse matrices mapped to sparse diagonal-matrix efficiently?](https://discourse.julialang.org/t/how-to-update-individual-sparse-matrices-mapped-to-sparse-diagonal-matrix-efficiently/92900)

<div class="topic-metadata">

**Author:** [@Amro](https://discourse.julialang.org/u/Amro)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 11:11pm UTC](https://discourse.julialang.org/t/how-to-update-individual-sparse-matrices-mapped-to-sparse-diagonal-matrix-efficiently/92900 "2023-01-12T23:11:15Z")

</div>

I have a simple MWE below that includes a diagonal sparse matrix A and its sub-diagonal matrices A\_1,A\_2,A\_3. Assuming that A is going to be updated in values only (pattern is fixed), what is the efficient way to update A…

---

## [What to do when command \`\`\`notebook()\`\`\` won't prompt a Jupyter installation?](https://discourse.julialang.org/t/what-to-do-when-command-notebook-wont-prompt-a-jupyter-installation/92897)

<div class="topic-metadata">

**Author:** [@Hugo](https://discourse.julialang.org/u/Hugo)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 11:01pm UTC](https://discourse.julialang.org/t/what-to-do-when-command-notebook-wont-prompt-a-jupyter-installation/92897 "2023-01-12T23:01:07Z")

</div>

TL;DR: How to make Julia find the jupyter kernel so Quarto can run? I just installed a new version of Julia (1.8.5) and, given the problems I am dealing with, I assume the packages I had installed didn’t migrate to the …

---

## [Discourse v3.0](https://discourse.julialang.org/t/discourse-v3-0/92826)

<div class="topic-metadata">

**Author:** [@mbauman](https://discourse.julialang.org/u/mbauman)\
**Replies:** 9\
**Last updated:** [January 12, 2023, 10:56pm UTC](https://discourse.julialang.org/t/discourse-v3-0/92826 "2023-01-12T22:56:43Z")

</div>

Things look a little different around here this afternoon — we’ve been upgraded to Discourse v3.0: There are lots of new goodies in addition to the obvious UI changes, including things we can decide to enable (or not)…

---

## [Questions related to updating Julia](https://discourse.julialang.org/t/questions-related-to-updating-julia/92896)

<div class="topic-metadata">

**Author:** [@Leon6](https://discourse.julialang.org/u/Leon6)\
**Replies:** 6\
**Last updated:** [January 12, 2023, 10:45pm UTC](https://discourse.julialang.org/t/questions-related-to-updating-julia/92896 "2023-01-12T22:45:10Z")

</div>

I’m on Mac OS Venture 13.1 and am trying to upgrade from my current v1.7 to v1.8.5.After downloading and installing the dmg file now I have both versions in my Application folder. How should I remove the old version and…

---

## [Package naming question](https://discourse.julialang.org/t/package-naming-question/92894)

<div class="topic-metadata">

**Author:** [@Greg7](https://discourse.julialang.org/u/Greg7)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 8:53pm UTC](https://discourse.julialang.org/t/package-naming-question/92894 "2023-01-12T20:53:49Z")

</div>

We want to register a new Julia package, but we failed to register it with the AutoMerge because of the Damerau-Levenshtein distance. The two packages are very different and the two names do not sound confusing at all,…

---

## [Invalidations findings (from a GMT case)](https://discourse.julialang.org/t/invalidations-findings-from-a-gmt-case/92420)

<div class="topic-metadata">

**Author:** [@joa-quim](https://discourse.julialang.org/u/joa-quim)\
**Replies:** 64\
**Last updated:** [January 12, 2023, 8:46pm UTC](https://discourse.julialang.org/t/invalidations-findings-from-a-gmt-case/92420 "2023-01-12T20:46:39Z")

</div>

Continuing from Julia v1.9.0-beta2 is fast and using Tim’s recipe using SnoopCompileCore invs = @snoopr using GMT tinf = @snoopi\_deep plot(rand(5,2)); using SnoopCompile trees = invalidation\_trees(invs); taletrees = pr…

---

## [When activating the environment won't work](https://discourse.julialang.org/t/when-activating-the-environment-wont-work/92893)

<div class="topic-metadata">

**Author:** [@Hugo](https://discourse.julialang.org/u/Hugo)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 8:44pm UTC](https://discourse.julialang.org/t/when-activating-the-environment-wont-work/92893 "2023-01-12T20:44:52Z")

</div>

I am working on a project using VSCode as my IDE. I created a project once, and since then I have been activating the its environment every time I work on that project. I usually have no problems with it, but today I’m …

---

## [Unable to re-create an environment: Pre-compile errors](https://discourse.julialang.org/t/unable-to-re-create-an-environment-pre-compile-errors/92853)

<div class="topic-metadata">

**Author:** [@Lukas\_Hebing](https://discourse.julialang.org/u/Lukas_Hebing)\
**Replies:** 5\
**Last updated:** [January 12, 2023, 8:20pm UTC](https://discourse.julialang.org/t/unable-to-re-create-an-environment-pre-compile-errors/92853 "2023-01-12T20:20:15Z")

</div>

Hello, as suggested in the pkg dodumentation, I tried to use an existing project.toml and manifest.toml file to re-create an anvironment of a colleague. Installing runs fine. However, when I use some packages (e.g. Mode…

---

## [Deserialize does not work when reopen](https://discourse.julialang.org/t/deserialize-does-not-work-when-reopen/92892)

<div class="topic-metadata">

**Author:** [@JNSDVD](https://discourse.julialang.org/u/JNSDVD)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 7:55pm UTC](https://discourse.julialang.org/t/deserialize-does-not-work-when-reopen/92892 "2023-01-12T19:55:42Z")

</div>

Hey guys, I do not understand why the first code returns true while it does not work when I close the Jupyter Notebook, open it again and run only the second code. Of course the file XX.jls is still in the same folder …

---

## [New Bayesian Data Analysis Meetup event](https://discourse.julialang.org/t/new-bayesian-data-analysis-meetup-event/92771)

<div class="topic-metadata">

**Author:** [@bparbhu](https://discourse.julialang.org/u/bparbhu)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 7:48pm UTC](https://discourse.julialang.org/t/new-bayesian-data-analysis-meetup-event/92771 "2023-01-12T19:48:47Z")

</div>

Hi everyone, On February 23rd, 2023 we will be resuming the Bayesian Data Analysis meetup in NYC. Our first meetup will be virtual but we will feature an introduction to Bayesian Inference using Turing.jl. https://tur…

---

## [Blackbox optimization fitness evolution non-monotonic](https://discourse.julialang.org/t/blackbox-optimization-fitness-evolution-non-monotonic/92891)

<div class="topic-metadata">

**Author:** [@mengxiaoliu](https://discourse.julialang.org/u/mengxiaoliu)\
**Replies:** 0\
**Last updated:** [January 12, 2023, 7:40pm UTC](https://discourse.julialang.org/t/blackbox-optimization-fitness-evolution-non-monotonic/92891 "2023-01-12T19:40:14Z")

</div>

Hi all, I use the default algorithm (rand/1/bin) in the BlackBoxOptim package to optimize a single-objective function. Here is a plot of the best fitness per generation: I am not sure why the best fitness does not d…

---

## [Where is T distribution on Distributions.jl?](https://discourse.julialang.org/t/where-is-t-distribution-on-distributions-jl/92887)

<div class="topic-metadata">

**Author:** [@jcbritobr](https://discourse.julialang.org/u/jcbritobr)\
**Replies:** 1\
**Last updated:** [January 12, 2023, 6:17pm UTC](https://discourse.julialang.org/t/where-is-t-distribution-on-distributions-jl/92887 "2023-01-12T18:17:39Z")

</div>

Hello, good morning. Tryed search on documentation, but cant find a T distribution on julia Distributions.jl. Where can I find it?

---

## [BigFloat type promotion != precision promotion](https://discourse.julialang.org/t/bigfloat-type-promotion-precision-promotion/91945)

<div class="topic-metadata">

**Author:** [@gvdeynde](https://discourse.julialang.org/u/gvdeynde)\
**Replies:** 16\
**Last updated:** [January 12, 2023, 6:11pm UTC](https://discourse.julialang.org/t/bigfloat-type-promotion-precision-promotion/91945 "2023-01-12T18:11:06Z")

</div>

Hi all I’m a bit confused on the rules of precision “promotion” using BigFloats. As far as I can see, there are none. See example below. From this, I can conclude that Type promotion is made (the result of an operatio…

---

## [Julia == rust + dynamic\_typing + JiT + GC?](https://discourse.julialang.org/t/julia-rust-dynamic-typing-jit-gc/92778)

<div class="topic-metadata">

**Author:** [@Jasha10](https://discourse.julialang.org/u/Jasha10)\
**Replies:** 4\
**Last updated:** [January 12, 2023, 5:33pm UTC](https://discourse.julialang.org/t/julia-rust-dynamic-typing-jit-gc/92778 "2023-01-12T17:33:15Z")

</div>

Dabbling in Julia and then recently beginning to learn rust, it seems to me that the two languages have a lot in common. My impression now is that the most fundamental differences are that Julia has: dynamic typing Ji…

---

## [Security in Julia Packages](https://discourse.julialang.org/t/security-in-julia-packages/92883)

<div class="topic-metadata">

**Author:** [@Jon\_Marcum](https://discourse.julialang.org/u/Jon_Marcum)\
**Replies:** 2\
**Last updated:** [January 12, 2023, 5:18pm UTC](https://discourse.julialang.org/t/security-in-julia-packages/92883 "2023-01-12T17:18:36Z")

</div>

How does Julia insure that packages are not compromised by bad actors? Case in point an article that I read stated that pypi contained 50% of its packages with security vulnerabilities ( About half of Python libraries in…

---

## [Operational calculus in julia?](https://discourse.julialang.org/t/operational-calculus-in-julia/24415)

<div class="topic-metadata">

**Author:** [@xtalax](https://discourse.julialang.org/u/xtalax)\
**Replies:** 4\
**Last updated:** [January 12, 2023, 4:00pm UTC](https://discourse.julialang.org/t/operational-calculus-in-julia/24415 "2023-01-12T16:00:02Z")

</div>

If it were possible to give functions types in Julia, it would ease the implementation of operational calculus in the language. I’m thinking about ways to implement differential operators in julia, so that it would be p…

---

## [Performance measurement of floating number division vs multiplication](https://discourse.julialang.org/t/performance-measurement-of-floating-number-division-vs-multiplication/92874)

<div class="topic-metadata">

**Author:** [@linwaytin](https://discourse.julialang.org/u/linwaytin)\
**Replies:** 3\
**Last updated:** [January 12, 2023, 3:30pm UTC](https://discourse.julialang.org/t/performance-measurement-of-floating-number-division-vs-multiplication/92874 "2023-01-12T15:30:55Z")

</div>

I want to know how expensive the floating number division is, compared to the multiplication. Using BenchmarkTools, I found they are the same. julia\> @benchmark $(Ref(a))\[\] \* $(Ref(b))\[\] BenchmarkTools.Trial: 10000 samp…

---

## [Writing my own callbacks](https://discourse.julialang.org/t/writing-my-own-callbacks/92871)

<div class="topic-metadata">

**Author:** [@erlebach](https://discourse.julialang.org/u/erlebach)\
**Replies:** 5\
**Last updated:** [January 12, 2023, 3:22pm UTC](https://discourse.julialang.org/t/writing-my-own-callbacks/92871 "2023-01-12T15:22:24Z")

</div>

I thought I finally understood the various subtleties of scope and closure in Julia, but obviously not! Here is a self-contained MWE that demonstrates a callback that does not work and I do not know how to fix: iter = 8…

---

## [Very long time to compile system image with v1.9beta2](https://discourse.julialang.org/t/very-long-time-to-compile-system-image-with-v1-9beta2/92870)

<div class="topic-metadata">

**Author:** [@mcreel](https://discourse.julialang.org/u/mcreel)\
**Replies:** 5\
**Last updated:** [January 12, 2023, 3:12pm UTC](https://discourse.julialang.org/t/very-long-time-to-compile-system-image-with-v1-9beta2/92870 "2023-01-12T15:12:15Z")

</div>

Using julia v1.9beta2, I have tried to compile a system image for a project with many dependencies. This takes around 10-12 minutes with v1.8.x. With 1.9b2, I interrupted it at the 2 hour point. Perhaps I should clear ou…

---

## [Interface boundaries Warning in MethodOfLines.jl](https://discourse.julialang.org/t/interface-boundaries-warning-in-methodoflines-jl/92813)

<div class="topic-metadata">

**Author:** [@anh](https://discourse.julialang.org/u/anh)\
**Replies:** 3\
**Last updated:** [January 12, 2023, 3:04pm UTC](https://discourse.julialang.org/t/interface-boundaries-warning-in-methodoflines-jl/92813 "2023-01-12T15:04:46Z")

</div>

Hello, I’m very new to posting questions on here so I apologize in advance for any formatting/convention mistakes or if anything is unclear! I am trying to solve a PDE using MethodOfLines.jl and receive the following wa…

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

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