# Latest

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

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

**Page:** 1456

---

## [How to export Julia functions to python?](https://discourse.julialang.org/t/how-to-export-julia-functions-to-python/57440)

<div class="topic-metadata">

**Author:** [@morphism](https://discourse.julialang.org/u/morphism)\
**Replies:** 2\
**Last updated:** [March 18, 2021, 6:03am UTC](https://discourse.julialang.org/t/how-to-export-julia-functions-to-python/57440 "2021-03-18T06:03:06Z")

</div>

Hello, everyone I followed the steps in building Julia library. https://julialang.github.io/PackageCompiler.jl/dev/devdocs/binaries\_part\_2/?fbclid=IwAR06HyDGHE6s8Ko1TaM5mC\_xPBmcGBhQ5VrKu-qU\_dgap9k190p6cbMd9Pw But I fo…

---

## [Signing the points were 2 functions are equal](https://discourse.julialang.org/t/signing-the-points-were-2-functions-are-equal/57442)

<div class="topic-metadata">

**Author:** [@leopdsf](https://discourse.julialang.org/u/leopdsf)\
**Replies:** 2\
**Last updated:** [March 18, 2021, 6:10am UTC](https://discourse.julialang.org/t/signing-the-points-were-2-functions-are-equal/57442 "2021-03-18T06:10:24Z")

</div>

Hello, there! I’m working with some numerical calculations, plotting 2 diferent functions as follows: using Plots h=0 K=1.5 g(y) = y j(y) = tanh(K\*y+h) plot(g,xlim=(-1.5,1.5),label=("g(y)=y"),xlabel=("y"),ylabel=("g(…

---

## [Accessing variables in a ModelingToolkit system](https://discourse.julialang.org/t/accessing-variables-in-a-modelingtoolkit-system/57249)

<div class="topic-metadata">

**Author:** [@Dhruva2](https://discourse.julialang.org/u/Dhruva2)\
**Replies:** 9\
**Last updated:** [March 18, 2021, 5:59am UTC](https://discourse.julialang.org/t/accessing-variables-in-a-modelingtoolkit-system/57249 "2021-03-18T05:59:12Z")

</div>

First off, the new functionality for connecting systems in ModelingToolkit is really powerful, awesome job! I have a few issues with it that I can’t solve, however… Suppose I have a ModelingToolkit ODESystem od::ODESy…

---

## [Dash.jl - Plotly mapbox layer/trace support](https://discourse.julialang.org/t/dash-jl-plotly-mapbox-layer-trace-support/57438)

<div class="topic-metadata">

**Author:** [@spcogg](https://discourse.julialang.org/u/spcogg)\
**Replies:** 0\
**Last updated:** [March 18, 2021, 5:05am UTC](https://discourse.julialang.org/t/dash-jl-plotly-mapbox-layer-trace-support/57438 "2021-03-18T05:05:54Z")

</div>

Does anyone know if the julia Dash.jl interface currently supports mapbox layers , specifically, the scattermapbox trace I can see references to it in code, e.g. the docstrings for the dcc\_graph function, but i can’t s…

---

## [Overriding default proxy setup in Julia for Windows](https://discourse.julialang.org/t/overriding-default-proxy-setup-in-julia-for-windows/57159)

<div class="topic-metadata">

**Author:** [@wsshin](https://discourse.julialang.org/u/wsshin)\
**Replies:** 2\
**Last updated:** [March 18, 2021, 2:29am UTC](https://discourse.julialang.org/t/overriding-default-proxy-setup-in-julia-for-windows/57159 "2021-03-18T02:29:16Z")

</div>

I am a Mac user, but need to test Julia on Windows for my work at the job. During pkg\> add PyCall, I get the following error message during the build procedure (reproduced by pkg\> build PyCall): pkg\> build PyCall …

---

## [Slow gzip streaming in julia but not in python](https://discourse.julialang.org/t/slow-gzip-streaming-in-julia-but-not-in-python/56346)

<div class="topic-metadata">

**Author:** [@calvin](https://discourse.julialang.org/u/calvin)\
**Replies:** 19\
**Last updated:** [March 18, 2021, 2:18am UTC](https://discourse.julialang.org/t/slow-gzip-streaming-in-julia-but-not-in-python/56346 "2021-03-18T02:18:05Z")

</div>

Hi there, I am new to Julia, and come to Julia for performance with fewer codes. I have been using R, and encountered a simple task: read from a gziped file and do something to each line. It was slow in R, of course. So…

---

## [PyCall giving Ptr instead of PyObject](https://discourse.julialang.org/t/pycall-giving-ptr-instead-of-pyobject/57422)

<div class="topic-metadata">

**Author:** [@Satvik](https://discourse.julialang.org/u/Satvik)\
**Replies:** 2\
**Last updated:** [March 18, 2021, 1:53am UTC](https://discourse.julialang.org/t/pycall-giving-ptr-instead-of-pyobject/57422 "2021-03-18T01:53:00Z")

</div>

Hi, I’m trying to load a python file that was pickled using joblib. The file is a python dict that contains several objects, including a few DataFrames. When I load the dict in Python it’s fine, but when I try to load i…

---

## [Too much allocations](https://discourse.julialang.org/t/too-much-allocations/57366)

<div class="topic-metadata">

**Author:** [@powerzf](https://discourse.julialang.org/u/powerzf)\
**Replies:** 4\
**Last updated:** [March 18, 2021, 12:33am UTC](https://discourse.julialang.org/t/too-much-allocations/57366 "2021-03-18T00:33:59Z")

</div>

abstract type CVGSurface end struct Triangle \<: CVGSurface triangleID :: Int64 x :: Float64 y :: Float64 z :: Float64 end Triangle() = Triangle(1,1.0,1.0,1.0) struct TrBoundry \<:CVGSurface tri…

---

## [Finding unique columns of a matrix](https://discourse.julialang.org/t/finding-unique-columns-of-a-matrix/57421)

<div class="topic-metadata">

**Author:** [@angeloaliano1](https://discourse.julialang.org/u/angeloaliano1)\
**Replies:** 3\
**Last updated:** [March 18, 2021, 12:07am UTC](https://discourse.julialang.org/t/finding-unique-columns-of-a-matrix/57421 "2021-03-18T00:07:42Z")

</div>

Dear all, I have a matrix A: A = \[ 1.0 0.0 0.0 0.0 1.0 1.0 3.0 0.0 0.0 1.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 3.0 1.0 0.0 0.0 0.0 1.0 11.0 0.0 0.0 0.0 1.0 0.0 6.0 0.0 0.…

---

## [Read a dictionary JLD2 file dumped by python in julia](https://discourse.julialang.org/t/read-a-dictionary-jld2-file-dumped-by-python-in-julia/57418)

<div class="topic-metadata">

**Author:** [@Sebastian\_Mena](https://discourse.julialang.org/u/Sebastian_Mena)\
**Replies:** 3\
**Last updated:** [March 17, 2021, 10:17pm UTC](https://discourse.julialang.org/t/read-a-dictionary-jld2-file-dumped-by-python-in-julia/57418 "2021-03-17T22:17:04Z")

</div>

Hi, I am trying to import a dictionary that I saved in python with the extension .jld2 First, I tried this code to do that: \> using JSON \> using DataStructures \> using JLD2 \> dict\_name = load("path/dict\_name.jld2") A…

---

## [Is it possible to write something like:\`\`\`op = :(&amp;&amp;)set = AndSet@eval f](https://discourse.julialang.org/t/is-it-possible-to-write-something-like-op-amp-amp-set-andset-eval-f/57417)

<div class="topic-metadata">

**Author:** [@BridgeBot](https://discourse.julialang.org/u/BridgeBot)\
**Replies:** 1\
**Last updated:** [March 17, 2021, 10:04pm UTC](https://discourse.julialang.org/t/is-it-possible-to-write-something-like-op-amp-amp-set-andset-eval-f/57417 "2021-03-17T22:04:51Z")

</div>

is it possible to write something like: op = :(&&) set = AndSet @eval do\_some\_operation(::$set, lhs, rhs) = lhs $op $rhs ? The $op part does not get parsed as hoped. Any way to rewrite this to make it possible? Note t…

---

## [Pkg.TOML.ParserError](https://discourse.julialang.org/t/pkg-toml-parsererror/57350)

<div class="topic-metadata">

**Author:** [@highflyer737](https://discourse.julialang.org/u/highflyer737)\
**Replies:** 5\
**Last updated:** [March 17, 2021, 9:58pm UTC](https://discourse.julialang.org/t/pkg-toml-parsererror/57350 "2021-03-17T21:58:03Z")

</div>

Hi, I’ve been using Julia without issue for 6+ months. A few weeks ago I turned my computer in for a SSD upgrade, resulting in a fresh install of Win10 (and therefore Julia). I am now seeing Pkg.TOML.ParserErrors. Afte…

---

## [Generic edgeMap function for graph algorithms like Bellman-Ford](https://discourse.julialang.org/t/generic-edgemap-function-for-graph-algorithms-like-bellman-ford/57416)

<div class="topic-metadata">

**Author:** [@Aje12](https://discourse.julialang.org/u/Aje12)\
**Replies:** 0\
**Last updated:** [March 17, 2021, 9:17pm UTC](https://discourse.julialang.org/t/generic-edgemap-function-for-graph-algorithms-like-bellman-ford/57416 "2021-03-17T21:17:49Z")

</div>

Hi everyone, Apologies for this being a long one. I am working with the bellman ford algorithm from lightgraphs.jl but having an issue with some of my functions. My intension behind this is to have a general mapping fun…

---

## [\[ANN\] DispatchedTuples.jl: A Dict/NamedTuple-like gpu-friendly data structure](https://discourse.julialang.org/t/ann-dispatchedtuples-jl-a-dict-namedtuple-like-gpu-friendly-data-structure/57415)

<div class="topic-metadata">

**Author:** [@charleskawczynski](https://discourse.julialang.org/u/charleskawczynski)\
**Replies:** 0\
**Last updated:** [March 17, 2021, 9:11pm UTC](https://discourse.julialang.org/t/ann-dispatchedtuples-jl-a-dict-namedtuple-like-gpu-friendly-data-structure/57415 "2021-03-17T21:11:20Z")

</div>

DispatchedTuples.jl is a very lightweight package that defines an efficient Dict/NamedTuple-like data structure that is gpu-friendly (as they are tuple-backed). The main difference between a NamedTuple and a DispatchedT…

---

## [Performance of a key step in Strang Splitting method](https://discourse.julialang.org/t/performance-of-a-key-step-in-strang-splitting-method/57312)

<div class="topic-metadata">

**Author:** [@jacobusmmsmit](https://discourse.julialang.org/u/jacobusmmsmit)\
**Replies:** 10\
**Last updated:** [March 17, 2021, 8:39pm UTC](https://discourse.julialang.org/t/performance-of-a-key-step-in-strang-splitting-method/57312 "2021-03-17T20:39:08Z")

</div>

Hello, My friend is working on a problem solving a 3+1 Dimensional non-linear PDE using a two-step operator splitting scheme. His code is in MATLAB and I suggested he try out Julia as it gives you more of a toolkit to o…

---

## [Return type of \`sum\` with nested function is inferred as \`Any\`](https://discourse.julialang.org/t/return-type-of-sum-with-nested-function-is-inferred-as-any/57407)

<div class="topic-metadata">

**Author:** [@Uroc327](https://discourse.julialang.org/u/Uroc327)\
**Replies:** 6\
**Last updated:** [March 17, 2021, 8:30pm UTC](https://discourse.julialang.org/t/return-type-of-sum-with-nested-function-is-inferred-as-any/57407 "2021-03-17T20:30:40Z")

</div>

I have a function that sums over expressions calling nested functions. I noticed that the function runs rather slowly. Upon further investigation, julia seems to be unable to infer the return type of this function. The …

---

## [LoadError: MethodError: Cannot \`convert\` an object of type Array{Float64,2} to an object of type EasyFITS.FitsImage{Float64,2}](https://discourse.julialang.org/t/loaderror-methoderror-cannot-convert-an-object-of-type-array-float64-2-to-an-object-of-type-easyfits-fitsimage-float64-2/57097)

<div class="topic-metadata">

**Author:** [@assia855](https://discourse.julialang.org/u/assia855)\
**Replies:** 4\
**Last updated:** [March 17, 2021, 8:20pm UTC](https://discourse.julialang.org/t/loaderror-methoderror-cannot-convert-an-object-of-type-array-float64-2-to-an-object-of-type-easyfits-fitsimage-float64-2/57097 "2021-03-17T20:20:48Z")

</div>

LoadError: MethodError: Cannot convert an object of type Array{Float64,2} to an object of type EasyFITS.FitsImage{Float64,2} Closest candidates are: convert(::Type{#s15} where #s15\<:AbstractArray, ::EasyFITS.FitsImage)…

---

## [Union{Some{T}, Nothing} behaviour](https://discourse.julialang.org/t/union-some-t-nothing-behaviour/57353)

<div class="topic-metadata">

**Author:** [@Jake](https://discourse.julialang.org/u/Jake)\
**Replies:** 7\
**Last updated:** [March 17, 2021, 3:51pm UTC](https://discourse.julialang.org/t/union-some-t-nothing-behaviour/57353 "2021-03-17T15:51:44Z")

</div>

I cannot figure out how to obtain a non-nothing output from the following code. julia\> struct B a::Union{Some{T}, Nothing} where {T\<:Integer} end julia\> b = B(nothing) B(nothing) julia\> b = B(5) ERRO…

---

## [Vectorization when broadcasting vector of structs](https://discourse.julialang.org/t/vectorization-when-broadcasting-vector-of-structs/57410)

<div class="topic-metadata">

**Author:** [@gbaraldi](https://discourse.julialang.org/u/gbaraldi)\
**Replies:** 0\
**Last updated:** [March 17, 2021, 8:02pm UTC](https://discourse.julialang.org/t/vectorization-when-broadcasting-vector-of-structs/57410 "2021-03-17T20:02:11Z")

</div>

Recently on slack I was discussing about the performance of generic structs and whether or not they should be vectorized and while exploring I found some interesting results. using BenchmarkTools struct TestType{𝒯} …

---

## [Set array dimensions in composite type](https://discourse.julialang.org/t/set-array-dimensions-in-composite-type/57123)

<div class="topic-metadata">

**Author:** [@weymouth](https://discourse.julialang.org/u/weymouth)\
**Replies:** 14\
**Last updated:** [March 17, 2021, 7:52pm UTC](https://discourse.julialang.org/t/set-array-dimensions-in-composite-type/57123 "2021-03-17T19:52:14Z")

</div>

How can you define arrays of increasing dimension in a composite type when they have a simple form such as the following? struct compound{N} # N is the number of spatial dimensions of the field scalar\_field :: Array…

---

## [Displaying a parquet file in Arrow](https://discourse.julialang.org/t/displaying-a-parquet-file-in-arrow/57398)

<div class="topic-metadata">

**Author:** [@oo92](https://discourse.julialang.org/u/oo92)\
**Replies:** 7\
**Last updated:** [March 17, 2021, 7:32pm UTC](https://discourse.julialang.org/t/displaying-a-parquet-file-in-arrow/57398 "2021-03-17T19:32:34Z")

</div>

Hi. I am trying to add a Parquet file into Arrow. I tried to follow the Arrow.jl docs and implement it like this: begin df = CSV.read("/home/onur/julia-assignment/temp.csv", DataFrame) file = file = "/home/onur/julia…

---

## [Is there a direct Julia equivalent of Rust's \`retain()\` method?](https://discourse.julialang.org/t/is-there-a-direct-julia-equivalent-of-rusts-retain-method/57391)

<div class="topic-metadata">

**Author:** [@BridgeBot](https://discourse.julialang.org/u/BridgeBot)\
**Replies:** 2\
**Last updated:** [March 17, 2021, 3:43pm UTC](https://discourse.julialang.org/t/is-there-a-direct-julia-equivalent-of-rusts-retain-method/57391 "2021-03-17T15:43:33Z")

</div>

Is there a direct Julia equivalent of Rust’s retain() method? Note that the original poster on Slack cannot see your response here on Discourse. Consider transcribing the appropriate answer back to Slack, or pinging the…

---

## [Avoiding allocations for function arguments with non-concrete types](https://discourse.julialang.org/t/avoiding-allocations-for-function-arguments-with-non-concrete-types/57263)

<div class="topic-metadata">

**Author:** [@Nicholaswogan](https://discourse.julialang.org/u/Nicholaswogan)\
**Replies:** 8\
**Last updated:** [March 17, 2021, 6:34pm UTC](https://discourse.julialang.org/t/avoiding-allocations-for-function-arguments-with-non-concrete-types/57263 "2021-03-17T18:34:46Z")

</div>

Hi, I am beginning to learn how to build my own types, and pass them to functions with different methods for different input types. Below is a chemistry example problem. I do not understand one of the allocations involve…

---

## [How to 'using a\_local\_module'](https://discourse.julialang.org/t/how-to-using-a-local-module/57389)

<div class="topic-metadata">

**Author:** [@hpw](https://discourse.julialang.org/u/hpw)\
**Replies:** 5\
**Last updated:** [March 17, 2021, 6:18pm UTC](https://discourse.julialang.org/t/how-to-using-a-local-module/57389 "2021-03-17T18:18:38Z")

</div>

In a project directory, I have a main.jl and a myModule.jl myModule.jl. contains module myModule … end In the main.jl, how do I use myModule ? using myModule and import myModule both are for modules already r…

---

## [In Makie, when should a function accept \`fig\[1,1\]\` as input, vs an \`Axis\`?](https://discourse.julialang.org/t/in-makie-when-should-a-function-accept-fig-1-1-as-input-vs-an-axis/57399)

<div class="topic-metadata">

**Author:** [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Replies:** 1\
**Last updated:** [March 17, 2021, 5:26pm UTC](https://discourse.julialang.org/t/in-makie-when-should-a-function-accept-fig-1-1-as-input-vs-an-axis/57399 "2021-03-17T17:26:28Z")

</div>

I don’t really when to use an Axis vs indexing like fig\[1,1\] . If I’m writing a function to make part of a plot, should I be passing it fig\[1,1\] or an axis? should the function be making the axis and returning it? From @…

---

## [ANN: LoopVectorization 0.12: multithreading and better handling of discontiguous memory accesses](https://discourse.julialang.org/t/ann-loopvectorization-0-12-multithreading-and-better-handling-of-discontiguous-memory-accesses/57262)

<div class="topic-metadata">

**Author:** [@Elrod](https://discourse.julialang.org/u/Elrod)\
**Replies:** 16\
**Last updated:** [March 17, 2021, 4:25pm UTC](https://discourse.julialang.org/t/ann-loopvectorization-0-12-multithreading-and-better-handling-of-discontiguous-memory-accesses/57262 "2021-03-17T16:25:48Z")

</div>

I thought LoopVectorization 0.12 brought enough exciting improvements to warrant an update. Probably most exciting is the addition of @avxt or equivalently @avx thread=true, which can automatically multithread for loops…

---

## [Makie stopped working on my machine after update](https://discourse.julialang.org/t/makie-stopped-working-on-my-machine-after-update/57392)

<div class="topic-metadata">

**Author:** [@tt1234567](https://discourse.julialang.org/u/tt1234567)\
**Replies:** 11\
**Last updated:** [March 17, 2021, 4:56pm UTC](https://discourse.julialang.org/t/makie-stopped-working-on-my-machine-after-update/57392 "2021-03-17T16:56:15Z")

</div>

Hello I did a package update this morning and Makie seems to have stopped working. I tried deleting the .julia directory and instantiating again but the problem didn’t change. Is it just me? using Makie fig = Makie.Fig…

---

## [Segmentation fault when trying to make a custom sysimage](https://discourse.julialang.org/t/segmentation-fault-when-trying-to-make-a-custom-sysimage/57226)

<div class="topic-metadata">

**Author:** [@sonicrules1234](https://discourse.julialang.org/u/sonicrules1234)\
**Replies:** 4\
**Last updated:** [March 17, 2021, 4:51pm UTC](https://discourse.julialang.org/t/segmentation-fault-when-trying-to-make-a-custom-sysimage/57226 "2021-03-17T16:51:17Z")

</div>

signal (11): Segmentation fault in expression starting at none:0 uv\_write2 at /workspace/srcdir/libuv/src/unix/stream.c:1397 uv\_write at /workspace/srcdir/libuv/src/unix/stream.c:1492 jl\_uv\_write at /buildworker/worker/p…

---

## [VS Code: Julia Env different in status bar and REPL](https://discourse.julialang.org/t/vs-code-julia-env-different-in-status-bar-and-repl/57369)

<div class="topic-metadata">

**Author:** [@meck](https://discourse.julialang.org/u/meck)\
**Replies:** 10\
**Last updated:** [March 17, 2021, 4:19pm UTC](https://discourse.julialang.org/t/vs-code-julia-env-different-in-status-bar-and-repl/57369 "2021-03-17T16:19:22Z")

</div>

As title already says, why does VC Code show two different activatated envs? I want to work in Oceananigans instead of in v1.5 but the REPL doesnt change.

---

## [Read complex text files in Julia](https://discourse.julialang.org/t/read-complex-text-files-in-julia/57386)

<div class="topic-metadata">

**Author:** [@baprata](https://discourse.julialang.org/u/baprata)\
**Replies:** 4\
**Last updated:** [March 17, 2021, 4:13pm UTC](https://discourse.julialang.org/t/read-complex-text-files-in-julia/57386 "2021-03-17T16:13:50Z")

</div>

I need to read this file (https://drive.google.com/file/d/1VSVxE7tMFutzNZhVmhsFnoSgCnpFZAUL/view?usp=sharing) to obtain a matrix and a vector as follows. Could anybody helps me? Array (20 x 5): 1 4 87 21 28 68 3…

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

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