# Latest

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

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

**Page:** 1417

---

## [Periodic boundary conditions for PDE system using ModellingToolkit and DiffEqBase](https://discourse.julialang.org/t/periodic-boundary-conditions-for-pde-system-using-modellingtoolkit-and-diffeqbase/51827)

<div class="topic-metadata">

**Author:** [@archermarx](https://discourse.julialang.org/u/archermarx)\
**Replies:** 6\
**Last updated:** [April 22, 2021, 5:56am UTC](https://discourse.julialang.org/t/periodic-boundary-conditions-for-pde-system-using-modellingtoolkit-and-diffeqbase/51827 "2021-04-22T05:56:28Z")

</div>

I’m working with ModellingToolkit and DiffEqOperators to solve a set of PDEs, and I wanted to test out a simpler problem before I jumped into a more complicated problem. I followed the heat equation example and that work…

---

## [Is \`let\` the right tool for this task?](https://discourse.julialang.org/t/is-let-the-right-tool-for-this-task/59763)

<div class="topic-metadata">

**Author:** [@maxkapur](https://discourse.julialang.org/u/maxkapur)\
**Replies:** 6\
**Last updated:** [April 22, 2021, 5:55am UTC](https://discourse.julialang.org/t/is-let-the-right-tool-for-this-task/59763 "2021-04-22T05:55:22Z")

</div>

I would like to define a certain function that takes a vector as input and does some computations that involving varying just one of the entries. For example, if the input vector is a, I would like to compute f(a) whlie …

---

## [Using vs import? Would switching names make more sense?](https://discourse.julialang.org/t/using-vs-import-would-switching-names-make-more-sense/59775)

<div class="topic-metadata">

**Author:** [@AA\_julia](https://discourse.julialang.org/u/AA_julia)\
**Replies:** 2\
**Last updated:** [April 22, 2021, 5:53am UTC](https://discourse.julialang.org/t/using-vs-import-would-switching-names-make-more-sense/59775 "2021-04-22T05:53:13Z")

</div>

Hi, I know this seems too late and people already used to use both “using” and “import” as they have already defined, but I’m just wondering if it does make more sense to rename “using” as “import”, and vice versa? The …

---

## [LinearAlgebra.SingularException(9) while running radial basis function from Surrogates using multiquadric radial](https://discourse.julialang.org/t/linearalgebra-singularexception-9-while-running-radial-basis-function-from-surrogates-using-multiquadric-radial/59774)

<div class="topic-metadata">

**Author:** [@mdsa3d](https://discourse.julialang.org/u/mdsa3d)\
**Replies:** 3\
**Last updated:** [April 22, 2021, 5:41am UTC](https://discourse.julialang.org/t/linearalgebra-singularexception-9-while-running-radial-basis-function-from-surrogates-using-multiquadric-radial/59774 "2021-04-22T05:41:24Z")

</div>

I am trying to run the Radial basis from Surrogates to perform interpolation with multiquadricRadial. I have created the following script: using Surrogates using Plots; plotly() lb = \[0.0, 0.0\] ub = \[10.0, 10.0\] func…

---

## [Help using Turing for Lattice Path Integral Calculations](https://discourse.julialang.org/t/help-using-turing-for-lattice-path-integral-calculations/59777)

<div class="topic-metadata">

**Author:** [@jdhooghe](https://discourse.julialang.org/u/jdhooghe)\
**Replies:** 0\
**Last updated:** [April 22, 2021, 5:09am UTC](https://discourse.julialang.org/t/help-using-turing-for-lattice-path-integral-calculations/59777 "2021-04-22T05:09:35Z")

</div>

Hello everyone, I am hoping to gain some insight into a particular problem I want to solve which I’ve done using PyMC3 but I lack the insight at the moment to make it working using Turing/AdvancedHMC. While not the prob…

---

## [How Can I Create Permanently-Stored Lookup Tables?](https://discourse.julialang.org/t/how-can-i-create-permanently-stored-lookup-tables/59755)

<div class="topic-metadata">

**Author:** [@RalphH](https://discourse.julialang.org/u/RalphH)\
**Replies:** 11\
**Last updated:** [April 22, 2021, 4:35am UTC](https://discourse.julialang.org/t/how-can-i-create-permanently-stored-lookup-tables/59755 "2021-04-22T04:35:03Z")

</div>

Hello, everyone. How can I store computed values permanently, i.e. so they never have to be recomputed? Specifically, I have generated 2 lookup tables via lengthy Monte Carlo simulations and stored them in CSV files. I …

---

## [Using symmetry with TensorKit: ERROR: LoadError: MethodError: no method matching similarstructure\_from\_indices](https://discourse.julialang.org/t/using-symmetry-with-tensorkit-error-loaderror-methoderror-no-method-matching-similarstructure-from-indices/59572)

<div class="topic-metadata">

**Author:** [@Nellatur](https://discourse.julialang.org/u/Nellatur)\
**Replies:** 1\
**Last updated:** [April 22, 2021, 2:53am UTC](https://discourse.julialang.org/t/using-symmetry-with-tensorkit-error-loaderror-methoderror-no-method-matching-similarstructure-from-indices/59572 "2021-04-22T02:53:58Z")

</div>

I tried to utilize symmetry in tensor contraction A\[a,b\]\*B\[b,c,d\] = C\[a,c,d\] with B\[b,c,d\] = B\[b,d,c\]. Based on Tutorial · TensorKit.jl I tried the following code using TensorKit using BenchmarkTools #using Tensor…

---

## [State of the Literature/References](https://discourse.julialang.org/t/state-of-the-literature-references/51807)

<div class="topic-metadata">

**Author:** [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Replies:** 21\
**Last updated:** [April 22, 2021, 12:37am UTC](https://discourse.julialang.org/t/state-of-the-literature-references/51807 "2021-04-22T00:37:45Z")

</div>

I recently ran into the idea of using some references within my doc strings and within the documentation. Currently I do that using footnotes; which bears a small problem if one reuses a literature reference twice within…

---

## [Pros and cons of using Flux directly over using MLJ/MLJFlux](https://discourse.julialang.org/t/pros-and-cons-of-using-flux-directly-over-using-mlj-mljflux/59756)

<div class="topic-metadata">

**Author:** [@ablaom](https://discourse.julialang.org/u/ablaom)\
**Replies:** 2\
**Last updated:** [April 22, 2021, 12:07am UTC](https://discourse.julialang.org/t/pros-and-cons-of-using-flux-directly-over-using-mlj-mljflux/59756 "2021-04-22T00:07:28Z")

</div>

The following question has been posted on slack: “Can anyone guide me on the relative merits of using MLJ with MLJFlux vs. using Flux directly?”

---

## [Is there an interface to Mathematica through wolframescript?](https://discourse.julialang.org/t/is-there-an-interface-to-mathematica-through-wolframescript/35727)

<div class="topic-metadata">

**Author:** [@gangchern](https://discourse.julialang.org/u/gangchern)\
**Replies:** 22\
**Last updated:** [April 21, 2021, 11:16pm UTC](https://discourse.julialang.org/t/is-there-an-interface-to-mathematica-through-wolframescript/35727 "2021-04-21T23:16:26Z")

</div>

It should working as: input from julia , transform to Mathematica input , call run command: wolframescript some input . read the mathematica output and transform to julia output form So that I can use the mathematica…

---

## [Unpack unknown number of values](https://discourse.julialang.org/t/unpack-unknown-number-of-values/59753)

<div class="topic-metadata">

**Author:** [@jzr](https://discourse.julialang.org/u/jzr)\
**Replies:** 6\
**Last updated:** [April 21, 2021, 9:55pm UTC](https://discourse.julialang.org/t/unpack-unknown-number-of-values/59753 "2021-04-21T21:55:41Z")

</div>

Is it possible to unpack an unknown number of values, something like this? \_, x, \_... = \[1,2,3\]

---

## [Writing a dataframe to Excel XLSX](https://discourse.julialang.org/t/writing-a-dataframe-to-excel-xlsx/59748)

<div class="topic-metadata">

**Author:** [@Smith](https://discourse.julialang.org/u/Smith)\
**Replies:** 5\
**Last updated:** [April 21, 2021, 9:32pm UTC](https://discourse.julialang.org/t/writing-a-dataframe-to-excel-xlsx/59748 "2021-04-21T21:32:35Z")

</div>

Can we write a dataframe (without headers) to a specified sheet and specified cell in Excel? I have a dataframe that I want to write to a specific sheet in a spreadsheet. Consider this dataframe df = DataFrame(Name=\["aa…

---

## [Compute mean of array where all values could be missing](https://discourse.julialang.org/t/compute-mean-of-array-where-all-values-could-be-missing/59754)

<div class="topic-metadata">

**Author:** [@elbersb](https://discourse.julialang.org/u/elbersb)\
**Replies:** 5\
**Last updated:** [April 21, 2021, 8:54pm UTC](https://discourse.julialang.org/t/compute-mean-of-array-where-all-values-could-be-missing/59754 "2021-04-21T20:54:48Z")

</div>

I ran into this today: using Statsbase mean(skipmissing(\[missing\])) \> ERROR: ArgumentError: reducing over an empty collection is not allowed \> Stacktrace: \> \[1\] \_empty\_reduce\_error() \> @ Base ./reduce.jl:299 \> \[2\] …

---

## [DataFrames.jl doesn't want to precompile on Julia 1.6](https://discourse.julialang.org/t/dataframes-jl-doesnt-want-to-precompile-on-julia-1-6/59712)

<div class="topic-metadata">

**Author:** [@mixstam1453](https://discourse.julialang.org/u/mixstam1453)\
**Replies:** 5\
**Last updated:** [April 21, 2021, 8:28pm UTC](https://discourse.julialang.org/t/dataframes-jl-doesnt-want-to-precompile-on-julia-1-6/59712 "2021-04-21T20:28:02Z")

</div>

Hello, Using Julia 1.6, on debian buster 64-bit (1GB RAM). I can add and precompile successfully packages such as CSV, Plots, NCDatasets etc, but when i add DataFrames, it installed with the other packages that precomp…

---

## [Solving ODEs in a loop with DifferentialEquations.jl](https://discourse.julialang.org/t/solving-odes-in-a-loop-with-differentialequations-jl/59640)

<div class="topic-metadata">

**Author:** [@lucass-carneiro](https://discourse.julialang.org/u/lucass-carneiro)\
**Replies:** 10\
**Last updated:** [April 21, 2021, 7:54pm UTC](https://discourse.julialang.org/t/solving-odes-in-a-loop-with-differentialequations-jl/59640 "2021-04-21T19:54:04Z")

</div>

Hi there! I’m working on a problem where I must solve a system of ODEs repeatedly with different parameters and initial conditions. In particular, I’m not really interested in the solution as a whole, I only need to kno…

---

## [Derivative with Zygote/ForwardDiff of a function of multiple vectors wrt a subset of arguments](https://discourse.julialang.org/t/derivative-with-zygote-forwarddiff-of-a-function-of-multiple-vectors-wrt-a-subset-of-arguments/59560)

<div class="topic-metadata">

**Author:** [@Albert\_Zevelev](https://discourse.julialang.org/u/Albert_Zevelev)\
**Replies:** 1\
**Last updated:** [April 21, 2021, 7:48pm UTC](https://discourse.julialang.org/t/derivative-with-zygote-forwarddiff-of-a-function-of-multiple-vectors-wrt-a-subset-of-arguments/59560 "2021-04-21T19:48:53Z")

</div>

I can differentiate a function of one vector, but not multiple vectors using ForwardDiff, Zygote f(x) = 3.0\*x\[1\] + 5.0\*x\[2\]^2.0 fpF(x) = ForwardDiff.gradient(f,x) fpZ(x) = Zygote.forward\_jacobian(f,x)\[2\] # xx = 2.0\*o…

---

## [Get left hand side of SymPy equations](https://discourse.julialang.org/t/get-left-hand-side-of-sympy-equations/59694)

<div class="topic-metadata">

**Author:** [@fms-1988](https://discourse.julialang.org/u/fms-1988)\
**Replies:** 5\
**Last updated:** [April 21, 2021, 7:45pm UTC](https://discourse.julialang.org/t/get-left-hand-side-of-sympy-equations/59694 "2021-04-21T19:45:07Z")

</div>

I have a vector of equations: using SymPy θ,ω,dθ,dω,b,c = symbols("θ,ω,\\\\dot{θ},\\\\dot{ω},b,c") f1 = Eq(dθ,ω) f2 = Eq(dω,-b\*ω - c\* sin(θ)) eqns = \[f1;f2\] out: \\left\[ \\begin{array}{c} \\dot{θ} = ω \\\\ \\dot{ω} = -b\*ω - c\*…

---

## [Preallocating large matrices in all cores is slower than allocating every time](https://discourse.julialang.org/t/preallocating-large-matrices-in-all-cores-is-slower-than-allocating-every-time/59261)

<div class="topic-metadata">

**Author:** [@kaslusimoes](https://discourse.julialang.org/u/kaslusimoes)\
**Replies:** 7\
**Last updated:** [April 21, 2021, 7:28pm UTC](https://discourse.julialang.org/t/preallocating-large-matrices-in-all-cores-is-slower-than-allocating-every-time/59261 "2021-04-21T19:28:55Z")

</div>

Hi everyone, I am trying to improve a piece of code of mine (numerical simulations for a scientific research project) to scale it up. It essentially involves running one computationally and memory heavy function for se…

---

## [ReverseDiff over Zygote to differentiate neural network using GalacticOptim - Dimension mismatch](https://discourse.julialang.org/t/reversediff-over-zygote-to-differentiate-neural-network-using-galacticoptim-dimension-mismatch/59744)

<div class="topic-metadata">

**Author:** [@RynoLaubscher](https://discourse.julialang.org/u/RynoLaubscher)\
**Replies:** 2\
**Last updated:** [April 21, 2021, 7:21pm UTC](https://discourse.julialang.org/t/reversediff-over-zygote-to-differentiate-neural-network-using-galacticoptim-dimension-mismatch/59744 "2021-04-21T19:21:16Z")

</div>

Hi All, I am struggling a bit with using GalacticOptim.AutoReverseDiff to find the gradients over a loss function which internally calculates a gradient using Zygote. Running ForwardDiff over the function works fine but …

---

## [How to use ChainRules to tell Zygote about a more specialized rule?](https://discourse.julialang.org/t/how-to-use-chainrules-to-tell-zygote-about-a-more-specialized-rule/59721)

<div class="topic-metadata">

**Author:** [@bgctw](https://discourse.julialang.org/u/bgctw)\
**Replies:** 2\
**Last updated:** [April 21, 2021, 6:59pm UTC](https://discourse.julialang.org/t/how-to-use-chainrules-to-tell-zygote-about-a-more-specialized-rule/59721 "2021-04-21T18:59:23Z")

</div>

I am trying to optimize an ODE problem specified with ModelingToolkit. The objective function indexes into the ODESolution by a symbol. There is a Zygote adjoint for getindex(::VectorOfArray, i), and VectorOfArray is an …

---

## [Trying to find out how pkg environment works](https://discourse.julialang.org/t/trying-to-find-out-how-pkg-environment-works/59582)

<div class="topic-metadata">

**Author:** [@quazirfan](https://discourse.julialang.org/u/quazirfan)\
**Replies:** 2\
**Last updated:** [April 21, 2021, 7:00pm UTC](https://discourse.julialang.org/t/trying-to-find-out-how-pkg-environment-works/59582 "2021-04-21T19:00:57Z")

</div>

If I see the following line after evaluating an use statement, such as using MLJ - does it mean I am using local git cloned copy? \[ Info: Precompiling MLJ \[add582a8-e3ab-11e8-2d5e-e98b27df1bc7\] (This is one a default e…

---

## [Script package unable to run julia](https://discourse.julialang.org/t/script-package-unable-to-run-julia/59751)

<div class="topic-metadata">

**Author:** [@Ethan\_Gouveia](https://discourse.julialang.org/u/Ethan_Gouveia)\
**Replies:** 0\
**Last updated:** [April 21, 2021, 6:44pm UTC](https://discourse.julialang.org/t/script-package-unable-to-run-julia/59751 "2021-04-21T18:44:23Z")

</div>

When I try to run a .jl file with ctrl+shift+B an error occurs. Julia is in my PATH, and I can launch it from the terminal by typing “julia”, so not sure why I cant execute the file. What can I do to make the Script pack…

---

## [Manually Merge Functions](https://discourse.julialang.org/t/manually-merge-functions/59713)

<div class="topic-metadata">

**Author:** [@andenrx](https://discourse.julialang.org/u/andenrx)\
**Replies:** 5\
**Last updated:** [April 21, 2021, 5:08pm UTC](https://discourse.julialang.org/t/manually-merge-functions/59713 "2021-04-21T17:08:29Z")

</div>

I have seen a lot of discussion related to this and the general consensus seems to be that it would be a mistake to automatically merge functions from different packages. However, is there a way to manually do this? For…

---

## [How to put numbers on top of each bar in a bar chart?](https://discourse.julialang.org/t/how-to-put-numbers-on-top-of-each-bar-in-a-bar-chart/59743)

<div class="topic-metadata">

**Author:** [@zxjroger](https://discourse.julialang.org/u/zxjroger)\
**Replies:** 4\
**Last updated:** [April 21, 2021, 5:07pm UTC](https://discourse.julialang.org/t/how-to-put-numbers-on-top-of-each-bar-in-a-bar-chart/59743 "2021-04-21T17:07:35Z")

</div>

I tried to make a chart like this, but I couldn’t find a way to show the numbers on top of each bar.

---

## [AGP with linear predictors](https://discourse.julialang.org/t/agp-with-linear-predictors/59630)

<div class="topic-metadata">

**Author:** [@jzr](https://discourse.julialang.org/u/jzr)\
**Replies:** 3\
**Last updated:** [April 21, 2021, 4:50pm UTC](https://discourse.julialang.org/t/agp-with-linear-predictors/59630 "2021-04-21T16:50:14Z")

</div>

Continuing my experiments from another thread using the suggestion of @theogf, I have some code using AGP. With a single predictor I can fit: using AugmentedGaussianProcesses const AGP = AugmentedGaussianProcesses using…

---

## [\[ANN\] JET.jl: the next generation of code checker for Julia](https://discourse.julialang.org/t/ann-jet-jl-the-next-generation-of-code-checker-for-julia/58913)

<div class="topic-metadata">

**Author:** [@aviatesk](https://discourse.julialang.org/u/aviatesk)\
**Replies:** 11\
**Last updated:** [April 21, 2021, 2:31pm UTC](https://discourse.julialang.org/t/ann-jet-jl-the-next-generation-of-code-checker-for-julia/58913 "2021-04-21T14:31:34Z")

</div>

Julia’s extreme expressiveness and composability come from its dynamism — at the cost of that, a static type-level analysis of Julia code has been remained as a longstanding problem. JET.jl is a fresh approach to static…

---

## [Print DataFrame as "less"-command style](https://discourse.julialang.org/t/print-dataframe-as-less-command-style/40667)

<div class="topic-metadata">

**Author:** [@carlomontec](https://discourse.julialang.org/u/carlomontec)\
**Replies:** 4\
**Last updated:** [April 21, 2021, 4:01pm UTC](https://discourse.julialang.org/t/print-dataframe-as-less-command-style/40667 "2021-04-21T16:01:07Z")

</div>

Hello, is there a way to print to screen a DataFrame in similar fashion as the “less” command in Linux? So that it displays the data that fits the current terminal size, and with the arrow keys to scroll the columns and…

---

## [3D convolution, de-convolution layers in Flux for training 3D MRI data](https://discourse.julialang.org/t/3d-convolution-de-convolution-layers-in-flux-for-training-3d-mri-data/11917)

<div class="topic-metadata">

**Author:** [@Azamat](https://discourse.julialang.org/u/Azamat)\
**Replies:** 4\
**Last updated:** [April 21, 2021, 3:54pm UTC](https://discourse.julialang.org/t/3d-convolution-de-convolution-layers-in-flux-for-training-3d-mri-data/11917 "2021-04-21T15:54:55Z")

</div>

Are there 3D convolution, de-convolution layers in Flux.jl? Or is there any implementation that can be used with Flux.jl? To elaborate I have 3D greyscale images (MRI scans), i.e. each voxel value is a number. Now is t…

---

## [Solving a constraint lasso](https://discourse.julialang.org/t/solving-a-constraint-lasso/59727)

<div class="topic-metadata">

**Author:** [@lrnv](https://discourse.julialang.org/u/lrnv)\
**Replies:** 2\
**Last updated:** [April 21, 2021, 3:33pm UTC](https://discourse.julialang.org/t/solving-a-constraint-lasso/59727 "2021-04-21T15:33:25Z")

</div>

Hi, Recently i had the problem of solving a constraint lasso, much like the one described in this paper. The paper refers to a julia package, ConstrainedLasso.jl, that is unfornutely not updated since julia 0.6. With so…

---

## [Performance optimisation: Julia vs C++](https://discourse.julialang.org/t/performance-optimisation-julia-vs-c/59689)

<div class="topic-metadata">

**Author:** [@carstenbauer](https://discourse.julialang.org/u/carstenbauer)\
**Replies:** 31\
**Last updated:** [April 21, 2021, 2:55pm UTC](https://discourse.julialang.org/t/performance-optimisation-julia-vs-c/59689 "2021-04-21T14:55:24Z")

</div>

Hi all! This is for the performance tweaking addicts out there :smiley: I had a conversation with a “C++ friend” today in which upon request I tried to showcase to him that Julia can be as performant as C++ (say, withi…

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

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