# Latest

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

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

**Page:** 1085

---

## [BilevelJump installation issue](https://discourse.julialang.org/t/bileveljump-installation-issue/78605)

<div class="topic-metadata">

**Author:** [@Fabrizio](https://discourse.julialang.org/u/Fabrizio)\
**Replies:** 4\
**Last updated:** [March 28, 2022, 10:43am UTC](https://discourse.julialang.org/t/bileveljump-installation-issue/78605 "2022-03-28T10:43:55Z")

</div>

Dear all, i am using Jump JuMP v0.22.1 https://github.com/jump-dev/JuMP.jl.git#master with MathOptInterface v0.10.5. Trying to installing BilevelJump give to me this issue: ERROR: Unsatisfiable requirements detected for…

---

## [Lowercase dataframe column strings with missing values](https://discourse.julialang.org/t/lowercase-dataframe-column-strings-with-missing-values/78606)

<div class="topic-metadata">

**Author:** [@zorbax](https://discourse.julialang.org/u/zorbax)\
**Replies:** 1\
**Last updated:** [March 28, 2022, 10:26am UTC](https://discourse.julialang.org/t/lowercase-dataframe-column-strings-with-missing-values/78606 "2022-03-28T10:26:39Z")

</div>

I have a Data Frame with missing values on it. using DataFrames df = DataFrame( Y = \["A", "B", "C", "D", "E", "F"\], Z = \["A", missing, "C", missing, "E", missing\] ) When I tried to transform to lowercase I got…

---

## [Julia multithreading from pycall - possible to overcome?](https://discourse.julialang.org/t/julia-multithreading-from-pycall-possible-to-overcome/78538)

<div class="topic-metadata">

**Author:** [@Fatafim](https://discourse.julialang.org/u/Fatafim)\
**Replies:** 3\
**Last updated:** [March 28, 2022, 9:05am UTC](https://discourse.julialang.org/t/julia-multithreading-from-pycall-possible-to-overcome/78538 "2022-03-28T09:05:09Z")

</div>

Say I have a jupyter notebook: %%julia using Pkg Pkg.add(“DecisionTree”) using DecisionTree X = Vector(\[1.1,2.2,3.3\]) Y = Vector(\[1.1,2.2,3.3\]) X = reshape(X, size(X)) X = Float32.(X) Y = Float32.(Y) print(typ…

---

## [DataFrame transform with many output columns](https://discourse.julialang.org/t/dataframe-transform-with-many-output-columns/78593)

<div class="topic-metadata">

**Author:** [@Mastomaki](https://discourse.julialang.org/u/Mastomaki)\
**Replies:** 1\
**Last updated:** [March 28, 2022, 8:53am UTC](https://discourse.julialang.org/t/dataframe-transform-with-many-output-columns/78593 "2022-03-28T08:53:31Z")

</div>

Hello! I can split string columns in dataframe as follows: s = DataFrame(grid = "uuu\_mygrid", e = \[3,3,3\]) transform(s, :grid =\> (ByRow(x -\> split(x,"\_"))) =\> AsTable) But how can I specify the new column names?

---

## [CUDA kernel configuration](https://discourse.julialang.org/t/cuda-kernel-configuration/78417)

<div class="topic-metadata">

**Author:** [@Marcell\_Havlik](https://discourse.julialang.org/u/Marcell_Havlik)\
**Replies:** 3\
**Last updated:** [March 28, 2022, 7:54am UTC](https://discourse.julialang.org/t/cuda-kernel-configuration/78417 "2022-03-28T07:54:41Z")

</div>

Hey Julianners, I don’t know what do I do wrong, but I use a configurator that calculates the ideal kernel config that was used here: https://discourse.julialang.org/t/the-most-general-way-to-estimate-the-optimal-argume…

---

## [DifferentialEquations.jl treat complex different than float](https://discourse.julialang.org/t/differentialequations-jl-treat-complex-different-than-float/78412)

<div class="topic-metadata">

**Author:** [@Elyco](https://discourse.julialang.org/u/Elyco)\
**Replies:** 7\
**Last updated:** [March 28, 2022, 7:06am UTC](https://discourse.julialang.org/t/differentialequations-jl-treat-complex-different-than-float/78412 "2022-03-28T07:06:17Z")

</div>

Hi, I encountered something weird when I was trying to solve a system of ODEs in two equivalent (if I don’t miss something very basic) ways. Here is two ODE, that should be mathematically the same C = -0.01+2im functi…

---

## [KAUST research Conference: Flow Simulation at the Exascale](https://discourse.julialang.org/t/kaust-research-conference-flow-simulation-at-the-exascale/78587)

<div class="topic-metadata">

**Author:** [@johnh](https://discourse.julialang.org/u/johnh)\
**Replies:** 0\
**Last updated:** [March 28, 2022, 6:40am UTC](https://discourse.julialang.org/t/kaust-research-conference-flow-simulation-at-the-exascale/78587 "2022-03-28T06:40:31Z")

</div>

https://cemse.kaust.edu.sa/exaflow

---

## [What if the \`if\` filter from generator statements worked in for loops too?](https://discourse.julialang.org/t/what-if-the-if-filter-from-generator-statements-worked-in-for-loops-too/78581)

<div class="topic-metadata">

**Author:** [@maxkapur](https://discourse.julialang.org/u/maxkapur)\
**Replies:** 4\
**Last updated:** [March 28, 2022, 6:42am UTC](https://discourse.julialang.org/t/what-if-the-if-filter-from-generator-statements-worked-in-for-loops-too/78581 "2022-03-28T06:42:57Z")

</div>

Julia lets you append if to a list comprehension to filter it inline: julia\> \[j for j in rand(1:100, 20) if iseven(j)\] 7-element Vector{Int64}: 12 82 64 58 84 76 32 Sometimes you want to do something similar in …

---

## [How to setup a Julia project to load modules depending on input and debug in vscode](https://discourse.julialang.org/t/how-to-setup-a-julia-project-to-load-modules-depending-on-input-and-debug-in-vscode/78555)

<div class="topic-metadata">

**Author:** [@sunayana](https://discourse.julialang.org/u/sunayana)\
**Replies:** 1\
**Last updated:** [March 28, 2022, 5:47am UTC](https://discourse.julialang.org/t/how-to-setup-a-julia-project-to-load-modules-depending-on-input-and-debug-in-vscode/78555 "2022-03-28T05:47:38Z")

</div>

Hi All, I am new to Julia and trying to setup a project structure in a way so that I can debug using vscode. My project structure looks like this: ├── Shared │ ├── Project.toml │ └── src │ └── Shared.jl ├── …

---

## [Make a Compose.jl composition square](https://discourse.julialang.org/t/make-a-compose-jl-composition-square/78585)

<div class="topic-metadata">

**Author:** [@theta](https://discourse.julialang.org/u/theta)\
**Replies:** 4\
**Last updated:** [March 28, 2022, 5:14am UTC](https://discourse.julialang.org/t/make-a-compose-jl-composition-square/78585 "2022-03-28T05:14:37Z")

</div>

I’m messing with Compose.jl, and I noticed that the “canvas” isn’t square like I would expect. Does anyone know how to create an explicitly square canvas? I’m using ElectronDisplay to view the SVG output from Compose, bu…

---

## [Drop specific elements of sparse arrays](https://discourse.julialang.org/t/drop-specific-elements-of-sparse-arrays/78583)

<div class="topic-metadata">

**Author:** [@fipelle](https://discourse.julialang.org/u/fipelle)\
**Replies:** 0\
**Last updated:** [March 28, 2022, 3:58am UTC](https://discourse.julialang.org/t/drop-specific-elements-of-sparse-arrays/78583 "2022-03-28T03:58:59Z")

</div>

Hi, I was wondering if it is possible to drop the i-th element of a sparse vector x (i.e., setting it to zero) in-place. I am aware that you can do something like x\[i\]=0.0; dropzeros!(x), but I was wondering if there is…

---

## [Type instability of nested recursive function](https://discourse.julialang.org/t/type-instability-of-nested-recursive-function/78392)

<div class="topic-metadata">

**Author:** [@ma-chengyuan](https://discourse.julialang.org/u/ma-chengyuan)\
**Replies:** 4\
**Last updated:** [March 28, 2022, 3:38am UTC](https://discourse.julialang.org/t/type-instability-of-nested-recursive-function/78392 "2022-03-28T03:38:10Z")

</div>

I was writing some code where I need an inner function to be recursive, something like (highly simplified) function f1(x::Vector{Int64}) function g(i, val) i \<= length(x) || return g(i + 1, val) …

---

## [Task migration & data-race freedom](https://discourse.julialang.org/t/task-migration-data-race-freedom/78552)

<div class="topic-metadata">

**Author:** [@Lilith](https://discourse.julialang.org/u/Lilith)\
**Replies:** 7\
**Last updated:** [March 28, 2022, 3:31am UTC](https://discourse.julialang.org/t/task-migration-data-race-freedom/78552 "2022-03-28T03:31:51Z")

</div>

In light of task migration, Tasks can now migrate among threads when they are re-scheduled. Previously, a Task would always run on whichever thread executed it first Can I still assume that f and g will never run con…

---

## [Section with Julia exercises, contests and equivalences with other languages](https://discourse.julialang.org/t/section-with-julia-exercises-contests-and-equivalences-with-other-languages/15116)

<div class="topic-metadata">

**Author:** [@Juan](https://discourse.julialang.org/u/Juan)\
**Replies:** 5\
**Last updated:** [March 28, 2022, 1:59am UTC](https://discourse.julialang.org/t/section-with-julia-exercises-contests-and-equivalences-with-other-languages/15116 "2022-03-28T01:59:04Z")

</div>

I think it would be a good a idea to have a category on the forum with: A collection of typical tasks solved with Julia. A daily or weekly contest where somebody raise an exercise or problem and others post their solut…

---

## [Where to find very basic exercises for a beginner?](https://discourse.julialang.org/t/where-to-find-very-basic-exercises-for-a-beginner/55277)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 17\
**Last updated:** [March 28, 2022, 1:58am UTC](https://discourse.julialang.org/t/where-to-find-very-basic-exercises-for-a-beginner/55277 "2022-03-28T01:58:01Z")

</div>

Hi, I need to help a student for a course where they teach Julia. The student provided me with last session exam content, and the questions are really, really basic. But the topics are wide (arrays, string functions, st…

---

## [Where can I excercise Julia codes and learn more](https://discourse.julialang.org/t/where-can-i-excercise-julia-codes-and-learn-more/13527)

<div class="topic-metadata">

**Author:** [@ashim-haque](https://discourse.julialang.org/u/ashim-haque)\
**Replies:** 5\
**Last updated:** [March 28, 2022, 1:56am UTC](https://discourse.julialang.org/t/where-can-i-excercise-julia-codes-and-learn-more/13527 "2022-03-28T01:56:57Z")

</div>

I am new to Julia and switching from MATLAB. I am an electrical engineer and I am not that good with programming. I am currently doing my thesis work on control system design with machine learning. Is there any web page …

---

## [Displaying Parallel Progress Bars](https://discourse.julialang.org/t/displaying-parallel-progress-bars/4148)

<div class="topic-metadata">

**Author:** [@adamslc](https://discourse.julialang.org/u/adamslc)\
**Replies:** 7\
**Last updated:** [March 27, 2022, 9:14pm UTC](https://discourse.julialang.org/t/displaying-parallel-progress-bars/4148 "2022-03-27T21:14:33Z")

</div>

I need to run many simulations that will each take several hours to complete. To speed up the process, I’m going to run several of these simulations in parallel. The trouble is, I’m not very patient, and so I want some s…

---

## [How to plot a legend with many names so that some of them don't get cut](https://discourse.julialang.org/t/how-to-plot-a-legend-with-many-names-so-that-some-of-them-dont-get-cut/78568)

<div class="topic-metadata">

**Author:** [@askvorts](https://discourse.julialang.org/u/askvorts)\
**Replies:** 2\
**Last updated:** [March 27, 2022, 8:35pm UTC](https://discourse.julialang.org/t/how-to-plot-a-legend-with-many-names-so-that-some-of-them-dont-get-cut/78568 "2022-03-27T20:35:14Z")

</div>

In a groupedbar plot, I am trying to plot the legend for a list of 30 stock names. However, using Plots, some of the bottom names in the list (e.g. WMT) do not show up in the plot legend. How may I slightly “compress”…

---

## [Help optimizing simple example](https://discourse.julialang.org/t/help-optimizing-simple-example/78556)

<div class="topic-metadata">

**Author:** [@Dan.phi](https://discourse.julialang.org/u/Dan.phi)\
**Replies:** 5\
**Last updated:** [March 27, 2022, 8:12pm UTC](https://discourse.julialang.org/t/help-optimizing-simple-example/78556 "2022-03-27T20:12:31Z")

</div>

Hi, I would appreciate if anyone could suggest an optimized version of my naïve implementation (via a loop) of the example below, which computes matrix W. This is part of an inner algorithm that is repeated thousands of…

---

## [Extracting indexes of vectors in Julia](https://discourse.julialang.org/t/extracting-indexes-of-vectors-in-julia/78547)

<div class="topic-metadata">

**Author:** [@Leticia-maria](https://discourse.julialang.org/u/Leticia-maria)\
**Replies:** 4\
**Last updated:** [March 27, 2022, 7:59pm UTC](https://discourse.julialang.org/t/extracting-indexes-of-vectors-in-julia/78547 "2022-03-27T19:59:46Z")

</div>

How to obtain the indexes of the nonzero terms of a vector in Julia? x = \[\[3, 0, 0\], \[0, 4, 0\], \[5, 6, 0\]\] output: (\[0, 1, 2, 2\]), \[0, 1, 0, 1\])

---

## [How to wait for a thread to complete](https://discourse.julialang.org/t/how-to-wait-for-a-thread-to-complete/78546)

<div class="topic-metadata">

**Author:** [@Christopher\_Fisher](https://discourse.julialang.org/u/Christopher_Fisher)\
**Replies:** 3\
**Last updated:** [March 27, 2022, 7:56pm UTC](https://discourse.julialang.org/t/how-to-wait-for-a-thread-to-complete/78546 "2022-03-27T19:56:10Z")

</div>

Hi all, I have a situation where I receive a message via ZMQ and would like to perform post processing of the reply on a separate thread and then send a reply from the main thread once the post processing is complete. I…

---

## [I am trying to import a image dataset from kaggle](https://discourse.julialang.org/t/i-am-trying-to-import-a-image-dataset-from-kaggle/78476)

<div class="topic-metadata">

**Author:** [@zed\_unseened](https://discourse.julialang.org/u/zed_unseened)\
**Replies:** 4\
**Last updated:** [March 27, 2022, 7:34pm UTC](https://discourse.julialang.org/t/i-am-trying-to-import-a-image-dataset-from-kaggle/78476 "2022-03-27T19:34:55Z")

</div>

here is also the link to the dataset: I am trying to create an image classifier using an AlexNet Architecture This is the way I tried to import the data set but I am encountering problems using Markdown using Intera…

---

## [\# of threads in Optimal Transport Package](https://discourse.julialang.org/t/of-threads-in-optimal-transport-package/78560)

<div class="topic-metadata">

**Author:** [@kadir-gunel](https://discourse.julialang.org/u/kadir-gunel)\
**Replies:** 4\
**Last updated:** [March 27, 2022, 6:38pm UTC](https://discourse.julialang.org/t/of-threads-in-optimal-transport-package/78560 "2022-03-27T18:38:25Z")

</div>

Hello, I tried to increase the # of threads in OT.jl by initializing julia with flags such as -p 16 or -t 32 but no success. I can only use 8 threads by default. Is there any way that we can increase the # of threads ? …

---

## [How to visualise the structure of the decision tree built by MLJ?](https://discourse.julialang.org/t/how-to-visualise-the-structure-of-the-decision-tree-built-by-mlj/30946)

<div class="topic-metadata">

**Author:** [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Replies:** 9\
**Last updated:** [March 27, 2022, 6:42pm UTC](https://discourse.julialang.org/t/how-to-visualise-the-structure-of-the-decision-tree-built-by-mlj/30946 "2022-03-27T18:42:08Z")

</div>

using RDatasets, DataFrames iris = dataset("datasets", "iris") using MLJ # using the MLJ framework using MLJModels # loads the modesl MLJ can use e.g. linear regression, decision tree tree\_model = @load DecisionTreeClas…

---

## [Will Julia be more efficient than PyTorch](https://discourse.julialang.org/t/will-julia-be-more-efficient-than-pytorch/78557)

<div class="topic-metadata">

**Author:** [@mindaslab](https://discourse.julialang.org/u/mindaslab)\
**Replies:** 1\
**Last updated:** [March 27, 2022, 5:29pm UTC](https://discourse.julialang.org/t/will-julia-be-more-efficient-than-pytorch/78557 "2022-03-27T17:29:19Z")

</div>

Hello All, I am very much interested in deep learning, but I realize that I cannot buy expensive hardware that industries use to train things like GPT-NeoX and so on.I wonder if a neural network is built and trained on…

---

## [Almost ready: an introductory course on Scientific Programming and Machine Learning with Julia](https://discourse.julialang.org/t/almost-ready-an-introductory-course-on-scientific-programming-and-machine-learning-with-julia/78559)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 0\
**Last updated:** [March 27, 2022, 5:14pm UTC](https://discourse.julialang.org/t/almost-ready-an-introductory-course-on-scientific-programming-and-machine-learning-with-julia/78559 "2022-03-27T17:14:55Z")

</div>

Not yet there, as I still need to (heavily) rearrange the course navigation and the content of the first introductory lesson on both the Julia & ML parts, but the content is indeed pretty ready (I will add random forests…

---

## [Flux vs Knet for research and production](https://discourse.julialang.org/t/flux-vs-knet-for-research-and-production/78449)

<div class="topic-metadata">

**Author:** [@matic\_lauko](https://discourse.julialang.org/u/matic_lauko)\
**Replies:** 8\
**Last updated:** [March 27, 2022, 4:01pm UTC](https://discourse.julialang.org/t/flux-vs-knet-for-research-and-production/78449 "2022-03-27T16:01:26Z")

</div>

I’m new to AI in julia, and to AI in general, but still want to make the best decision or at least know the reason for choice. What are the advantages and disadvantages of both packages for production and also research. …

---

## [\[ANN\] Faiss.jl, similarity search](https://discourse.julialang.org/t/ann-faiss-jl-similarity-search/78065)

<div class="topic-metadata">

**Author:** [@zsz00](https://discourse.julialang.org/u/zsz00)\
**Replies:** 18\
**Last updated:** [March 27, 2022, 3:58pm UTC](https://discourse.julialang.org/t/ann-faiss-jl-similarity-search/78065 "2022-03-27T15:58:39Z")

</div>

zsz00/Faiss.jl: Julia wrapper around the Faiss library for similarity search with PythonCall.jl (github.com) A simple Julia wrapper around the Faiss library for similarity search with PythonCall.jl . While functional …

---

## [Creating random Static Vector by StaticVector.jl and Distributions.jl in a loop](https://discourse.julialang.org/t/creating-random-static-vector-by-staticvector-jl-and-distributions-jl-in-a-loop/78439)

<div class="topic-metadata">

**Author:** [@Vahid\_Hosseinzadeh](https://discourse.julialang.org/u/Vahid_Hosseinzadeh)\
**Replies:** 4\
**Last updated:** [March 27, 2022, 3:23pm UTC](https://discourse.julialang.org/t/creating-random-static-vector-by-staticvector-jl-and-distributions-jl-in-a-loop/78439 "2022-03-27T15:23:16Z")

</div>

Hi I wand to create a random 2 vector in a loop and want it to be static. Here is the code: using StaticArrays using Distributions dist2dN = MvNormal(\[0., 0.\],\[10. 0;0 10.\]) for \_ in 1:5 x = @SVector \[i for i in r…

---

## [Modify colorbar in heatmap](https://discourse.julialang.org/t/modify-colorbar-in-heatmap/78544)

<div class="topic-metadata">

**Author:** [@RickDW](https://discourse.julialang.org/u/RickDW)\
**Replies:** 2\
**Last updated:** [March 27, 2022, 3:02pm UTC](https://discourse.julialang.org/t/modify-colorbar-in-heatmap/78544 "2022-03-27T15:02:58Z")

</div>

Hi, I’m trying to create an animation from a sequence of heatmaps, and I want to keep the upper and lower limits of the colorbar steady. I.e. if a value of say 0.5 is plotted using pure white in one frame I want 0.5 to m…

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

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