# Latest

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

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

**Page:** 799

---

## [NaNs In The Output of SVD](https://discourse.julialang.org/t/nans-in-the-output-of-svd/93712)

<div class="topic-metadata">

**Author:** [@robin-armstrong](https://discourse.julialang.org/u/robin-armstrong)\
**Replies:** 1\
**Last updated:** [January 28, 2023, 10:22pm UTC](https://discourse.julialang.org/t/nans-in-the-output-of-svd/93712 "2023-01-28T22:22:47Z")

</div>

I am currently running numerical experiments which involve computing the SVD of a very large number of random matrices. Occasionally, Julia’s SVD function will return a Vt factor that contains a row of all NaNs. Here is …

---

## [How do I get allocations down but keep code speed?](https://discourse.julialang.org/t/how-do-i-get-allocations-down-but-keep-code-speed/93692)

<div class="topic-metadata">

**Author:** [@Ahmed\_Salih](https://discourse.julialang.org/u/Ahmed_Salih)\
**Replies:** 9\
**Last updated:** [January 28, 2023, 9:11pm UTC](https://discourse.julialang.org/t/how-do-i-get-allocations-down-but-keep-code-speed/93692 "2023-01-28T21:11:17Z")

</div>

using CUDA, StaticArrays, Flux N = 10^6 T = Float32 WgL = CuArray(rand(SVector{3,T},N)) I\_ = CuArray(rand(1:6195,N)) J\_ = CuArray(rand(1:6195,N)) WGL = CuArray(zeros(SVector{3,T},N)) CUDA.@allocated WGL .= WgL\[I\_\] -…

---

## [New package: ApproximateVI.jl](https://discourse.julialang.org/t/new-package-approximatevi-jl/93454)

<div class="topic-metadata">

**Author:** [@Nikos\_Gianniotis](https://discourse.julialang.org/u/Nikos_Gianniotis)\
**Replies:** 5\
**Last updated:** [January 28, 2023, 7:56pm UTC](https://discourse.julialang.org/t/new-package-approximatevi-jl/93454 "2023-01-28T19:56:57Z")

</div>

Hello everyone, I recently wrapped up some code of mine and decided for my own sake to package it and register it with general Julia registry. The package can be found here: The package is about approximating an intr…

---

## [@df not defined](https://discourse.julialang.org/t/df-not-defined/44897)

<div class="topic-metadata">

**Author:** [@1634](https://discourse.julialang.org/u/1634)\
**Replies:** 6\
**Last updated:** [January 28, 2023, 5:52pm UTC](https://discourse.julialang.org/t/df-not-defined/44897 "2023-01-28T17:52:28Z")

</div>

Hiya, this is the example given by Plots.jl for plotting with dataframe (Tutorial · Plots). But everytime I tried, it reported ERROR: LoadError: UndefVarError: @df not defined Is there anything I missed causing this er…

---

## [Calling repl from Julia code?](https://discourse.julialang.org/t/calling-repl-from-julia-code/7263)

<div class="topic-metadata">

**Author:** [@Gyslain](https://discourse.julialang.org/u/Gyslain)\
**Replies:** 4\
**Last updated:** [January 28, 2023, 4:46pm UTC](https://discourse.julialang.org/t/calling-repl-from-julia-code/7263 "2023-01-28T16:46:03Z")

</div>

Hey, I would like to launch the REPL from a script in order to have an interactive session at a point of execution of my Julia program. Base.\_start() start the REPL, but after that, the program is stuck in the loop of t…

---

## [Where to set a timeout on a task](https://discourse.julialang.org/t/where-to-set-a-timeout-on-a-task/93579)

<div class="topic-metadata">

**Author:** [@1153dent](https://discourse.julialang.org/u/1153dent)\
**Replies:** 2\
**Last updated:** [January 28, 2023, 4:40pm UTC](https://discourse.julialang.org/t/where-to-set-a-timeout-on-a-task/93579 "2023-01-28T16:40:48Z")

</div>

hi there Has anyone got an effective approach to setting a timeout on multiple async calls. So if I send out 10 calls each with it’s own id and timer. I would handle the callback in a wrapper. Can I determine WHICH ti…

---

## [\[ANN\]: RxInfer.jl 2.0 Julia package for automated Bayesian inference on a factor graph with reactive message passing](https://discourse.julialang.org/t/ann-rxinfer-jl-2-0-julia-package-for-automated-bayesian-inference-on-a-factor-graph-with-reactive-message-passing/89879)

<div class="topic-metadata">

**Author:** [@bvdmitri](https://discourse.julialang.org/u/bvdmitri)\
**Replies:** 23\
**Last updated:** [January 28, 2023, 4:37pm UTC](https://discourse.julialang.org/t/ann-rxinfer-jl-2-0-julia-package-for-automated-bayesian-inference-on-a-factor-graph-with-reactive-message-passing/89879 "2023-01-28T16:37:44Z")

</div>

We are excited to announce the release of RxInfer 2.0, which is a Julia package for fast and scalable Bayesian inference in probabilistic models. RxInfer unites previously released packages ReactiveMP, GraphPPL, and Ro…

---

## [R2 utility function for glm GeneralizedLinearModel](https://discourse.julialang.org/t/r2-utility-function-for-glm-generalizedlinearmodel/93694)

<div class="topic-metadata">

**Author:** [@jcbritobr](https://discourse.julialang.org/u/jcbritobr)\
**Replies:** 6\
**Last updated:** [January 28, 2023, 3:36pm UTC](https://discourse.julialang.org/t/r2-utility-function-for-glm-generalizedlinearmodel/93694 "2023-01-28T15:36:19Z")

</div>

Hello, good afternoon. There are a r2 utility function for glm GeneralizedLinearModel? r2 only works with LinearModel. Also, the coefficients from sklearn had some value differences from glm. Someone knows if sklear d…

---

## [Forecasting time series with NeuralODE, Lux, DiffEqFlux](https://discourse.julialang.org/t/forecasting-time-series-with-neuralode-lux-diffeqflux/93613)

<div class="topic-metadata">

**Author:** [@ASe](https://discourse.julialang.org/u/ASe)\
**Replies:** 2\
**Last updated:** [January 28, 2023, 2:56pm UTC](https://discourse.julialang.org/t/forecasting-time-series-with-neuralode-lux-diffeqflux/93613 "2023-01-28T14:56:05Z")

</div>

Dear all, First of all, thank you very much for this supportive environment here. As suggested, I moved my question to a separate thread. Unfortunately, I am neither very familiar with neural nets nor with details in J…

---

## [Address the error "BoundsError: attempt to access 0-element Vector{Float64} at index \[1\]"](https://discourse.julialang.org/t/address-the-error-boundserror-attempt-to-access-0-element-vector-float64-at-index-1/93683)

<div class="topic-metadata">

**Author:** [@Kanishk](https://discourse.julialang.org/u/Kanishk)\
**Replies:** 3\
**Last updated:** [January 28, 2023, 1:28pm UTC](https://discourse.julialang.org/t/address-the-error-boundserror-attempt-to-access-0-element-vector-float64-at-index-1/93683 "2023-01-28T13:28:53Z")

</div>

Hello I am using the “IntervalArithmetic.jl” package in Pluto.jl notebook. While executing the code code I am getting the following error BoundsError: attempt to access 0-element Vector{Float64} at index \[1\] getindex(:…

---

## [Why does this not work in Flux?](https://discourse.julialang.org/t/why-does-this-not-work-in-flux/93689)

<div class="topic-metadata">

**Author:** [@Ahmed\_Salih](https://discourse.julialang.org/u/Ahmed_Salih)\
**Replies:** 0\
**Last updated:** [January 28, 2023, 1:16pm UTC](https://discourse.julialang.org/t/why-does-this-not-work-in-flux/93689 "2023-01-28T13:16:53Z")

</div>

Hello! New to the Flux library. I went through their documentian and understand how it works for arrays of one dimension. I am trying to use it on GPU. The code I use is: using Flux, CUDA, StaticArrays T = Float32 NL…

---

## [Wrong kwarg in docstring for Pkg.add?](https://discourse.julialang.org/t/wrong-kwarg-in-docstring-for-pkg-add/93688)

<div class="topic-metadata">

**Author:** [@TheLateKronos](https://discourse.julialang.org/u/TheLateKronos)\
**Replies:** 0\
**Last updated:** [January 28, 2023, 1:05pm UTC](https://discourse.julialang.org/t/wrong-kwarg-in-docstring-for-pkg-add/93688 "2023-01-28T13:05:58Z")

</div>

The following example from the doctring for Pkg.add must be wrong: Pkg.add(url="/remote/mycompany/juliapackages/OurPackage") # From path to local gitrepo Surely the kwarg should be path, right?

---

## [Zygote gradient with custom type results in error](https://discourse.julialang.org/t/zygote-gradient-with-custom-type-results-in-error/93519)

<div class="topic-metadata">

**Author:** [@maxfreu](https://discourse.julialang.org/u/maxfreu)\
**Replies:** 2\
**Last updated:** [January 28, 2023, 12:59pm UTC](https://discourse.julialang.org/t/zygote-gradient-with-custom-type-results-in-error/93519 "2023-01-28T12:59:58Z")

</div>

Hi! I’m once more struggling with Zygote. I’m trying to maximize the kernel-correlation between two point sets in 2D. Imagine two scattered sets of points, calculate the distances between all points in one set to all poi…

---

## [Disconnecting/deleting services](https://discourse.julialang.org/t/disconnecting-deleting-services/93687)

<div class="topic-metadata">

**Author:** [@lobingera](https://discourse.julialang.org/u/lobingera)\
**Replies:** 1\
**Last updated:** [January 28, 2023, 12:55pm UTC](https://discourse.julialang.org/t/disconnecting-deleting-services/93687 "2023-01-28T12:55:25Z")

</div>

Hi, i have stopped using (and contributing to) julia some time ago already, now i’m taking down the accounts and connections. a) How to delete the slack account? b) How to delete the discourse account? c) How to tran…

---

## [@turbo macro giving slightly different results](https://discourse.julialang.org/t/turbo-macro-giving-slightly-different-results/93529)

<div class="topic-metadata">

**Author:** [@Shashank](https://discourse.julialang.org/u/Shashank)\
**Replies:** 6\
**Last updated:** [January 28, 2023, 10:37am UTC](https://discourse.julialang.org/t/turbo-macro-giving-slightly-different-results/93529 "2023-01-28T10:37:03Z")

</div>

I am trying to vectorize a loop, and adding the turbo gives slightly different results. The code does not rely on specific execution order as is the case with the example in the post below: I have pasted a MWE below. …

---

## [Symbolic matrix multiplication to polynomial](https://discourse.julialang.org/t/symbolic-matrix-multiplication-to-polynomial/93679)

<div class="topic-metadata">

**Author:** [@jar1](https://discourse.julialang.org/u/jar1)\
**Replies:** 1\
**Last updated:** [January 28, 2023, 9:46am UTC](https://discourse.julialang.org/t/symbolic-matrix-multiplication-to-polynomial/93679 "2023-01-28T09:46:57Z")

</div>

Can I get a polynomial out of this? julia\> @variables x\[1:3\] y\[1:3\] 3-element Vector{Symbolics.Arr{Num}}: x\[1:3\] y\[1:3\] julia\> A = \[ 1 2 14 -5 2 -3 8 19 -2 \] 3×3 Mat…

---

## [Why does GPU allocate so much for me?](https://discourse.julialang.org/t/why-does-gpu-allocate-so-much-for-me/93681)

<div class="topic-metadata">

**Author:** [@Ahmed\_Salih](https://discourse.julialang.org/u/Ahmed_Salih)\
**Replies:** 1\
**Last updated:** [January 28, 2023, 9:41am UTC](https://discourse.julialang.org/t/why-does-gpu-allocate-so-much-for-me/93681 "2023-01-28T09:41:35Z")

</div>

Hello! Probably a noob question, but got to ask :slight\_smile: Suppose I have: using CUDA N = 10^6 AGPU = CuArray(rand(N)) BGPU = CuArray(rand(N)) ACPU = rand(N) BCPU = rand(N) # Why does GPU allocate so much mo…

---

## [Workflow for forking an environment](https://discourse.julialang.org/t/workflow-for-forking-an-environment/93660)

<div class="topic-metadata">

**Author:** [@jar1](https://discourse.julialang.org/u/jar1)\
**Replies:** 7\
**Last updated:** [January 28, 2023, 8:14am UTC](https://discourse.julialang.org/t/workflow-for-forking-an-environment/93660 "2023-01-28T08:14:27Z")

</div>

I have a “main” environment that has a lot of the packages I use. Whenever I want to try something out, I go to a new directory and I want to use those packages plus a couple of other packages. I don’t want to reinstal…

---

## [Unable to use CUDA from artifacts](https://discourse.julialang.org/t/unable-to-use-cuda-from-artifacts/86854)

<div class="topic-metadata">

**Author:** [@yoshi](https://discourse.julialang.org/u/yoshi)\
**Replies:** 5\
**Last updated:** [January 28, 2023, 8:06am UTC](https://discourse.julialang.org/t/unable-to-use-cuda-from-artifacts/86854 "2023-01-28T08:06:46Z")

</div>

I’m trying to use julia in an HPC environment. I load the CUDA driver using slurm’s “module” functionality. I can see where it is in the $PATH variable. But when I go to run “pkg\> test CUDA” I get warnings saying “This v…

---

## [Multi-Threading with GPU](https://discourse.julialang.org/t/multi-threading-with-gpu/93542)

<div class="topic-metadata">

**Author:** [@frog](https://discourse.julialang.org/u/frog)\
**Replies:** 3\
**Last updated:** [January 28, 2023, 2:42am UTC](https://discourse.julialang.org/t/multi-threading-with-gpu/93542 "2023-01-28T02:42:46Z")

</div>

Attempting to create a program that gets the maximum number of threads available for a system GPU ( CUDA ) and runs a function per thread. First the program gets the total number of available threads and adds a slight b…

---

## [Is accessing the \`instance\` field of a singleton type supported usage?](https://discourse.julialang.org/t/is-accessing-the-instance-field-of-a-singleton-type-supported-usage/93671)

<div class="topic-metadata">

**Author:** [@nsajko](https://discourse.julialang.org/u/nsajko)\
**Replies:** 2\
**Last updated:** [January 28, 2023, 12:48am UTC](https://discourse.julialang.org/t/is-accessing-the-instance-field-of-a-singleton-type-supported-usage/93671 "2023-01-28T00:48:56Z")

</div>

The above technique is very useful in rare cases, but I wonder whether it’s supported? I don’t think it’s documented. For example; is the below guaranteed to work with future Julia versions? julia\> Tuple{Nothing, Noth…

---

## [MOI Count Repetitions of Integers](https://discourse.julialang.org/t/moi-count-repetitions-of-integers/93545)

<div class="topic-metadata">

**Author:** [@Stuart\_Rogers](https://discourse.julialang.org/u/Stuart_Rogers)\
**Replies:** 6\
**Last updated:** [January 26, 2023, 7:43am UTC](https://discourse.julialang.org/t/moi-count-repetitions-of-integers/93545 "2023-01-26T07:43:05Z")

</div>

Given a vector of integers, is there a MOI constraint that will count the number of repetitions of each distinct integer in the vector?

---

## [Danger of deleting .julia?](https://discourse.julialang.org/t/danger-of-deleting-julia/93372)

<div class="topic-metadata">

**Author:** [@jar1](https://discourse.julialang.org/u/jar1)\
**Replies:** 19\
**Last updated:** [January 27, 2023, 9:54pm UTC](https://discourse.julialang.org/t/danger-of-deleting-julia/93372 "2023-01-27T21:54:42Z")

</div>

From thread Please refrain from doing such dangerous suggestions again. What is the danger of deleting .julia?

---

## [How to switch between several layouts in Makie?](https://discourse.julialang.org/t/how-to-switch-between-several-layouts-in-makie/93578)

<div class="topic-metadata">

**Author:** [@pzabka](https://discourse.julialang.org/u/pzabka)\
**Replies:** 6\
**Last updated:** [January 27, 2023, 9:51pm UTC](https://discourse.julialang.org/t/how-to-switch-between-several-layouts-in-makie/93578 "2023-01-27T21:51:42Z")

</div>

Hello, I am creating a GUI in Makie, and I would like to be able to change the layout with a menu widget. So far, I can add widgets (GridLaouts) at runtime, but I didn’t find how to hide or replace them. See the mwe bel…

---

## [How to see every allocating function call?](https://discourse.julialang.org/t/how-to-see-every-allocating-function-call/93654)

<div class="topic-metadata">

**Author:** [@Ahmed\_Salih](https://discourse.julialang.org/u/Ahmed_Salih)\
**Replies:** 1\
**Last updated:** [January 27, 2023, 8:34pm UTC](https://discourse.julialang.org/t/how-to-see-every-allocating-function-call/93654 "2023-01-27T20:34:25Z")

</div>

Hello! I have a small simulation program I made in Julia. I have a main function, that when I call it, it runs the whole function - lets call it Main(). Is there a macro similar to @profile for getting how many allocs …

---

## [Can I "warm start" Optim.jl's BFGS more cleanly?](https://discourse.julialang.org/t/can-i-warm-start-optim-jls-bfgs-more-cleanly/93648)

<div class="topic-metadata">

**Author:** [@lrnv](https://discourse.julialang.org/u/lrnv)\
**Replies:** 1\
**Last updated:** [January 27, 2023, 7:28pm UTC](https://discourse.julialang.org/t/can-i-warm-start-optim-jls-bfgs-more-cleanly/93648 "2023-01-27T19:28:31Z")

</div>

Hey, I am solving a series of problems which are in some sense very small modifications from one another. At eash step, I modify my loss using the information from the inverse hessian obtained by BFGS, and then i resta…

---

## [Is there any demonstration project somewhere?](https://discourse.julialang.org/t/is-there-any-demonstration-project-somewhere/93651)

<div class="topic-metadata">

**Author:** [@MIZ](https://discourse.julialang.org/u/MIZ)\
**Replies:** 2\
**Last updated:** [January 27, 2023, 8:13pm UTC](https://discourse.julialang.org/t/is-there-any-demonstration-project-somewhere/93651 "2023-01-27T20:13:49Z")

</div>

Hi all Is there any demonstration project somewhere? I want to create my first opinion about Julia, so I want to study any well documented, small, simple, complete app with UI, with reading and writing files, including…

---

## [SymPy: solving a system of equation and replacing the values in the original expression](https://discourse.julialang.org/t/sympy-solving-a-system-of-equation-and-replacing-the-values-in-the-original-expression/93653)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 1\
**Last updated:** [January 27, 2023, 6:06pm UTC](https://discourse.julialang.org/t/sympy-solving-a-system-of-equation-and-replacing-the-values-in-the-original-expression/93653 "2023-01-27T18:06:45Z")

</div>

Hello, I am trying to replicate this (old) simple example on symbolically finding the resolution of a system of equations and replacing an expression with the founded numerical solution: I arrived to it by manually r…

---

## [How to see all installed packages? + a few other \`Pkg\` related questions](https://discourse.julialang.org/t/how-to-see-all-installed-packages-a-few-other-pkg-related-questions/1231)

<div class="topic-metadata">

**Author:** [@chobbes](https://discourse.julialang.org/u/chobbes)\
**Replies:** 27\
**Last updated:** [January 27, 2023, 2:17am UTC](https://discourse.julialang.org/t/how-to-see-all-installed-packages-a-few-other-pkg-related-questions/1231 "2023-01-27T02:17:42Z")

</div>

I have more than a hundred packages installed. But Pkg.installed() only lists some 40 due to the size of the terminal window. How can I see all installed packages? Also, how can I have the installed packages printed…

---

## [Broadcasting string $variable](https://discourse.julialang.org/t/broadcasting-string-variable/93488)

<div class="topic-metadata">

**Author:** [@Lincoln\_Hannah](https://discourse.julialang.org/u/Lincoln_Hannah)\
**Replies:** 12\
**Last updated:** [January 27, 2023, 5:36pm UTC](https://discourse.julialang.org/t/broadcasting-string-variable/93488 "2023-01-27T17:36:05Z")

</div>

Is it possible to do something like this: ."X$(1:3)" and get @\_ "X$\_".(1:3) = \["X1","X2","X3"\] That is, can a vector variable within a string (via $) create a vector of strings. One for each element.

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

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