# Latest

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

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

**Page:** 1390

---

## [How to decode an HTTP payload to a string?](https://discourse.julialang.org/t/how-to-decode-an-http-payload-to-a-string/60999)

<div class="topic-metadata">

**Author:** [@ben-schulz](https://discourse.julialang.org/u/ben-schulz)\
**Replies:** 7\
**Last updated:** [May 18, 2021, 3:25am UTC](https://discourse.julialang.org/t/how-to-decode-an-http-payload-to-a-string/60999 "2021-05-18T03:25:36Z")

</div>

suppose i have the following call to HTTP.jl: using HTTP rsp = HTTP.request("GET", "https://www.google.com") rsp appears to contain the target HTML document, since a call to print displays what look like the first few …

---

## [Colored surface in Makie](https://discourse.julialang.org/t/colored-surface-in-makie/61009)

<div class="topic-metadata">

**Author:** [@grero](https://discourse.julialang.org/u/grero)\
**Replies:** 6\
**Last updated:** [May 18, 2021, 2:38am UTC](https://discourse.julialang.org/t/colored-surface-in-makie/61009 "2021-05-18T02:38:00Z")

</div>

I’m trying to draw transparent surfaces in Makie to illustrate separation boundaries between clusters. However, I can’t seem to get the surface function to respect the color argument. It seems to use the default colormap…

---

## [Constraint MINLP problem](https://discourse.julialang.org/t/constraint-minlp-problem/61272)

<div class="topic-metadata">

**Author:** [@Francisco\_Javier\_Mar](https://discourse.julialang.org/u/Francisco_Javier_Mar)\
**Replies:** 5\
**Last updated:** [May 18, 2021, 2:30am UTC](https://discourse.julialang.org/t/constraint-minlp-problem/61272 "2021-05-18T02:30:11Z")

</div>

Hello. I was wondering if someone could clarify a question for me. I have a problem when it comes to modeling in JuMP. I have a MINLP problem with the following objective function and constraints. @NLobjective(model,Min…

---

## [Memory reuse problem in for loop](https://discourse.julialang.org/t/memory-reuse-problem-in-for-loop/61290)

<div class="topic-metadata">

**Author:** [@deil](https://discourse.julialang.org/u/deil)\
**Replies:** 10\
**Last updated:** [May 18, 2021, 2:24am UTC](https://discourse.julialang.org/t/memory-reuse-problem-in-for-loop/61290 "2021-05-18T02:24:31Z")

</div>

I was implementing an algorithm to detect edges in RGB images, when I noticed very high memory usage: function coloredge(img::Matrix{RGB{T}})::Matrix{T} where T \<: AbstractFloat Sy, Sx = size(img) z = zeros…

---

## [Double function definition](https://discourse.julialang.org/t/double-function-definition/61330)

<div class="topic-metadata">

**Author:** [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)\
**Replies:** 5\
**Last updated:** [May 17, 2021, 11:21pm UTC](https://discourse.julialang.org/t/double-function-definition/61330 "2021-05-17T23:21:46Z")

</div>

Wondering if it is possible to define two functions with the same sugar as for variable definition (ex: x, y = 1.0, -pi): h(x,y), g(x,y) = y-x, y-2x # Error (h,g)(x,y) = y-x, y-2x # OK but what is it? h(1,1), g(1…

---

## [Deleted Julia kernel from Jupyter Notebook, but now I can't get it back](https://discourse.julialang.org/t/deleted-julia-kernel-from-jupyter-notebook-but-now-i-cant-get-it-back/61329)

<div class="topic-metadata">

**Author:** [@Michael\_Barmann](https://discourse.julialang.org/u/Michael_Barmann)\
**Replies:** 2\
**Last updated:** [May 17, 2021, 10:56pm UTC](https://discourse.julialang.org/t/deleted-julia-kernel-from-jupyter-notebook-but-now-i-cant-get-it-back/61329 "2021-05-17T22:56:49Z")

</div>

After downloading Julia 1.6.1, I figured I might as well remove the 1.5.3 and 1.6.0 kernels that I had installed on Jupyter Notebook, which I did using the instructions here: How to remove previous version from Jupyter? …

---

## [Extracting dense submatrix from sparse matrix](https://discourse.julialang.org/t/extracting-dense-submatrix-from-sparse-matrix/61242)

<div class="topic-metadata">

**Author:** [@foobar\_lv2](https://discourse.julialang.org/u/foobar_lv2)\
**Replies:** 2\
**Last updated:** [May 17, 2021, 10:50pm UTC](https://discourse.julialang.org/t/extracting-dense-submatrix-from-sparse-matrix/61242 "2021-05-17T22:50:19Z")

</div>

Hi, I’m new to GPU programming in general and julia-GPU in specific. So sorry if my question turns out to be naive. I have a largish sparse matrix; given a sorted array of indices I need to extract the corresponding sub…

---

## [Placing breakpoints dynamically in code and debugging with vs-code](https://discourse.julialang.org/t/placing-breakpoints-dynamically-in-code-and-debugging-with-vs-code/61270)

<div class="topic-metadata">

**Author:** [@Jorge\_Pereira](https://discourse.julialang.org/u/Jorge_Pereira)\
**Replies:** 4\
**Last updated:** [May 17, 2021, 10:37pm UTC](https://discourse.julialang.org/t/placing-breakpoints-dynamically-in-code-and-debugging-with-vs-code/61270 "2021-05-17T22:37:48Z")

</div>

I’m new to julia and i was wondering how to place a breakpoint dynamically through code, and debugging with the vs-code extension. For example, on Windows, with the Visual Studio IDE and C++, we can use something like \_\_…

---

## [Non-unicode versions of unicode functions in base/stdlib?](https://discourse.julialang.org/t/non-unicode-versions-of-unicode-functions-in-base-stdlib/13401)

<div class="topic-metadata">

**Author:** [@galenlynch](https://discourse.julialang.org/u/galenlynch)\
**Replies:** 10\
**Last updated:** [May 16, 2021, 2:03pm UTC](https://discourse.julialang.org/t/non-unicode-versions-of-unicode-functions-in-base-stdlib/13401 "2021-05-16T14:03:35Z")

</div>

I’m looking at someone else’s code in Julia 1.0 and noticed they use the ∉ (not in) function, which doesn’t seem to have an ascii equivalent (e.g. notin). I realize that it’s possible to get the same functionality by typ…

---

## [Using macros to modify function bodies](https://discourse.julialang.org/t/using-macros-to-modify-function-bodies/61319)

<div class="topic-metadata">

**Author:** [@jmuchovej](https://discourse.julialang.org/u/jmuchovej)\
**Replies:** 1\
**Last updated:** [May 17, 2021, 9:16pm UTC](https://discourse.julialang.org/t/using-macros-to-modify-function-bodies/61319 "2021-05-17T21:16:52Z")

</div>

I’m coming from Python, attempting to build a Julia equivalent of huggingface/knockknock. Briefly: KnockKnock decorates Python functions notifying you when said functions begin execution and fail/complete execution. My g…

---

## [Annotations and line widths in Plots.jl heatmaps](https://discourse.julialang.org/t/annotations-and-line-widths-in-plots-jl-heatmaps/4259)

<div class="topic-metadata">

**Author:** [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Replies:** 5\
**Last updated:** [May 17, 2021, 9:13pm UTC](https://discourse.julialang.org/t/annotations-and-line-widths-in-plots-jl-heatmaps/4259 "2021-05-17T21:13:08Z")

</div>

One of the nicest features of heatmaps in the Python’s Seaborn module is the ability to annotate heatmaps with the values in the cells, the axes labels, and the line style separating the cells as you can see in these exa…

---

## [Comparing symbols with == vs ===](https://discourse.julialang.org/t/comparing-symbols-with-vs/56569)

<div class="topic-metadata">

**Author:** [@sijo](https://discourse.julialang.org/u/sijo)\
**Replies:** 7\
**Last updated:** [May 17, 2021, 8:59pm UTC](https://discourse.julialang.org/t/comparing-symbols-with-vs/56569 "2021-05-17T20:59:23Z")

</div>

The documentation of Symbol says Symbols are immutable and should be compared using ===. Is that for the same reason that it was recommended to use === when checking for missing or nothing? And following the merge o…

---

## [Annotations with Plots.jl and PGFPlotsX using plot!(add=..., extra\_kwargs=:subplots)](https://discourse.julialang.org/t/annotations-with-plots-jl-and-pgfplotsx-using-plot-add-extra-kwargs-subplots/61323)

<div class="topic-metadata">

**Author:** [@tapia](https://discourse.julialang.org/u/tapia)\
**Replies:** 0\
**Last updated:** [May 17, 2021, 8:47pm UTC](https://discourse.julialang.org/t/annotations-with-plots-jl-and-pgfplotsx-using-plot-add-extra-kwargs-subplots/61323 "2021-05-17T20:47:12Z")

</div>

Hi, I am relatively new to julia and Plots, but have a solid background with matplotlib and TikZ. I have been using Plots.jl for the last few days together with the PGFPlotX backend and I really like it. One think that I…

---

## [Code templates, quoting, and variable substitution](https://discourse.julialang.org/t/code-templates-quoting-and-variable-substitution/61306)

<div class="topic-metadata">

**Author:** [@Mark\_Nahabedian](https://discourse.julialang.org/u/Mark_Nahabedian)\
**Replies:** 3\
**Last updated:** [May 17, 2021, 8:21pm UTC](https://discourse.julialang.org/t/code-templates-quoting-and-variable-substitution/61306 "2021-05-17T20:21:12Z")

</div>

I’m having trouble with code templates, quoting, and variables. I’m using the NativeSVG package. Some of its SVG element definitions don’t allow content even though they should. In particular, I’d like to add a title …

---

## [Makie equivalent of matplotlib's \`PolyCollection\`](https://discourse.julialang.org/t/makie-equivalent-of-matplotlibs-polycollection/61061)

<div class="topic-metadata">

**Author:** [@goretkin](https://discourse.julialang.org/u/goretkin)\
**Replies:** 4\
**Last updated:** [May 17, 2021, 8:16pm UTC](https://discourse.julialang.org/t/makie-equivalent-of-matplotlibs-polycollection/61061 "2021-05-17T20:16:06Z")

</div>

I’m looking to reproduce something like the following in Makie: using PyPlot const PolyCollection = PyPlot.matplotlib.collections.PolyCollection polygon = \[\[0.0, 0.0\], \[1.0, 0.0\], \[0.0, 1.0\]\] # force new axes ax = PyPl…

---

## [Compatibility entry for julia itself is ignored](https://discourse.julialang.org/t/compatibility-entry-for-julia-itself-is-ignored/61309)

<div class="topic-metadata">

**Author:** [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Replies:** 2\
**Last updated:** [May 17, 2021, 7:28pm UTC](https://discourse.julialang.org/t/compatibility-entry-for-julia-itself-is-ignored/61309 "2021-05-17T19:28:47Z")

</div>

I ran package activation and instantiation for a package that specified julia 1.5.4 in julia 1.6.0. I used the specifier julia = "~1.5.4", which I believe allows only the patch number to vary. However, there was no error…

---

## [Not sure how to tie all the functionality together](https://discourse.julialang.org/t/not-sure-how-to-tie-all-the-functionality-together/61316)

<div class="topic-metadata">

**Author:** [@anon69491625](https://discourse.julialang.org/u/anon69491625)\
**Replies:** 0\
**Last updated:** [May 17, 2021, 7:06pm UTC](https://discourse.julialang.org/t/not-sure-how-to-tie-all-the-functionality-together/61316 "2021-05-17T19:06:04Z")

</div>

Hi there I am confident I can write functions in Julia ( thanks to the wonderful book ( the julia language handbook by George Root) but I am NOT confident I know how to tie all the functions together in the same manner …

---

## [Arithmetic operators on bool type](https://discourse.julialang.org/t/arithmetic-operators-on-bool-type/61192)

<div class="topic-metadata">

**Author:** [@roi.holtzman](https://discourse.julialang.org/u/roi.holtzman)\
**Replies:** 10\
**Last updated:** [May 17, 2021, 6:27pm UTC](https://discourse.julialang.org/t/arithmetic-operators-on-bool-type/61192 "2021-05-17T18:27:19Z")

</div>

I need to manipulate an array that can take the values -1,+1. I was thinking that it would be memory efficient to use a Bool array. I also need to perform calculations, and when I operate on a false it gives back 0. Is …

---

## [DiffEqParamEstim.jl and multiple\_shooting\_objective](https://discourse.julialang.org/t/diffeqparamestim-jl-and-multiple-shooting-objective/61140)

<div class="topic-metadata">

**Author:** [@cricci](https://discourse.julialang.org/u/cricci)\
**Replies:** 6\
**Last updated:** [May 17, 2021, 6:05pm UTC](https://discourse.julialang.org/t/diffeqparamestim-jl-and-multiple-shooting-objective/61140 "2021-05-17T18:05:08Z")

</div>

I am reading through the tutorial of DiffEqParamEstim.jl (Optimization-Based ODE Parameter Estimation · DiffEqParamEstim.jl) in the section of multiple shooting method. The code put together reads the following using D…

---

## [Problem of convergence for the SH model](https://discourse.julialang.org/t/problem-of-convergence-for-the-sh-model/61307)

<div class="topic-metadata">

**Author:** [@Frazze](https://discourse.julialang.org/u/Frazze)\
**Replies:** 11\
**Last updated:** [May 17, 2021, 5:05pm UTC](https://discourse.julialang.org/t/problem-of-convergence-for-the-sh-model/61307 "2021-05-17T17:05:58Z")

</div>

Hi everyone, I’m trying to solving the Swift Hohenberg 2D model as a ODE problem, but it works only on a short time range and reducing the resolution of my grid. I believe that the problem is not only an optimization p…

---

## [Flatten in case column contains string and array](https://discourse.julialang.org/t/flatten-in-case-column-contains-string-and-array/61284)

<div class="topic-metadata">

**Author:** [@rocco\_sprmnt21](https://discourse.julialang.org/u/rocco_sprmnt21)\
**Replies:** 6\
**Last updated:** [May 17, 2021, 4:58pm UTC](https://discourse.julialang.org/t/flatten-in-case-column-contains-string-and-array/61284 "2021-05-17T16:58:00Z")

</div>

I would like to have clarification (or even simply comments) on the behavior of the flatten function in the case of the example of column y. using DataFrames df=DataFrame(x=rand(1:20,5),y=\["aa",\["a1","a2"\],"bbb",\[1,2,3\]…

---

## [Tips for making a program more Julian](https://discourse.julialang.org/t/tips-for-making-a-program-more-julian/61266)

<div class="topic-metadata">

**Author:** [@Vero](https://discourse.julialang.org/u/Vero)\
**Replies:** 25\
**Last updated:** [May 17, 2021, 4:32pm UTC](https://discourse.julialang.org/t/tips-for-making-a-program-more-julian/61266 "2021-05-17T16:32:42Z")

</div>

Hi there! I’m new to Julia and have been experimenting with it the past few months. I had been using it more as a workspace by which I could complete my school work than as a programming language. That changed recently a…

---

## [Manifest.toml for reproducible code: is it even useful cross-platform?](https://discourse.julialang.org/t/manifest-toml-for-reproducible-code-is-it-even-useful-cross-platform/61293)

<div class="topic-metadata">

**Author:** [@mauro3](https://discourse.julialang.org/u/mauro3)\
**Replies:** 11\
**Last updated:** [May 17, 2021, 4:31pm UTC](https://discourse.julialang.org/t/manifest-toml-for-reproducible-code-is-it-even-useful-cross-platform/61293 "2021-05-17T16:31:41Z")

</div>

The Manifest.toml records the state of all installed packages of a “project” (I’m interested in “projects” here not “packages”). I’m collaborating on a project with someone on Windows, I’m on Linux. In general, instant…

---

## [Jointly simulate high, low, and terminal value of Brownian motion](https://discourse.julialang.org/t/jointly-simulate-high-low-and-terminal-value-of-brownian-motion/61075)

<div class="topic-metadata">

**Author:** [@Beliavsky](https://discourse.julialang.org/u/Beliavsky)\
**Replies:** 3\
**Last updated:** [May 17, 2021, 4:00pm UTC](https://discourse.julialang.org/t/jointly-simulate-high-low-and-terminal-value-of-brownian-motion/61075 "2021-05-17T16:00:43Z")

</div>

You can simulate the terminal value of a 1D Brownian motion using a Gaussian random number generator, randn in Julia. For some problems you would like to simulate the maximum and minimum in addition to the terminal value…

---

## [Weird allocation issue for fill! with ArrayPartition in Julia \< 1.6](https://discourse.julialang.org/t/weird-allocation-issue-for-fill-with-arraypartition-in-julia-1-6/61296)

<div class="topic-metadata">

**Author:** [@Salmon](https://discourse.julialang.org/u/Salmon)\
**Replies:** 1\
**Last updated:** [May 17, 2021, 3:31pm UTC](https://discourse.julialang.org/t/weird-allocation-issue-for-fill-with-arraypartition-in-julia-1-6/61296 "2021-05-17T15:31:10Z")

</div>

Hello Julians, I have an issue with allocations that I encountered while running my code on a cluster which uses Julia 1.5.4. Basically, once my partition array gets reasonably large, I encounter many allocations when c…

---

## [Doubt in using the Reexport.jl command](https://discourse.julialang.org/t/doubt-in-using-the-reexport-jl-command/61085)

<div class="topic-metadata">

**Author:** [@RaquelSantos](https://discourse.julialang.org/u/RaquelSantos)\
**Replies:** 5\
**Last updated:** [May 17, 2021, 3:21pm UTC](https://discourse.julialang.org/t/doubt-in-using-the-reexport-jl-command/61085 "2021-05-17T15:21:19Z")

</div>

I have a model and I would like to use it in two environments, one for the code base and the other for exporting and expanding the methods. But I don’t know how to use the command. Can anybody help me? Thanks :smiley: …

---

## [How to use Makie to visualize network data in 3D?](https://discourse.julialang.org/t/how-to-use-makie-to-visualize-network-data-in-3d/61197)

<div class="topic-metadata">

**Author:** [@Junars](https://discourse.julialang.org/u/Junars)\
**Replies:** 7\
**Last updated:** [May 16, 2021, 2:07pm UTC](https://discourse.julialang.org/t/how-to-use-makie-to-visualize-network-data-in-3d/61197 "2021-05-16T14:07:14Z")

</div>

I have a custom node type and I want to be able to present data dynamically in real time. Maybe I should do it in another language？ Hope a simple example. Thx!!!

---

## [Strange Pluto performance on Binder](https://discourse.julialang.org/t/strange-pluto-performance-on-binder/61305)

<div class="topic-metadata">

**Author:** [@mihalybaci](https://discourse.julialang.org/u/mihalybaci)\
**Replies:** 0\
**Last updated:** [May 17, 2021, 2:06pm UTC](https://discourse.julialang.org/t/strange-pluto-performance-on-binder/61305 "2021-05-17T14:06:13Z")

</div>

I created a Pluto notebook to capture some the performance tips in the manual, and everything seems to run fine on my home computer. But I am getting an odd result when trying to run the notebook on Binder using this Plu…

---

## [Leftjoin order of dataframe](https://discourse.julialang.org/t/leftjoin-order-of-dataframe/61170)

<div class="topic-metadata">

**Author:** [@yogi1](https://discourse.julialang.org/u/yogi1)\
**Replies:** 5\
**Last updated:** [May 17, 2021, 1:46pm UTC](https://discourse.julialang.org/t/leftjoin-order-of-dataframe/61170 "2021-05-17T13:46:09Z")

</div>

Hi all, I have updated my DataFrames package from v0.22.5 to v1.1.1. I have a leftjoin function in my code that is no longer working as expected. The leftjoin function has changed order from the first dataframe. e.g.…

---

## [Pattern for managing thread local storage?](https://discourse.julialang.org/t/pattern-for-managing-thread-local-storage/54023)

<div class="topic-metadata">

**Author:** [@dmitrip](https://discourse.julialang.org/u/dmitrip)\
**Replies:** 5\
**Last updated:** [May 17, 2021, 1:19pm UTC](https://discourse.julialang.org/t/pattern-for-managing-thread-local-storage/54023 "2021-05-17T13:19:18Z")

</div>

What’s a good pattern for preallocating buffers in a multithreaded setting? I want to avoid allocating new memory whenever I launch a task on a thread. So far I’ve been using the following pattern, which maintains a po…

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

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