# Latest

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

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

**Page:** 886

---

## [Trying to collect indices with multiple conditions](https://discourse.julialang.org/t/trying-to-collect-indices-with-multiple-conditions/89217)

<div class="topic-metadata">

**Author:** [@Muhammad\_Nadeem](https://discourse.julialang.org/u/Muhammad_Nadeem)\
**Replies:** 4\
**Last updated:** [October 25, 2022, 3:23am UTC](https://discourse.julialang.org/t/trying-to-collect-indices-with-multiple-conditions/89217 "2022-10-25T03:23:55Z")

</div>

Hello all, I am trying to find all the indicies where certain criteria is met, here is my code ind1 = Vector{Float64}(undef, 4) for i in 1:4 ind1\[i\] = intersect(findall(x-\>x==l, z), findall(sum(M\[i,j\]\*z\[j\] for j in i…

---

## [Distributing parallel tasks/workers over multiple nodes using SLURM](https://discourse.julialang.org/t/distributing-parallel-tasks-workers-over-multiple-nodes-using-slurm/60574)

<div class="topic-metadata">

**Author:** [@schmuelinsky](https://discourse.julialang.org/u/schmuelinsky)\
**Replies:** 10\
**Last updated:** [October 25, 2022, 3:41am UTC](https://discourse.julialang.org/t/distributing-parallel-tasks-workers-over-multiple-nodes-using-slurm/60574 "2022-10-25T03:41:45Z")

</div>

I’m trying to compute a series of Monte Carlo (MC) integrations on an HPC using SLURM. Since the MC samples are all independent, my approach is to distribute them as parallel tasks using pmap(). Each MC sample is quite …

---

## [Huge CPU load when using GLM](https://discourse.julialang.org/t/huge-cpu-load-when-using-glm/89209)

<div class="topic-metadata">

**Author:** [@jonjilla](https://discourse.julialang.org/u/jonjilla)\
**Replies:** 14\
**Last updated:** [October 25, 2022, 2:52am UTC](https://discourse.julialang.org/t/huge-cpu-load-when-using-glm/89209 "2022-10-25T02:52:29Z")

</div>

Hello all I’m using GLM to calculate coefficients for logistic regression. I don’t recall this being an issue when I first developed this script, but recently, I’ve noticed that this script is generating a huge load on…

---

## [Please help: Poor performance, what am I missing?](https://discourse.julialang.org/t/please-help-poor-performance-what-am-i-missing/89221)

<div class="topic-metadata">

**Author:** [@jocklawrie](https://discourse.julialang.org/u/jocklawrie)\
**Replies:** 6\
**Last updated:** [October 25, 2022, 2:01am UTC](https://discourse.julialang.org/t/please-help-poor-performance-what-am-i-missing/89221 "2022-10-25T02:01:26Z")

</div>

Hello clever people, I’m having trouble dissecting a performance problem. MWE below. The computation in the 3rd benchmark is the composition of the computations in the first 2 benchmarks. I expect the 3rd benchmark to …

---

## [Q: array of vectors?](https://discourse.julialang.org/t/q-array-of-vectors/89169)

<div class="topic-metadata">

**Author:** [@Audrius-St](https://discourse.julialang.org/u/Audrius-St)\
**Replies:** 11\
**Last updated:** [October 25, 2022, 1:53am UTC](https://discourse.julialang.org/t/q-array-of-vectors/89169 "2022-10-25T01:53:46Z")

</div>

Hello, What is the optimum representation to use to store vectors over a discrete field. For example, the discrete field being the 2D pixels of an image or the 3D voxels of an image volume? I’ll use the 2D pixel field…

---

## [Max function in differential equation](https://discourse.julialang.org/t/max-function-in-differential-equation/89176)

<div class="topic-metadata">

**Author:** [@Ge0rges](https://discourse.julialang.org/u/Ge0rges)\
**Replies:** 3\
**Last updated:** [October 24, 2022, 10:01pm UTC](https://discourse.julialang.org/t/max-function-in-differential-equation/89176 "2022-10-24T22:01:45Z")

</div>

Hello all, I have a set of differential equations I’m trying to solve. One of them includes a max() function. I am wondering if that is the reason why I am sometimes unable to solve this equation. Can the solver “integr…

---

## [Error in for loop](https://discourse.julialang.org/t/error-in-for-loop/89212)

<div class="topic-metadata">

**Author:** [@Muhammad\_Nadeem](https://discourse.julialang.org/u/Muhammad_Nadeem)\
**Replies:** 8\
**Last updated:** [October 25, 2022, 12:33am UTC](https://discourse.julialang.org/t/error-in-for-loop/89212 "2022-10-25T00:33:35Z")

</div>

Hello all, I am writing a simple code given as: for i in 1:4 b\[i\] = sum(M\[i,j\]\*z\[j\] for j in items)+sum(N\[i,j\]\*w\[j\] for j in items)+q\[i\] end print(b) it is giving me error BoundsError: attempt to access 0-element…

---

## [How to convert from bool to float](https://discourse.julialang.org/t/how-to-convert-from-bool-to-float/89216)

<div class="topic-metadata">

**Author:** [@Xavier\_Gonzalez](https://discourse.julialang.org/u/Xavier_Gonzalez)\
**Replies:** 2\
**Last updated:** [October 24, 2022, 10:40pm UTC](https://discourse.julialang.org/t/how-to-convert-from-bool-to-float/89216 "2022-10-24T22:40:58Z")

</div>

I would like to take a matrix that is currently made of bools and turn it into floats. If I is this matrix of bools, I’ve been trying commands like convert(Int8, I) and getting errors like ERROR: MethodError: Cannot \`c…

---

## [\[ANN\] Makie v0.18](https://discourse.julialang.org/t/ann-makie-v0-18/88653)

<div class="topic-metadata">

**Author:** [@sdanisch](https://discourse.julialang.org/u/sdanisch)\
**Replies:** 5\
**Last updated:** [October 24, 2022, 10:21pm UTC](https://discourse.julialang.org/t/ann-makie-v0-18/88653 "2022-10-24T22:21:10Z")

</div>

We’re happy to announce Makie v0.18! It’s a big release that we put lots of work into. It contains a few breaking changes but these should hopefully only cause minor inconvenience. You can find all the highlights in our…

---

## [Available fonts for plotting inside Plotly/PlotlyJS](https://discourse.julialang.org/t/available-fonts-for-plotting-inside-plotly-plotlyjs/89074)

<div class="topic-metadata">

**Author:** [@ellocco](https://discourse.julialang.org/u/ellocco)\
**Replies:** 2\
**Last updated:** [October 24, 2022, 9:33am UTC](https://discourse.julialang.org/t/available-fonts-for-plotting-inside-plotly-plotlyjs/89074 "2022-10-24T09:33:22Z")

</div>

Is there a way to figure out which fonts are available that can be used for PlotlyJS-plots?

---

## [Constrain type to variable sized union](https://discourse.julialang.org/t/constrain-type-to-variable-sized-union/89206)

<div class="topic-metadata">

**Author:** [@HashBrown](https://discourse.julialang.org/u/HashBrown)\
**Replies:** 2\
**Last updated:** [October 24, 2022, 9:07pm UTC](https://discourse.julialang.org/t/constrain-type-to-variable-sized-union/89206 "2022-10-24T21:07:39Z")

</div>

I want to constrain a type parameter to be a variable sized union whose elements are concrete types of another parametric type. For example: struct Foo{T} ... end struct Bar{T \<: Union{Vararg{Foo}}} a::T end T…

---

## [2022 Julia User & Developer Survey - draft questionnaire available for comment](https://discourse.julialang.org/t/2022-julia-user-developer-survey-draft-questionnaire-available-for-comment/81168)

<div class="topic-metadata">

**Author:** [@ahclaster](https://discourse.julialang.org/u/ahclaster)\
**Replies:** 9\
**Last updated:** [October 24, 2022, 8:55pm UTC](https://discourse.julialang.org/t/2022-julia-user-developer-survey-draft-questionnaire-available-for-comment/81168 "2022-10-24T20:55:35Z")

</div>

The fourth annual Julia User & Developer Survey is being developed now, and we want your input. Please do NOT complete the survey at this time. This link is being shared with you to collect feedback about the questionna…

---

## [Union Splitting Guarantees](https://discourse.julialang.org/t/union-splitting-guarantees/89210)

<div class="topic-metadata">

**Author:** [@HashBrown](https://discourse.julialang.org/u/HashBrown)\
**Replies:** 2\
**Last updated:** [October 24, 2022, 8:54pm UTC](https://discourse.julialang.org/t/union-splitting-guarantees/89210 "2022-10-24T20:54:19Z")

</div>

I have some low level questions about union splitting 1.) If even one type in the union is abstract will union splitting not kick in? Or will there be branches created for at least the concrete types in the union. For e…

---

## [Constrain type to be concrete subtype](https://discourse.julialang.org/t/constrain-type-to-be-concrete-subtype/89207)

<div class="topic-metadata">

**Author:** [@HashBrown](https://discourse.julialang.org/u/HashBrown)\
**Replies:** 3\
**Last updated:** [October 24, 2022, 8:50pm UTC](https://discourse.julialang.org/t/constrain-type-to-be-concrete-subtype/89207 "2022-10-24T20:50:12Z")

</div>

Suppose I have the following struct: struct Foo{T \<: Real} a::T end I am still able to construct a Foo as: Foo{Real}(20). Is there a way to demand that the type parameter be a concrete type such as Int64, Float64, …

---

## [Parametric type with value of custom type as type parameter](https://discourse.julialang.org/t/parametric-type-with-value-of-custom-type-as-type-parameter/89202)

<div class="topic-metadata">

**Author:** [@GoodDayToYouAll](https://discourse.julialang.org/u/GoodDayToYouAll)\
**Replies:** 4\
**Last updated:** [October 24, 2022, 8:42pm UTC](https://discourse.julialang.org/t/parametric-type-with-value-of-custom-type-as-type-parameter/89202 "2022-10-24T20:42:22Z")

</div>

Hi everyone, as the title suggests, I want to create a parametric type with the value of a custom type as type parameter. So for example struct MyType x::Int end struct MyParametricType{T} x MyParametricType(a) = new{…

---

## [Problems with integer stack size](https://discourse.julialang.org/t/problems-with-integer-stack-size/89192)

<div class="topic-metadata">

**Author:** [@mb96](https://discourse.julialang.org/u/mb96)\
**Replies:** 6\
**Last updated:** [October 24, 2022, 7:26pm UTC](https://discourse.julialang.org/t/problems-with-integer-stack-size/89192 "2022-10-24T19:26:15Z")

</div>

Hi, I am solving a optimization problem with 13104 variables the maximization is looped over some set of initial conditions. At some point I get the following problem: Can some provide some information about what in…

---

## [AoG use cases, suggestions](https://discourse.julialang.org/t/aog-use-cases-suggestions/89203)

<div class="topic-metadata">

**Author:** [@lazarusA](https://discourse.julialang.org/u/lazarusA)\
**Replies:** 0\
**Last updated:** [October 24, 2022, 6:34pm UTC](https://discourse.julialang.org/t/aog-use-cases-suggestions/89203 "2022-10-24T18:34:04Z")

</div>

Hello everyone, I would like to include some new examples in BeautifulMakie using AlgebraOfGraphics. Hence, some suggestions of common use cases will be good to have. Things that might catch the interest of people comin…

---

## [Add missing row or column to frequency table](https://discourse.julialang.org/t/add-missing-row-or-column-to-frequency-table/61794)

<div class="topic-metadata">

**Author:** [@Christopher\_Fisher](https://discourse.julialang.org/u/Christopher_Fisher)\
**Replies:** 8\
**Last updated:** [October 24, 2022, 5:59pm UTC](https://discourse.julialang.org/t/add-missing-row-or-column-to-frequency-table/61794 "2022-10-24T17:59:47Z")

</div>

Hi all, In my simulation, the results are summarized as a 2X2 frequency table. For example: using DataFrames, FreqTables df1 = DataFrame( a = \[:yes,:yes,:no,:no\], b = \[:yes,:no,:yes,:no\] ) t1 = freqtable(df1, …

---

## [\[Cancelled\] JuliaUserGroupMunich: Munich-Social on Google's Coding Competitions](https://discourse.julialang.org/t/cancelled-juliausergroupmunich-munich-social-on-googles-coding-competitions/88716)

<div class="topic-metadata">

**Author:** [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)\
**Replies:** 3\
**Last updated:** [October 24, 2022, 5:51pm UTC](https://discourse.julialang.org/t/cancelled-juliausergroupmunich-munich-social-on-googles-coding-competitions/88716 "2022-10-24T17:51:44Z")

</div>

Join us on :spiral\_calendar: Thursday 27. October 2022 :clock630: 18:15 CEST organized via meetup This is the start of a new series: The Munich-Social series. We want to meet in-person and do some Julia st…

---

## [Siamese network in Lux.jl / Re-using parts of network](https://discourse.julialang.org/t/siamese-network-in-lux-jl-re-using-parts-of-network/82013)

<div class="topic-metadata">

**Author:** [@svilupp](https://discourse.julialang.org/u/svilupp)\
**Replies:** 10\
**Last updated:** [October 24, 2022, 4:46pm UTC](https://discourse.julialang.org/t/siamese-network-in-lux-jl-re-using-parts-of-network/82013 "2022-10-24T16:46:38Z")

</div>

Hi everyone! Have you seen any examples of re-using parts of the networks in Lux.jl? I haven’t been able to find anything. I’ve been trying to put a toy example of Siamese network (ala Keras - Siamese Contrastive Loss,…

---

## [Sum rows of a matrix to create new array](https://discourse.julialang.org/t/sum-rows-of-a-matrix-to-create-new-array/9470)

<div class="topic-metadata">

**Author:** [@dhislop](https://discourse.julialang.org/u/dhislop)\
**Replies:** 11\
**Last updated:** [October 24, 2022, 3:56pm UTC](https://discourse.julialang.org/t/sum-rows-of-a-matrix-to-create-new-array/9470 "2022-10-24T15:56:26Z")

</div>

Is there a way to sum all elements in a row of a matrix and output a new single column array? For ex. if I have a matrix: 1 0 1 1 0 0 0 0 0 1 1 0 I want to sum each row to output a new array: 3 0 …

---

## [Lux and Flux GPU function definitions overlap](https://discourse.julialang.org/t/lux-and-flux-gpu-function-definitions-overlap/89149)

<div class="topic-metadata">

**Author:** [@erlebach](https://discourse.julialang.org/u/erlebach)\
**Replies:** 4\
**Last updated:** [October 24, 2022, 1:39pm UTC](https://discourse.julialang.org/t/lux-and-flux-gpu-function-definitions-overlap/89149 "2022-10-24T13:39:13Z")

</div>

I am running the NeuralODE example for GPUs. Here is the code: using DifferentialEquations, Flux, DiffEqFlux, SciMLSensitivity using Random rng = Random.default\_rng() model\_gpu = Chain(Dense(2, 50, tanh), Dense(50, 2)…

---

## [Extracting a float from a string](https://discourse.julialang.org/t/extracting-a-float-from-a-string/43126)

<div class="topic-metadata">

**Author:** [@erlebach](https://discourse.julialang.org/u/erlebach)\
**Replies:** 31\
**Last updated:** [October 24, 2022, 1:10pm UTC](https://discourse.julialang.org/t/extracting-a-float-from-a-string/43126 "2022-10-24T13:10:53Z")

</div>

I would like to extract a float from a string of the form strg = file\_t=0.234. In Python, I would use a package called scanf with similar functionality to what is offered in C++. I might also use regular expressions, bu…

---

## [Accessing an object's unparameterized type](https://discourse.julialang.org/t/accessing-an-objects-unparameterized-type/89128)

<div class="topic-metadata">

**Author:** [@uniment](https://discourse.julialang.org/u/uniment)\
**Replies:** 10\
**Last updated:** [October 24, 2022, 11:29am UTC](https://discourse.julialang.org/t/accessing-an-objects-unparameterized-type/89128 "2022-10-24T11:29:45Z")

</div>

I have a function that receives an object with parameters attached to it, and I’d like it to call the object’s constructor with those parameters removed. For example, consider: struct Test{A, B} end obj = Test{1,2}() …

---

## [How to give names to the curves in 1D graph of 2D array?](https://discourse.julialang.org/t/how-to-give-names-to-the-curves-in-1d-graph-of-2d-array/89182)

<div class="topic-metadata">

**Author:** [@ryofurue](https://discourse.julialang.org/u/ryofurue)\
**Replies:** 1\
**Last updated:** [October 24, 2022, 11:25am UTC](https://discourse.julialang.org/t/how-to-give-names-to-the-curves-in-1d-graph-of-2d-array/89182 "2022-10-24T11:25:33Z")

</div>

In my M x N array, the columns represent y values and so plot(arr) will produce N curves, which is what I need. But my question is, how can one give a name to each curve? My first intuition was to give a vector of the n…

---

## [Awkward ODE problem](https://discourse.julialang.org/t/awkward-ode-problem/88435)

<div class="topic-metadata">

**Author:** [@josuagrw](https://discourse.julialang.org/u/josuagrw)\
**Replies:** 7\
**Last updated:** [October 24, 2022, 11:14am UTC](https://discourse.julialang.org/t/awkward-ode-problem/88435 "2022-10-24T11:14:02Z")

</div>

I have a differential equation of the kind \\dot q\_1 = f(q\_1, q\_2)\\\\ A(q\_1,q\_2)\\dot q\_2=B(q\_1,q\_2)\\dot q\_1 where q\_1, q\_2 are vectors, A is a symmetric, positive-definite real matrix, and B is a real (non-square) matri…

---

## [\] dev with private Github repository](https://discourse.julialang.org/t/dev-with-private-github-repository/89188)

<div class="topic-metadata">

**Author:** [@FemtoTrader](https://discourse.julialang.org/u/FemtoTrader)\
**Replies:** 3\
**Last updated:** [October 24, 2022, 10:13am UTC](https://discourse.julialang.org/t/dev-with-private-github-repository/89188 "2022-10-24T10:13:38Z")

</div>

Hello, I did \] dev https://femtotrader@github.com/femtotrader/MyPrivateRepository.jl but it raises ERROR: ArgumentError: invalid base 10 digit 'g' in "github" is there a method to make a private repository a package…

---

## [Analysis and Diagnostics for MCMC](https://discourse.julialang.org/t/analysis-and-diagnostics-for-mcmc/3104)

<div class="topic-metadata">

**Author:** [@jacobcvt12](https://discourse.julialang.org/u/jacobcvt12)\
**Replies:** 27\
**Last updated:** [October 24, 2022, 10:05am UTC](https://discourse.julialang.org/t/analysis-and-diagnostics-for-mcmc/3104 "2022-10-24T10:05:44Z")

</div>

Is there a package in Julia similar to the coda package in R? Most of the functions in coda are pretty straightforward, but it’s nice to have a bunch of MCMC diagnostics/analysis functions all grouped together. I see tha…

---

## [Groupedbar, groupedhist, StatPlots, StatsPlots?](https://discourse.julialang.org/t/groupedbar-groupedhist-statplots-statsplots/89071)

<div class="topic-metadata">

**Author:** [@ryofurue](https://discourse.julialang.org/u/ryofurue)\
**Replies:** 7\
**Last updated:** [October 24, 2022, 8:35am UTC](https://discourse.julialang.org/t/groupedbar-groupedhist-statplots-statsplots/89071 "2022-10-24T08:35:15Z")

</div>

So, what function in what package is best for a bar chart with multiple datasets? So far I’ve been looking at the StatPlots and StatsPlots packages and groupedbar and groupedhist. I’m not able to install the former pac…

---

## [Julia present working directory](https://discourse.julialang.org/t/julia-present-working-directory/89164)

<div class="topic-metadata">

**Author:** [@Muhammad\_Nadeem](https://discourse.julialang.org/u/Muhammad_Nadeem)\
**Replies:** 4\
**Last updated:** [October 24, 2022, 6:12am UTC](https://discourse.julialang.org/t/julia-present-working-directory/89164 "2022-10-24T06:12:49Z")

</div>

Hello all, I am bit confused in working directory of Julia. So if suppose i am working in “test” folder then the working directory of Julia should be “test” i-e if i write pwd() in Julia then it should give me the test …

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

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