# Specific Domains

**URL:** https://discourse.julialang.org/c/domain/10.md?page=505

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

**Page:** 506

---

## [SOS1 variables are not supported](https://discourse.julialang.org/t/sos1-variables-are-not-supported/22012)

<div class="topic-metadata">

**Author:** [@SingingKim](https://discourse.julialang.org/u/SingingKim)\
**Replies:** 5\
**Last updated:** [March 21, 2019, 9:40pm UTC](https://discourse.julialang.org/t/sos1-variables-are-not-supported/22012 "2019-03-21T21:40:06Z")

</div>

I’m trying to build a SOS1 constraint using JuMP MOI (with Gurobi, CPLEX, Mosek). m = Model(with\_optimizer(Mosek.Optimizer)) @variable(m, x\[1:3\]) @constraint(m, x in MOI.SOS1(\[1, 2, 3\])) But it gives me an error saying…

---

## [Plot Neural Network Layout](https://discourse.julialang.org/t/plot-neural-network-layout/22007)

<div class="topic-metadata">

**Author:** [@Zach\_Christensen](https://discourse.julialang.org/u/Zach_Christensen)\
**Replies:** 13\
**Last updated:** [March 21, 2019, 9:24pm UTC](https://discourse.julialang.org/t/plot-neural-network-layout/22007 "2019-03-21T21:24:48Z")

</div>

I need to make a plot/graphic of my neural network. I know there’s stuff out there for plotting graphs but I can’t seem to find anything that has the typical structure with the vertices lined up and connected by edges to…

---

## [Interactive plot with Vegalite](https://discourse.julialang.org/t/interactive-plot-with-vegalite/22129)

<div class="topic-metadata">

**Author:** [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Replies:** 8\
**Last updated:** [March 21, 2019, 5:15pm UTC](https://discourse.julialang.org/t/interactive-plot-with-vegalite/22129 "2019-03-21T17:15:07Z")

</div>

Is anyone familiar with using Vegalite from the REPL to produce interactive plots (to zoom in/out at a minimum)? I understand this works in Jupyter notebooks, but I want to avoid notebooks and work directly in the termi…

---

## [How to distribute the definitions of preexisting functions to workers?](https://discourse.julialang.org/t/how-to-distribute-the-definitions-of-preexisting-functions-to-workers/22072)

<div class="topic-metadata">

**Author:** [@Babber](https://discourse.julialang.org/u/Babber)\
**Replies:** 12\
**Last updated:** [March 21, 2019, 3:43pm UTC](https://discourse.julialang.org/t/how-to-distribute-the-definitions-of-preexisting-functions-to-workers/22072 "2019-03-21T15:43:21Z")

</div>

I think, more or less, I defined my problem in the title. After extensive search, I couldn’t find a solution to it, maybe someone can help me here. So in a nutshell: I have some functions already defined well before I wo…

---

## [Having problems with creating animations with Plots.jl - GRBackend - Juno](https://discourse.julialang.org/t/having-problems-with-creating-animations-with-plots-jl-grbackend-juno/21876)

<div class="topic-metadata">

**Author:** [@tiago](https://discourse.julialang.org/u/tiago)\
**Replies:** 6\
**Last updated:** [March 21, 2019, 3:41pm UTC](https://discourse.julialang.org/t/having-problems-with-creating-animations-with-plots-jl-grbackend-juno/21876 "2019-03-21T15:41:19Z")

</div>

Hello! I am trying to create a simple animation in 1D, using the Plots.jl with GR as a backend. Basically, I have a matrix where the rows are the solution u at a time instant. What I was trying to do was to plot the ev…

---

## [Generate nonlinear expressions in an explicit loop](https://discourse.julialang.org/t/generate-nonlinear-expressions-in-an-explicit-loop/20447)

<div class="topic-metadata">

**Author:** [@ncostilla](https://discourse.julialang.org/u/ncostilla)\
**Replies:** 1\
**Last updated:** [March 21, 2019, 3:09pm UTC](https://discourse.julialang.org/t/generate-nonlinear-expressions-in-an-explicit-loop/20447 "2019-03-21T15:09:06Z")

</div>

I want to generate nonlinear expressions in an explicit loop. I know You can iterate over constraints and store references like in the next example: @variable(m, x\[1:5\] \>= 0) @constraintref myCons\[1:5\] for i = 1:5 myC…

---

## [User-defined distribution function example](https://discourse.julialang.org/t/user-defined-distribution-function-example/22035)

<div class="topic-metadata">

**Author:** [@roi.holtzman](https://discourse.julialang.org/u/roi.holtzman)\
**Replies:** 14\
**Last updated:** [March 21, 2019, 12:28pm UTC](https://discourse.julialang.org/t/user-defined-distribution-function-example/22035 "2019-03-21T12:28:30Z")

</div>

I am new to Julia, and I want to define my own distribution function. I found this post and followed the documentation, but I did not understand where do I put in the actual function (namely f(x)) of the distribution. Ca…

---

## [Help with function sum{}](https://discourse.julialang.org/t/help-with-function-sum/22128)

<div class="topic-metadata">

**Author:** [@danielcas](https://discourse.julialang.org/u/danielcas)\
**Replies:** 3\
**Last updated:** [March 21, 2019, 2:05am UTC](https://discourse.julialang.org/t/help-with-function-sum/22128 "2019-03-21T02:05:30Z")

</div>

H, on my file there’s a constraint written like this @NLconstraint(m,-sum{log(x\[i\])/gamma\[i\], i=1:n}\<=mm), when I run the program I get an error saying that this type of syntax is no longer supported. so…¿What is the new…

---

## [Vector affine function with SOC not supported in JuMP (.18 -\> .19 breaking change?)](https://discourse.julialang.org/t/vector-affine-function-with-soc-not-supported-in-jump-18-19-breaking-change/22076)

<div class="topic-metadata">

**Author:** [@guille](https://discourse.julialang.org/u/guille)\
**Replies:** 6\
**Last updated:** [March 20, 2019, 4:47pm UTC](https://discourse.julialang.org/t/vector-affine-function-with-soc-not-supported-in-jump-18-19-breaking-change/22076 "2019-03-20T16:47:34Z")

</div>

Hey all! Quick question (it is quite likely this question has a simple solution), but I’m working on doing a quick overhaul of some code for a paper. The original code was written on JuMP .17/.18, but with some of the b…

---

## [CUDA fft against CPU fft](https://discourse.julialang.org/t/cuda-fft-against-cpu-fft/22029)

<div class="topic-metadata">

**Author:** [@Ferran\_Mazzanti](https://discourse.julialang.org/u/Ferran_Mazzanti)\
**Replies:** 4\
**Last updated:** [March 19, 2019, 6:50pm UTC](https://discourse.julialang.org/t/cuda-fft-against-cpu-fft/22029 "2019-03-19T18:50:38Z")

</div>

Dear all, in my attempts to play with CUDA in Julia, I’ve come accross something I can’t really understand -hopefully because I’m doing something wrong. The fact is that in my calculations I need to perform Fourier tran…

---

## [UnicodePlots multiple plots?](https://discourse.julialang.org/t/unicodeplots-multiple-plots/22063)

<div class="topic-metadata">

**Author:** [@natemcintosh](https://discourse.julialang.org/u/natemcintosh)\
**Replies:** 1\
**Last updated:** [March 19, 2019, 5:17pm UTC](https://discourse.julialang.org/t/unicodeplots-multiple-plots/22063 "2019-03-19T17:17:20Z")

</div>

I been having TONS of fun with UnicodePlots recently. However, when I want to make two plots, one after the other, in a script, only the last is displayed in my REPL. For example, with this code in a .jl file, I call i…

---

## [Error while using DifferentialEquations.jl stiff methods](https://discourse.julialang.org/t/error-while-using-differentialequations-jl-stiff-methods/22004)

<div class="topic-metadata">

**Author:** [@Andre\_Mello](https://discourse.julialang.org/u/Andre_Mello)\
**Replies:** 3\
**Last updated:** [March 19, 2019, 4:42pm UTC](https://discourse.julialang.org/t/error-while-using-differentialequations-jl-stiff-methods/22004 "2019-03-19T16:42:41Z")

</div>

Hi all, The DifferentialEquations’ suggested integration methods when trying to solve this stiff problem all yield the same error. The native Julia ones, that is. Sundial’s CVODE\_BDF as well as lsoda are able to solve t…

---

## [If condition in constraint set](https://discourse.julialang.org/t/if-condition-in-constraint-set/22057)

<div class="topic-metadata">

**Author:** [@ilias](https://discourse.julialang.org/u/ilias)\
**Replies:** 1\
**Last updated:** [March 19, 2019, 3:37pm UTC](https://discourse.julialang.org/t/if-condition-in-constraint-set/22057 "2019-03-19T15:37:33Z")

</div>

Is there a way to rewrite the following constraint set in one row? for i in set\_i for ii in set\_i if parameter\[ii\] \>= parameter\[i\] @constraint( model, x\[i\] - y\[ii\] \<= 0 ); end end end…

---

## [help converting JuMPArray to regular array](https://discourse.julialang.org/t/help-converting-jumparray-to-regular-array/21924)

<div class="topic-metadata">

**Author:** [@levip](https://discourse.julialang.org/u/levip)\
**Replies:** 2\
**Last updated:** [March 19, 2019, 2:56pm UTC](https://discourse.julialang.org/t/help-converting-jumparray-to-regular-array/21924 "2019-03-19T14:56:23Z")

</div>

I’m trying to inspect the dual values of one of my constraints, but I cannot figure out how to convert the returned variable to a regular Array (so that I can ultimately save it to a CSV). I get a 3-dimensional JuMPArray…

---

## [Recommended way of solving multiple similar problems with JuMP](https://discourse.julialang.org/t/recommended-way-of-solving-multiple-similar-problems-with-jump/22055)

<div class="topic-metadata">

**Author:** [@Sebastian\_Rollen](https://discourse.julialang.org/u/Sebastian_Rollen)\
**Replies:** 1\
**Last updated:** [March 19, 2019, 2:20pm UTC](https://discourse.julialang.org/t/recommended-way-of-solving-multiple-similar-problems-with-jump/22055 "2019-03-19T14:20:32Z")

</div>

Hi, I have an application where I have to solve a quadratic problem multiple times, with the only thing changing between problems being the RHS of a constraint. Currently I do this by setting up the problem with the RHS…

---

## [FluxML Basic Custom Layer with Custom Loss Function](https://discourse.julialang.org/t/fluxml-basic-custom-layer-with-custom-loss-function/22036)

<div class="topic-metadata">

**Author:** [@LudiWin](https://discourse.julialang.org/u/LudiWin)\
**Replies:** 3\
**Last updated:** [March 19, 2019, 2:01pm UTC](https://discourse.julialang.org/t/fluxml-basic-custom-layer-with-custom-loss-function/22036 "2019-03-19T14:01:45Z")

</div>

Hi, I want to write a custom layer and a custom loss function and thought I’d start out with the basic linear regression problem from the tutorial of Flux and do the SGD from scratch for a custom layer in a Chain. For …

---

## [Tutorial on GPU programming on julia](https://discourse.julialang.org/t/tutorial-on-gpu-programming-on-julia/21957)

<div class="topic-metadata">

**Author:** [@Ferran\_Mazzanti](https://discourse.julialang.org/u/Ferran_Mazzanti)\
**Replies:** 5\
**Last updated:** [March 19, 2019, 10:01am UTC](https://discourse.julialang.org/t/tutorial-on-gpu-programming-on-julia/21957 "2019-03-19T10:01:34Z")

</div>

Hi, I’m starting to appreciate CUDA programming in Julia, but find hard to learn how to do that properly since I can not find any tutorial or book on that. I’ve read the documentation about CuArrays.jl and CUDAnative.jl…

---

## [Any synthetic control libraries in julia?](https://discourse.julialang.org/t/any-synthetic-control-libraries-in-julia/21272)

<div class="topic-metadata">

**Author:** [@pdeffebach](https://discourse.julialang.org/u/pdeffebach)\
**Replies:** 4\
**Last updated:** [March 18, 2019, 10:57pm UTC](https://discourse.julialang.org/t/any-synthetic-control-libraries-in-julia/21272 "2019-03-18T22:57:03Z")

</div>

Is anyone doing anything related to synthetic controls in julia? Like the Synth package for R and Stata? It would be great to see some of the implementations and work done in that space.

---

## [Moving camera then saving picture in Makie](https://discourse.julialang.org/t/moving-camera-then-saving-picture-in-makie/21938)

<div class="topic-metadata">

**Author:** [@fa-bien](https://discourse.julialang.org/u/fa-bien)\
**Replies:** 2\
**Last updated:** [March 16, 2019, 6:24pm UTC](https://discourse.julialang.org/t/moving-camera-then-saving-picture-in-makie/21938 "2019-03-16T18:24:49Z")

</div>

I visualise 3d scenes with Makie. Moving the camera (either with rotate\_cam! or with update\_cam!) only seems to works from the REPL or when saving an animation: as soon as the scene is evaluated, it returns to the origin…

---

## [Optimize slow constraint generation](https://discourse.julialang.org/t/optimize-slow-constraint-generation/21996)

<div class="topic-metadata">

**Author:** [@Di11on](https://discourse.julialang.org/u/Di11on)\
**Replies:** 1\
**Last updated:** [March 18, 2019, 12:55pm UTC](https://discourse.julialang.org/t/optimize-slow-constraint-generation/21996 "2019-03-18T12:55:25Z")

</div>

This is somewhat related to my other post (Deleting containerized constraints) but here, I want to see if there is a way to formulate my constraint differently. Following advice in this thread, I put all my variable and…

---

## [Basics steps to build an ANN?](https://discourse.julialang.org/t/basics-steps-to-build-an-ann/21366)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 24\
**Last updated:** [March 18, 2019, 10:04am UTC](https://discourse.julialang.org/t/basics-steps-to-build-an-ann/21366 "2019-03-18T10:04:38Z")

</div>

Is there a simple example on how to build a first ANN? I have a basic understanding of ANNs. I’m not looking for impressive examples. So, I’m not interested in hand writing recognition, image recognition, etc. Instead: …

---

## [RigidBodyDynamics, Munthe-Kaas integrator, step(integrator, t, Δt)](https://discourse.julialang.org/t/rigidbodydynamics-munthe-kaas-integrator-step-integrator-t-t/21906)

<div class="topic-metadata">

**Author:** [@RogerP](https://discourse.julialang.org/u/RogerP)\
**Replies:** 4\
**Last updated:** [March 18, 2019, 8:49am UTC](https://discourse.julialang.org/t/rigidbodydynamics-munthe-kaas-integrator-step-integrator-t-t/21906 "2019-03-18T08:49:00Z")

</div>

I want to set up a stepwise Munthe-Kass integrator for use in a real-time control system. I do: t = 0.0; Δt = 1e-4 ringBuff2 = RigidBodyDynamics.OdeIntegrators.RingBufferStorage{Float64}(state, 10000) butcherTableau = R…

---

## [calculate p(D|M) for Turing tutorial model?](https://discourse.julialang.org/t/calculate-p-d-m-for-turing-tutorial-model/21985)

<div class="topic-metadata">

**Author:** [@subunit](https://discourse.julialang.org/u/subunit)\
**Replies:** 0\
**Last updated:** [March 18, 2019, 2:31am UTC](https://discourse.julialang.org/t/calculate-p-d-m-for-turing-tutorial-model/21985 "2019-03-18T02:31:13Z")

</div>

Hi folks, I am new to Julia, Turing, and Bayes, so I’m a bit out of my depth here. I think I have a rough handle on what Turing is doing in the third tutorial (http://turing.ml/tutorials/3-bayesnn/), which is close to m…

---

## [How to obtain the number of rows in each group using DataFramesMeta?](https://discourse.julialang.org/t/how-to-obtain-the-number-of-rows-in-each-group-using-dataframesmeta/21955)

<div class="topic-metadata">

**Author:** [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Replies:** 2\
**Last updated:** [March 17, 2019, 6:50am UTC](https://discourse.julialang.org/t/how-to-obtain-the-number-of-rows-in-each-group-using-dataframesmeta/21955 "2019-03-17T06:50:16Z")

</div>

using DataFrames, DataFramesMeta a = DataFrame(a = rand(1:10, 100)) @\> begin a @by(:a, count = length(:a)) end is there a more convenient function like R’s dplyr::n() which returns the number of rows? Or even, R…

---

## [Ways to order a \`DataFrame\` by mixed order?](https://discourse.julialang.org/t/ways-to-order-a-dataframe-by-mixed-order/21952)

<div class="topic-metadata">

**Author:** [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Replies:** 2\
**Last updated:** [March 17, 2019, 4:26am UTC](https://discourse.julialang.org/t/ways-to-order-a-dataframe-by-mixed-order/21952 "2019-03-17T04:26:52Z")

</div>

I wanted to order a DataFrame by certain mixed order, e.g. i want to order a DataFrame by a\_str in descending order followed by b\_str in ascending order Setting up data using DataFrames, Query a\_str = string.(rand(UI…

---

## [Makie and colours](https://discourse.julialang.org/t/makie-and-colours/21937)

<div class="topic-metadata">

**Author:** [@fa-bien](https://discourse.julialang.org/u/fa-bien)\
**Replies:** 6\
**Last updated:** [March 16, 2019, 1:46pm UTC](https://discourse.julialang.org/t/makie-and-colours/21937 "2019-03-16T13:46:47Z")

</div>

I am visualising polyhedra with Makie. However I find that colours are all way too dark, see MWE that displays a cube that should be the brightest shade of yellow, but is not very bright. Moreover, I find that it gets br…

---

## [Key error in JuMP on domain tuples](https://discourse.julialang.org/t/key-error-in-jump-on-domain-tuples/21872)

<div class="topic-metadata">

**Author:** [@Di11on](https://discourse.julialang.org/u/Di11on)\
**Replies:** 6\
**Last updated:** [March 15, 2019, 2:18pm UTC](https://discourse.julialang.org/t/key-error-in-jump-on-domain-tuples/21872 "2019-03-15T14:18:02Z")

</div>

Hi folks, I’m having a strange problem with JuMP that I hope someone can identify… The first formulation below results in a key error but the second doesn’t but both should, in theory involve evaluations on the same se…

---

## [JuMP/CPLEX: adding objective function expression in loop is very resource-consuming](https://discourse.julialang.org/t/jump-cplex-adding-objective-function-expression-in-loop-is-very-resource-consuming/21859)

<div class="topic-metadata">

**Author:** [@mike\_k](https://discourse.julialang.org/u/mike_k)\
**Replies:** 3\
**Last updated:** [March 15, 2019, 11:40am UTC](https://discourse.julialang.org/t/jump-cplex-adding-objective-function-expression-in-loop-is-very-resource-consuming/21859 "2019-03-15T11:40:49Z")

</div>

Dear community, I use JuMP 0.18.5, CPLEX 0.4.3, Julia 1.1, and observe a strange behaviour when adding an objective function expression with a loop. Here is a stupid minimal example: using TimerOutputs using JuMP using…

---

## [Plotting a transparent planes/boxes with Makie](https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875)

<div class="topic-metadata">

**Author:** [@cserteGT3](https://discourse.julialang.org/u/cserteGT3)\
**Replies:** 2\
**Last updated:** [March 14, 2019, 4:37pm UTC](https://discourse.julialang.org/t/plotting-a-transparent-planes-boxes-with-makie/21875 "2019-03-14T16:37:59Z")

</div>

I’m looking for a way to plot simple planes with Makie. The only solution I found so far is this: using Makie p1 = Point3(0.0, 0.0, 0.0) p2 = Point3(0.0, 1.0, 0.0) p3 = Point3(0.0, 1.0, 1.0) p4 = Point3(0.0, 0.0, 1.0)…

---

## [FFTW Plans for multiple threads](https://discourse.julialang.org/t/fftw-plans-for-multiple-threads/21861)

<div class="topic-metadata">

**Author:** [@M\_Kaj](https://discourse.julialang.org/u/M_Kaj)\
**Replies:** 1\
**Last updated:** [March 14, 2019, 1:13pm UTC](https://discourse.julialang.org/t/fftw-plans-for-multiple-threads/21861 "2019-03-14T13:13:49Z")

</div>

I need to compute many convolutions of arrays with the same length and I want to use multiple threads for that. So i want each thread to compute a convolution with fft’s. As I understand it right now the creating of the…

[Previous page](https://discourse.julialang.org/c/domain/10.md?page=504)

[Next page](https://discourse.julialang.org/c/domain/10.md?page=506)
