# Latest

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

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

**Page:** 323

---

## [How to add diagonal line to log-log plot](https://discourse.julialang.org/t/how-to-add-diagonal-line-to-log-log-plot/119322)

<div class="topic-metadata">

**Author:** [@Christopher\_Fisher](https://discourse.julialang.org/u/Christopher_Fisher)\
**Replies:** 7\
**Last updated:** [September 12, 2024, 3:44pm UTC](https://discourse.julialang.org/t/how-to-add-diagonal-line-to-log-log-plot/119322 "2024-09-12T15:44:21Z")

</div>

Hello, I would like to plot a diagonal line on a log-log plot. How can I do that? using Plots x = 1:4 y = \[44,29,6,1\] scatter(x, y, xaxis=:log10, yaxis=:log10) Plots.abline!(-1, 44)

---

## [Ben Moll's Huggett code not consistent in Julia](https://discourse.julialang.org/t/ben-molls-huggett-code-not-consistent-in-julia/119327)

<div class="topic-metadata">

**Author:** [@Mehrdad\_Esfahani](https://discourse.julialang.org/u/Mehrdad_Esfahani)\
**Replies:** 4\
**Last updated:** [September 12, 2024, 2:51pm UTC](https://discourse.julialang.org/t/ben-molls-huggett-code-not-consistent-in-julia/119327 "2024-09-12T14:51:07Z")

</div>

I rewrote (translated) Ben Moll’s Matlab code for the Huggett model (partial equilibrium) in continuous time in Julia. When I change the value of the shocks, the concavity condition during the iteration fails. The Matlab…

---

## [Bool behavior for 2+, i.e. illegal values](https://discourse.julialang.org/t/bool-behavior-for-2-i-e-illegal-values/119328)

<div class="topic-metadata">

**Author:** [@Palli](https://discourse.julialang.org/u/Palli)\
**Replies:** 7\
**Last updated:** [September 12, 2024, 2:45pm UTC](https://discourse.julialang.org/t/bool-behavior-for-2-i-e-illegal-values/119328 "2024-09-12T14:45:37Z")

</div>

I noticed in Dlang, most recent version: Compiler changes bool values other than 0 or 1 are not @safe The spec has been updated so that only 0 and 1 are safe values for bool. This means that reading a bool value wh…

---

## [Solve equation in Symbolics.jl](https://discourse.julialang.org/t/solve-equation-in-symbolics-jl/119302)

<div class="topic-metadata">

**Author:** [@jar1](https://discourse.julialang.org/u/jar1)\
**Replies:** 6\
**Last updated:** [September 12, 2024, 2:43pm UTC](https://discourse.julialang.org/t/solve-equation-in-symbolics-jl/119302 "2024-09-12T14:43:49Z")

</div>

Symbolics.jl can’t solve this equation but if I multiply both sides by x^3 then it can. Wolfram Alpha can solve both. Symbolics.jl’s docs say it can do polynomial equations; do these count? What’s the problem? \[2edaba…

---

## [RFC: @jet\_ignore to let JET.jl ignore specific functions](https://discourse.julialang.org/t/rfc-jet-ignore-to-let-jet-jl-ignore-specific-functions/119258)

<div class="topic-metadata">

**Author:** [@nielsls](https://discourse.julialang.org/u/nielsls)\
**Replies:** 0\
**Last updated:** [September 10, 2024, 7:45pm UTC](https://discourse.julialang.org/t/rfc-jet-ignore-to-let-jet-jl-ignore-specific-functions/119258 "2024-09-10T19:45:57Z")

</div>

Unleashing JET.jl on my codebase tends to flood the prompt with errors due to the use of IO, DataFrames, etc… A lot of these runtime-dispatches are okay, but some are not. As an example, assume that I’m okay with the p…

---

## [Allocation-free weighted samples](https://discourse.julialang.org/t/allocation-free-weighted-samples/119265)

<div class="topic-metadata">

**Author:** [@Tetrakai](https://discourse.julialang.org/u/Tetrakai)\
**Replies:** 12\
**Last updated:** [September 12, 2024, 1:50pm UTC](https://discourse.julialang.org/t/allocation-free-weighted-samples/119265 "2024-09-12T13:50:12Z")

</div>

Given an SVector of weights, is there a way to take a single weighted sample without any allocations? Ie, these work great but require an allocation: x = \[1\] wts = @SVector rand(16) @btime wsample(1:16, $wts) @btime wsa…

---

## [Lowered optimization and targetted; even applied from the caller site](https://discourse.julialang.org/t/lowered-optimization-and-targetted-even-applied-from-the-caller-site/119326)

<div class="topic-metadata">

**Author:** [@Palli](https://discourse.julialang.org/u/Palli)\
**Replies:** 0\
**Last updated:** [September 12, 2024, 1:40pm UTC](https://discourse.julialang.org/t/lowered-optimization-and-targetted-even-applied-from-the-caller-site/119326 "2024-09-12T13:40:04Z")

</div>

From Jeff’s juliac JuliaCon talk: Just the \_init\_methods in Base take up 600k! The first line of attack, is less code, tree-shaking, as explained there. But it doesn’t rule out my idea for remaining code: It got me …

---

## [How to make xlabelvisible = false in AoG](https://discourse.julialang.org/t/how-to-make-xlabelvisible-false-in-aog/119317)

<div class="topic-metadata">

**Author:** [@vladdez](https://discourse.julialang.org/u/vladdez)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 1:32pm UTC](https://discourse.julialang.org/t/how-to-make-xlabelvisible-false-in-aog/119317 "2024-09-12T13:32:53Z")

</div>

Imagine I have this figure: df = (; name = \["Anna", "Beatrix", "Claire"\], height\_meters = \[1.55, 1.76, 1.63\]) m = mapping(:name, :height\_meters) spec1 = data(df) \* m \* visual(BarPlot) f = Figure() draw!(f\[1, 1\], spec1)…

---

## [Discrete callback + Saving callback for changing parameters in DifferentialEquations doesn't work as intended](https://discourse.julialang.org/t/discrete-callback-saving-callback-for-changing-parameters-in-differentialequations-doesnt-work-as-intended/119277)

<div class="topic-metadata">

**Author:** [@alonsoC1s](https://discourse.julialang.org/u/alonsoC1s)\
**Replies:** 11\
**Last updated:** [September 12, 2024, 12:25pm UTC](https://discourse.julialang.org/t/discrete-callback-saving-callback-for-changing-parameters-in-differentialequations-doesnt-work-as-intended/119277 "2024-09-12T12:25:57Z")

</div>

Hi, I have been using DifferentialEquations.jl to solve a set of around 250 coupled SDEs that used to be solved with custom Euler-Maruyama. In the model this is simulating there is a parameter, an adjacency matrix, tha…

---

## [ModelingToolkit... documenting my models](https://discourse.julialang.org/t/modelingtoolkit-documenting-my-models/119310)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 5\
**Last updated:** [September 12, 2024, 12:00pm UTC](https://discourse.julialang.org/t/modelingtoolkit-documenting-my-models/119310 "2024-09-12T12:00:24Z")

</div>

A recurring problem as my ModelingToolkit \[MTK\] models get more complex… I am running a MTK model developed for my students, i.e., the model is complete in that it runs. I now have to create a problem document for the s…

---

## [Register\_symbolic with arrays: What am I doing wrong](https://discourse.julialang.org/t/register-symbolic-with-arrays-what-am-i-doing-wrong/118655)

<div class="topic-metadata">

**Author:** [@HSnowden](https://discourse.julialang.org/u/HSnowden)\
**Replies:** 11\
**Last updated:** [September 12, 2024, 11:52am UTC](https://discourse.julialang.org/t/register-symbolic-with-arrays-what-am-i-doing-wrong/118655 "2024-09-12T11:52:06Z")

</div>

Hello, I am unable to register a symbolic function that takes an array and returns a scalar. This makes me think I need to use register\_symbolic rather than the array counterpart. However, the array that is sent is a Ve…

---

## [First Julia Meetup in Greece (Sep 03, 2024)](https://discourse.julialang.org/t/first-julia-meetup-in-greece-sep-03-2024/118798)

<div class="topic-metadata">

**Author:** [@xlxs4](https://discourse.julialang.org/u/xlxs4)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 10:30am UTC](https://discourse.julialang.org/t/first-julia-meetup-in-greece-sep-03-2024/118798 "2024-09-12T10:30:14Z")

</div>

We are excited to let you know that the first Julia user meetup in Greece will soon take place at the National Technical University of Athens (NTUA)! We’ll have talks on various things Julia, followed by a hacking/brain…

---

## [Even Gurobi is too slow for my Minecraft problem](https://discourse.julialang.org/t/even-gurobi-is-too-slow-for-my-minecraft-problem/119231)

<div class="topic-metadata">

**Author:** [@Tarny\_GG\_Channie](https://discourse.julialang.org/u/Tarny_GG_Channie)\
**Replies:** 10\
**Last updated:** [September 12, 2024, 10:28am UTC](https://discourse.julialang.org/t/even-gurobi-is-too-slow-for-my-minecraft-problem/119231 "2024-09-12T10:28:15Z")

</div>

Recently, I made a reactor designer for Minecraft Nuclearcraft. I even obtained a Gurobi license for it. Then, I tuned lots of parameters. I decided to tune up the cuts that happened a lot to be aggressive and I used the…

---

## [Keypoint based image registration using ImageTransformations.jl warp](https://discourse.julialang.org/t/keypoint-based-image-registration-using-imagetransformations-jl-warp/119158)

<div class="topic-metadata">

**Author:** [@LorMam](https://discourse.julialang.org/u/LorMam)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 10:23am UTC](https://discourse.julialang.org/t/keypoint-based-image-registration-using-imagetransformations-jl-warp/119158 "2024-09-12T10:23:50Z")

</div>

I have given two images that I want to warp on top of on another based on a number (here 6) of key points. The key point coordinates are measured using ImageJ. First, I load the images, and the key points. using …

---

## [XLSX.jl cannot handle customXml elements correctly when opening files as templates](https://discourse.julialang.org/t/xlsx-jl-cannot-handle-customxml-elements-correctly-when-opening-files-as-templates/115778)

<div class="topic-metadata">

**Author:** [@TimG](https://discourse.julialang.org/u/TimG)\
**Replies:** 10\
**Last updated:** [September 12, 2024, 10:20am UTC](https://discourse.julialang.org/t/xlsx-jl-cannot-handle-customxml-elements-correctly-when-opening-files-as-templates/115778 "2024-09-12T10:20:56Z")

</div>

This is a cross post from an issue on github. My application uses XLSX.jl to open xlsx files as templates, add data and then write them out again. It stopped working when I moved the template files to a new directory. I…

---

## [No node name error with XLSX](https://discourse.julialang.org/t/no-node-name-error-with-xlsx/90849)

<div class="topic-metadata">

**Author:** [@Pino](https://discourse.julialang.org/u/Pino)\
**Replies:** 8\
**Last updated:** [September 12, 2024, 9:30am UTC](https://discourse.julialang.org/t/no-node-name-error-with-xlsx/90849 "2024-09-12T09:30:48Z")

</div>

Hi, I’m trying to write some code to import spreadsheets into julia, stack them together in an array, manipulate them a bit and save them into a csv. I’m however having problems in importing programmatically the excel …

---

## [Is this a good workflow with Julia environment?](https://discourse.julialang.org/t/is-this-a-good-workflow-with-julia-environment/100848)

<div class="topic-metadata">

**Author:** [@WuSiren](https://discourse.julialang.org/u/WuSiren)\
**Replies:** 21\
**Last updated:** [September 12, 2024, 9:08am UTC](https://discourse.julialang.org/t/is-this-a-good-workflow-with-julia-environment/100848 "2024-09-12T09:08:41Z")

</div>

Will the following be a good workflow with Julia environment? Is there any bug in it? Or is there anything better to do? The workflow: Create a folder named myProject for a certain project. Open folder myProject with …

---

## [Optimising voronoi computation](https://discourse.julialang.org/t/optimising-voronoi-computation/119297)

<div class="topic-metadata">

**Author:** [@Manasa\_S](https://discourse.julialang.org/u/Manasa_S)\
**Replies:** 4\
**Last updated:** [September 12, 2024, 8:20am UTC](https://discourse.julialang.org/t/optimising-voronoi-computation/119297 "2024-09-12T08:20:43Z")

</div>

Hi, I am currently working on a project that needs to compute voronoi of points. The points increase exponentially over time. I am currently using DelaunayTriangulation package. I compute tri for the points and then vor…

---

## [Coupled, non-linear, time dependant system of PDE, finite element method, gridap](https://discourse.julialang.org/t/coupled-non-linear-time-dependant-system-of-pde-finite-element-method-gridap/119271)

<div class="topic-metadata">

**Author:** [@karthikeyan98pdy](https://discourse.julialang.org/u/karthikeyan98pdy)\
**Replies:** 6\
**Last updated:** [September 12, 2024, 8:01am UTC](https://discourse.julialang.org/t/coupled-non-linear-time-dependant-system-of-pde-finite-element-method-gridap/119271 "2024-09-12T08:01:54Z")

</div>

New to Julia gridap Personal context I am a phd student who works in numerical characterisation of electrochemical performance of fuel cells/electrolysis cells. This involves resolution of a system of coupled, non line…

---

## [Improving GPU performance for symbolic regression](https://discourse.julialang.org/t/improving-gpu-performance-for-symbolic-regression/108800)

<div class="topic-metadata">

**Author:** [@MilesCranmer](https://discourse.julialang.org/u/MilesCranmer)\
**Replies:** 14\
**Last updated:** [September 12, 2024, 5:58am UTC](https://discourse.julialang.org/t/improving-gpu-performance-for-symbolic-regression/108800 "2024-09-12T05:58:56Z")

</div>

I’m trying to improve the GPU performance for evaluation of an expression represented as a tree in DynamicExpressions.jl. The way it works is that an expression is created at runtime – here’s a movie of how this is used …

---

## [JuliaUserGroupMunich: Dmitry Bagaev - A path to fast and scalable Bayesian inference](https://discourse.julialang.org/t/juliausergroupmunich-dmitry-bagaev-a-path-to-fast-and-scalable-bayesian-inference/115746)

<div class="topic-metadata">

**Author:** [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)\
**Replies:** 2\
**Last updated:** [July 15, 2024, 7:59am UTC](https://discourse.julialang.org/t/juliausergroupmunich-dmitry-bagaev-a-path-to-fast-and-scalable-bayesian-inference/115746 "2024-07-15T07:59:19Z")

</div>

:round\_pushpin:online, organized via meetup :spiral\_calendar: Monday 1. July 2024 :clock6: CEST 18:00 !!! EXCEPTION: starting half an hour earlier as usual !!! Fast Bayesian Inference with RxInfer.jl ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔…

---

## [Turing: selective truncated distribution error](https://discourse.julialang.org/t/turing-selective-truncated-distribution-error/118598)

<div class="topic-metadata">

**Author:** [@Sam\_P](https://discourse.julialang.org/u/Sam_P)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 1:19am UTC](https://discourse.julialang.org/t/turing-selective-truncated-distribution-error/118598 "2024-09-12T01:19:11Z")

</div>

Hi all, I’ve been trying to fit a model to truncated discrete data using Turing, with the aim of recovering the non-truncated distribution’s parameter, and use the fitted model to predict new values based on new truncat…

---

## [Function for resuming mcmc chain](https://discourse.julialang.org/t/function-for-resuming-mcmc-chain/102308)

<div class="topic-metadata">

**Author:** [@Sahil\_Khan](https://discourse.julialang.org/u/Sahil_Khan)\
**Replies:** 13\
**Last updated:** [September 12, 2024, 1:01am UTC](https://discourse.julialang.org/t/function-for-resuming-mcmc-chain/102308 "2024-09-12T01:01:11Z")

</div>

I want to write a function so I will not have to wait for my long inference and get an end result but I will be able to get intermediate results. let’s say if I want to do inference for 100000 iteration. I can get resu…

---

## [Functional programming is not capable of achieving absolute top performance](https://discourse.julialang.org/t/functional-programming-is-not-capable-of-achieving-absolute-top-performance/119233)

<div class="topic-metadata">

**Author:** [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Replies:** 20\
**Last updated:** [September 12, 2024, 12:57am UTC](https://discourse.julialang.org/t/functional-programming-is-not-capable-of-achieving-absolute-top-performance/119233 "2024-09-12T00:57:33Z")

</div>

I was just playing around with the best way to compute the mean and standard deviation of a vector of values. Obviously, sum(x), std(x) is the cleanest but it isn’t the fastest, as I assume that approach needs to scan t…

---

## [Importance Sampling in Turing](https://discourse.julialang.org/t/importance-sampling-in-turing/118179)

<div class="topic-metadata">

**Author:** [@ArnoStrouwen](https://discourse.julialang.org/u/ArnoStrouwen)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 12:57am UTC](https://discourse.julialang.org/t/importance-sampling-in-turing/118179 "2024-09-12T00:57:49Z")

</div>

The summary from importance sampling is very different from NUTS, and just seems to summarize the prior distribution: using Turing @model function gdemo(x, y) s² ~ InverseGamma(2, 3) m ~ Normal(0, sqrt(s²)) …

---

## [Compilers, purity, and variance computation](https://discourse.julialang.org/t/compilers-purity-and-variance-computation/119254)

<div class="topic-metadata">

**Author:** [@Palli](https://discourse.julialang.org/u/Palli)\
**Replies:** 5\
**Last updated:** [September 10, 2024, 6:35pm UTC](https://discourse.julialang.org/t/compilers-purity-and-variance-computation/119254 "2024-09-10T18:35:13Z")

</div>

MOST likely you call sum, then std, i.e. separate loops and scan twice, BUT technically the functional approach doesn’t rule out optimal performance: scanning just once… In theory the compiler (of functional languages a…

---

## [Hierarchical proposal in AdvancedMH.jl](https://discourse.julialang.org/t/hierarchical-proposal-in-advancedmh-jl/117204)

<div class="topic-metadata">

**Author:** [@janglaubitz](https://discourse.julialang.org/u/janglaubitz)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 12:44am UTC](https://discourse.julialang.org/t/hierarchical-proposal-in-advancedmh-jl/117204 "2024-09-12T00:44:51Z")

</div>

I am trying to use AdvancedMH.jl within Turing.jl to perform static MH sampling for a hierarchical model: @model function model\_toyProblem\_original( y, σ², β, ϑ ) θ ~ Gamma( β, ϑ ) # hyper-prior model x ~ Norma…

---

## [ERROR: UndefVarError: \`install\` not defined](https://discourse.julialang.org/t/error-undefvarerror-install-not-defined/119305)

<div class="topic-metadata">

**Author:** [@phylo\_nick](https://discourse.julialang.org/u/phylo_nick)\
**Replies:** 1\
**Last updated:** [September 12, 2024, 12:24am UTC](https://discourse.julialang.org/t/error-undefvarerror-install-not-defined/119305 "2024-09-12T00:24:39Z")

</div>

I am trying to get R working in Julia to no avail. Here is my input: using Pkg Pkg.add("RCall") using RCall install.packages("ape", "coda", "RColorBrewer", "fields") Output: ERROR: UndefVarError: \`install\` not define…

---

## [Does Julia support Zen 4 CPUs?](https://discourse.julialang.org/t/does-julia-support-zen-4-cpus/119224)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 9\
**Last updated:** [September 11, 2024, 10:46pm UTC](https://discourse.julialang.org/t/does-julia-support-zen-4-cpus/119224 "2024-09-11T22:46:23Z")

</div>

I have a laptop with an Ryzen 7 7840U CPU, which - according to https://www.amd.com/en/products/processors/laptop/ryzen/7000-series/amd-ryzen-7-7840u.html - has a Zen 4 architecture. In Julia 1.10.5, the output of Sys.…

---

## [AI (Codeium) is amazing with Julia](https://discourse.julialang.org/t/ai-codeium-is-amazing-with-julia/119284)

<div class="topic-metadata">

**Author:** [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Replies:** 5\
**Last updated:** [September 11, 2024, 10:20pm UTC](https://discourse.julialang.org/t/ai-codeium-is-amazing-with-julia/119284 "2024-09-11T22:20:59Z")

</div>

Hi! As I mentioned before, I am rewriting PrettyTables.jl to make the system cleaner and allow more features. In this endeavor, I decided to install and use Codeium, a LLM that integrates very nice with Neovim. I just …

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

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