# Machine Learning

**URL:** https://discourse.julialang.org/c/domain/ml/24.md?page=29

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

**Page:** 30

---

## [Error from MLJ Iris example, no method matching?](https://discourse.julialang.org/t/error-from-mlj-iris-example-no-method-matching/71313)

<div class="topic-metadata">

**Author:** [@jamaas](https://discourse.julialang.org/u/jamaas)\
**Replies:** 4\
**Last updated:** [November 11, 2021, 10:02am UTC](https://discourse.julialang.org/t/error-from-mlj-iris-example-no-method-matching/71313 "2021-11-11T10:02:14Z")

</div>

I’m at the install/testing phase of Julia and attempting to run the Iris example of training a model using the Julia MLJ. I think I have it installed properly but am getting this error. What have I done incorrectly? Thx.…

---

## [Does DecisionTreeClassifier support missing data in the predictors?](https://discourse.julialang.org/t/does-decisiontreeclassifier-support-missing-data-in-the-predictors/71013)

<div class="topic-metadata">

**Author:** [@Rahul](https://discourse.julialang.org/u/Rahul)\
**Replies:** 3\
**Last updated:** [November 8, 2021, 8:26pm UTC](https://discourse.julialang.org/t/does-decisiontreeclassifier-support-missing-data-in-the-predictors/71013 "2021-11-08T20:26:43Z")

</div>

I cannot pass missing data to train DecisionTreeClassifier in MLJ. Is this not supported? Although the machine function gave me a warning, I tried to run fit! and it threw and error that the scitype of X isn’t supported. …

---

## [Allocation of Memory while evaluate a model](https://discourse.julialang.org/t/allocation-of-memory-while-evaluate-a-model/71064)

<div class="topic-metadata">

**Author:** [@HenrZu](https://discourse.julialang.org/u/HenrZu)\
**Replies:** 7\
**Last updated:** [November 8, 2021, 11:02am UTC](https://discourse.julialang.org/t/allocation-of-memory-while-evaluate-a-model/71064 "2021-11-08T11:02:05Z")

</div>

While working on the performance of a model used in a numerical simulation, I noticed that memory is allocated every time a model is evaluated. Since I call the model several times within the simulation, there is a sign…

---

## [Problem standardizing data with MLJ + NaN predictions in Flux](https://discourse.julialang.org/t/problem-standardizing-data-with-mlj-nan-predictions-in-flux/70923)

<div class="topic-metadata">

**Author:** [@lfenzo](https://discourse.julialang.org/u/lfenzo)\
**Replies:** 3\
**Last updated:** [November 8, 2021, 2:58am UTC](https://discourse.julialang.org/t/problem-standardizing-data-with-mlj-nan-predictions-in-flux/70923 "2021-11-08T02:58:36Z")

</div>

I’m new to Julia and Flux so I suspect this may be something dumb that I may be missing… I was trying to do some pre-processing in order to train a NN using Flux and ended up stuck with two problems: The predictions …

---

## [Workaround for Zygote.jl issue #317 not working?](https://discourse.julialang.org/t/workaround-for-zygote-jl-issue-317-not-working/59028)

<div class="topic-metadata">

**Author:** [@Andreas\_Poulsen](https://discourse.julialang.org/u/Andreas_Poulsen)\
**Replies:** 1\
**Last updated:** [November 7, 2021, 10:04pm UTC](https://discourse.julialang.org/t/workaround-for-zygote-jl-issue-317-not-working/59028 "2021-11-07T22:04:25Z")

</div>

Hi, I’ve run into the problem described in Zygote bugs #857, #317 and maybe #495. In essence, when broadcasting over a piecewise function where some branches may not have an adjoint, Zygote will try to back-propagate no…

---

## [RNN weights definition in Flux](https://discourse.julialang.org/t/rnn-weights-definition-in-flux/59623)

<div class="topic-metadata">

**Author:** [@Sunny](https://discourse.julialang.org/u/Sunny)\
**Replies:** 1\
**Last updated:** [November 7, 2021, 7:21pm UTC](https://discourse.julialang.org/t/rnn-weights-definition-in-flux/59623 "2021-11-07T19:21:24Z")

</div>

In the Flux source files there is a line. @functor RNNCell How does the functor understand that state0 and \\sigma (which should be fixed) in RNNCell definition aren’t weights?

---

## [Broadcasting over a Flux.DataLoader](https://discourse.julialang.org/t/broadcasting-over-a-flux-dataloader/70414)

<div class="topic-metadata">

**Author:** [@austinbean](https://discourse.julialang.org/u/austinbean)\
**Replies:** 11\
**Last updated:** [November 4, 2021, 6:59pm UTC](https://discourse.julialang.org/t/broadcasting-over-a-flux-dataloader/70414 "2021-11-04T18:59:00Z")

</div>

Apologies for this question since I’ve had a lot of trouble producing a MWE (which I don’t have). I’m working on an RNN using text data (each observation is a sentence - each word in each sentence is mapped to a word em…

---

## [Variable sequence length RNN in Flux](https://discourse.julialang.org/t/variable-sequence-length-rnn-in-flux/70715)

<div class="topic-metadata">

**Author:** [@paalon](https://discourse.julialang.org/u/paalon)\
**Replies:** 2\
**Last updated:** [November 3, 2021, 9:57am UTC](https://discourse.julialang.org/t/variable-sequence-length-rnn-in-flux/70715 "2021-11-03T09:57:18Z")

</div>

How to implement RNN for variable sequence length data with minibatching in Flux? According to Flux doc, In Flux, those 3 dimensions are provided through a vector of seq length containing a matrix (features, samples) …

---

## [Normalize the solution during the integration by differentialequations.jl](https://discourse.julialang.org/t/normalize-the-solution-during-the-integration-by-differentialequations-jl/70845)

<div class="topic-metadata">

**Author:** [@TravellingLight6](https://discourse.julialang.org/u/TravellingLight6)\
**Replies:** 1\
**Last updated:** [November 3, 2021, 5:38am UTC](https://discourse.julialang.org/t/normalize-the-solution-during-the-integration-by-differentialequations-jl/70845 "2021-11-03T05:38:25Z")

</div>

I usually come to solve outwards ode like schrodinger equation under columb potential and I recently realize that the initial condition and time span affect the stability of the solution as posted as following: using Di…

---

## [Why does my neural net not learn](https://discourse.julialang.org/t/why-does-my-neural-net-not-learn/70603)

<div class="topic-metadata">

**Author:** [@Marius\_123](https://discourse.julialang.org/u/Marius_123)\
**Replies:** 3\
**Last updated:** [November 2, 2021, 10:36am UTC](https://discourse.julialang.org/t/why-does-my-neural-net-not-learn/70603 "2021-11-02T10:36:23Z")

</div>

using Flux, Statistics using Flux.Data: DataLoader using Flux: @epochs using Flux.Losses: huber\_loss, tversky\_loss, mse using Base: @kwdef using CUDA function Data\_importer() train\_x = \[0.0 0.0 0.0 0.0; 9.178257595538…

---

## [Current status of nested AD](https://discourse.julialang.org/t/current-status-of-nested-ad/70753)

<div class="topic-metadata">

**Author:** [@jlmaccal](https://discourse.julialang.org/u/jlmaccal)\
**Replies:** 0\
**Last updated:** [November 1, 2021, 6:56pm UTC](https://discourse.julialang.org/t/current-status-of-nested-ad/70753 "2021-11-01T18:56:04Z")

</div>

Could anyone comment on the current status of nested AD? What works? What doesn’t? And what does the future look like? In my application, I am trying to learn a conservative vector field—that is, a vector field that is …

---

## [Any collaborative filtering by rank-constrained matrix factoristion in Julia?](https://discourse.julialang.org/t/any-collaborative-filtering-by-rank-constrained-matrix-factoristion-in-julia/70723)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 0\
**Last updated:** [November 1, 2021, 8:45am UTC](https://discourse.julialang.org/t/any-collaborative-filtering-by-rank-constrained-matrix-factoristion-in-julia/70723 "2021-11-01T08:45:22Z")

</div>

Hello, which is the state of the art package for collaborative filtering/missing imputation in julia using rank-constrained matrix factorisation and regularisation ? For example for constrained rank 1, the missing point…

---

## [NeualPDE Model Save/Load](https://discourse.julialang.org/t/neualpde-model-save-load/70551)

<div class="topic-metadata">

**Author:** [@Dr\_M\_Umut\_DEMiREZEN](https://discourse.julialang.org/u/Dr_M_Umut_DEMiREZEN)\
**Replies:** 4\
**Last updated:** [October 31, 2021, 12:06pm UTC](https://discourse.julialang.org/t/neualpde-model-save-load/70551 "2021-10-31T12:06:09Z")

</div>

Hi, After training with NeuralPDE framework, how can we save the trained model for further operations? in Flux framework, @save and @load functionas are available and we can save/load the model as a BSON file. But in s…

---

## [How to manually make prediction after training using LIBSVM](https://discourse.julialang.org/t/how-to-manually-make-prediction-after-training-using-libsvm/70669)

<div class="topic-metadata">

**Author:** [@Jaidy](https://discourse.julialang.org/u/Jaidy)\
**Replies:** 0\
**Last updated:** [October 30, 2021, 7:28pm UTC](https://discourse.julialang.org/t/how-to-manually-make-prediction-after-training-using-libsvm/70669 "2021-10-30T19:28:16Z")

</div>

Hi all, I have a dataset X\_train, y\_train that I feed to LIBSVM and get a model using the following code: model = svmtrain(X\_train’, y\_train, kernel = LIBSVM.Kernel.Linear) My question is how to make predictions manua…

---

## [Machine / Deep Learning with Gene Transcription levels](https://discourse.julialang.org/t/machine-deep-learning-with-gene-transcription-levels/70664)

<div class="topic-metadata">

**Author:** [@jamaas](https://discourse.julialang.org/u/jamaas)\
**Replies:** 0\
**Last updated:** [October 30, 2021, 3:16pm UTC](https://discourse.julialang.org/t/machine-deep-learning-with-gene-transcription-levels/70664 "2021-10-30T15:16:32Z")

</div>

I’m new to Julia, but have used R for many years. I’m embarking on attempting some machine learning, or perhaps deep learning that involves predicting gene transcrition levels from transcription factor binding sites. I…

---

## [DiffEqFlux NaN Bug with Neural ODE: "BoundsError: attempt to access 1-element Vector{Float64} at index \[2\]"](https://discourse.julialang.org/t/diffeqflux-nan-bug-with-neural-ode-boundserror-attempt-to-access-1-element-vector-float64-at-index-2/70596)

<div class="topic-metadata">

**Author:** [@mhr](https://discourse.julialang.org/u/mhr)\
**Replies:** 3\
**Last updated:** [October 30, 2021, 1:58pm UTC](https://discourse.julialang.org/t/diffeqflux-nan-bug-with-neural-ode-boundserror-attempt-to-access-1-element-vector-float64-at-index-2/70596 "2021-10-30T13:58:53Z")

</div>

I’m adapting some code from the following blog post: Differentiable Programming and Neural ODEs for Accelerating Model Based Reinforcement Learning and Optimal Control | by Paul Shen | The Startup | Medium. There’s an o…

---

## [1D GAN with Flux](https://discourse.julialang.org/t/1d-gan-with-flux/54179)

<div class="topic-metadata">

**Author:** [@davibarreira](https://discourse.julialang.org/u/davibarreira)\
**Replies:** 9\
**Last updated:** [October 29, 2021, 2:07pm UTC](https://discourse.julialang.org/t/1d-gan-with-flux/54179 "2021-10-29T14:07:27Z")

</div>

Hey everyone. So I’ve been trying to use Flux for Generative Adversarial Networks (GAN). And unfortunately, it’s not working properly. At the moment, I’m trying to replicate a 1D GAN example (this one here 1D GAN with Ke…

---

## [Getting NaNs in the hello world example of Flux](https://discourse.julialang.org/t/getting-nans-in-the-hello-world-example-of-flux/70573)

<div class="topic-metadata">

**Author:** [@NightMachinary](https://discourse.julialang.org/u/NightMachinary)\
**Replies:** 2\
**Last updated:** [October 28, 2021, 9:07pm UTC](https://discourse.julialang.org/t/getting-nans-in-the-hello-world-example-of-flux/70573 "2021-10-28T21:07:19Z")

</div>

I am just starting with Flux.jl, and well, I tried their Hello World example. However, by slightly changing the input parameters used to generate the training data, the code completely fails and produces NaNs. Here is th…

---

## [Object Detection with YOLOv3 and PlotlyJS](https://discourse.julialang.org/t/object-detection-with-yolov3-and-plotlyjs/70540)

<div class="topic-metadata">

**Author:** [@cepel](https://discourse.julialang.org/u/cepel)\
**Replies:** 0\
**Last updated:** [October 28, 2021, 9:42am UTC](https://discourse.julialang.org/t/object-detection-with-yolov3-and-plotlyjs/70540 "2021-10-28T09:42:21Z")

</div>

Hey everyone! I have developed a Dash Julia application for object detection (with ObjectDetector.jl, using Flux backend). You can enter an image URL, adjust detection and overlap thresholds, and plot the image with bou…

---

## [Flux.train error: no method matching back!(::Float64)](https://discourse.julialang.org/t/flux-train-error-no-method-matching-back-float64/31956)

<div class="topic-metadata">

**Author:** [@janak](https://discourse.julialang.org/u/janak)\
**Replies:** 4\
**Last updated:** [October 27, 2021, 7:41pm UTC](https://discourse.julialang.org/t/flux-train-error-no-method-matching-back-float64/31956 "2021-10-27T19:41:14Z")

</div>

I am working with Julia 1.2.0 on Jupyter lab on Windows 10 machine. I am using the following package versions: DiffEqFlux : v0.8.1 DifferentialEquations: v6.8.0 Flux: v0.9.0 I am trying to train a neural network usi…

---

## [Am I using LSTMs wrong?](https://discourse.julialang.org/t/am-i-using-lstms-wrong/70339)

<div class="topic-metadata">

**Author:** [@Michaela\_Maskova](https://discourse.julialang.org/u/Michaela_Maskova)\
**Replies:** 2\
**Last updated:** [October 25, 2021, 4:45pm UTC](https://discourse.julialang.org/t/am-i-using-lstms-wrong/70339 "2021-10-25T16:45:58Z")

</div>

Hi, everyone. I have a question about the usage of LSTM and other RNN cells with Flux for prediction of data sequences. I’m playing around with Kaggle competition data (Google Brain - Ventilator Pressure Prediction | Ka…

---

## [Gradients of FFT](https://discourse.julialang.org/t/gradients-of-fft/70223)

<div class="topic-metadata">

**Author:** [@maedoc](https://discourse.julialang.org/u/maedoc)\
**Replies:** 5\
**Last updated:** [October 23, 2021, 12:52pm UTC](https://discourse.julialang.org/t/gradients-of-fft/70223 "2021-10-23T12:52:30Z")

</div>

I tried to expand the DiffEqFlux page’s model to a simple one involving an FFT, but I can’t seem to get it working with any of the sensalg options. Here’s what I’ve got, using FFTW using DiffEqSensitivity, OrdinaryDiff…

---

## [Automatic Differentiation (AD) in Python compared to Julia and AD Basics](https://discourse.julialang.org/t/automatic-differentiation-ad-in-python-compared-to-julia-and-ad-basics/56031)

<div class="topic-metadata">

**Author:** [@kimlaberinto](https://discourse.julialang.org/u/kimlaberinto)\
**Replies:** 6\
**Last updated:** [October 22, 2021, 5:36pm UTC](https://discourse.julialang.org/t/automatic-differentiation-ad-in-python-compared-to-julia-and-ad-basics/56031 "2021-10-22T17:36:26Z")

</div>

Hello everyone! The quotes below is a reconstruction of a wonderful conversation I had with Lyndon White (@oxinabox) on the Julia Slack on February 24, 2021 (Thank you to Lyndon as well to let me quote and repost this on…

---

## [Minibatches of graphs in GeometricFlux.jl](https://discourse.julialang.org/t/minibatches-of-graphs-in-geometricflux-jl/70170)

<div class="topic-metadata">

**Author:** [@bad\_at\_math](https://discourse.julialang.org/u/bad_at_math)\
**Replies:** 2\
**Last updated:** [October 22, 2021, 1:04pm UTC](https://discourse.julialang.org/t/minibatches-of-graphs-in-geometricflux-jl/70170 "2021-10-22T13:04:55Z")

</div>

In the supervised graph problem, you train a neural network that maps entire graph instances to target values. The GeometricFlux.jl package has great functionality for training graph neural networks; however, all of the …

---

## [Using callback during adjoint method for NeuralODE](https://discourse.julialang.org/t/using-callback-during-adjoint-method-for-neuralode/70076)

<div class="topic-metadata">

**Author:** [@xk\_y](https://discourse.julialang.org/u/xk_y)\
**Replies:** 4\
**Last updated:** [October 20, 2021, 6:16pm UTC](https://discourse.julialang.org/t/using-callback-during-adjoint-method-for-neuralode/70076 "2021-10-20T18:16:05Z")

</div>

I am training a neural ode with a callback function to add a certain value at every integration timestep. The forward pass works but an error occur during backpropagation. I was wondering if the adjoint method supports a…

---

## [Object detection and Classification using PointCloud data in Julia?](https://discourse.julialang.org/t/object-detection-and-classification-using-pointcloud-data-in-julia/70097)

<div class="topic-metadata">

**Author:** [@DoktorMike](https://discourse.julialang.org/u/DoktorMike)\
**Replies:** 0\
**Last updated:** [October 20, 2021, 1:57pm UTC](https://discourse.julialang.org/t/object-detection-and-classification-using-pointcloud-data-in-julia/70097 "2021-10-20T13:57:10Z")

</div>

I recently came across an interesting problem where I need to do object detection and classification in a 3D PointCloud. I found some implementations for a few networks in PyTorch but didn’t find any in Julia. Flux3D doe…

---

## [My gradients IdDIct keys are GlobalRefs instead of arrays](https://discourse.julialang.org/t/my-gradients-iddict-keys-are-globalrefs-instead-of-arrays/69665)

<div class="topic-metadata">

**Author:** [@Johan-Gronqvist](https://discourse.julialang.org/u/Johan-Gronqvist)\
**Replies:** 2\
**Last updated:** [October 17, 2021, 5:50pm UTC](https://discourse.julialang.org/t/my-gradients-iddict-keys-are-globalrefs-instead-of-arrays/69665 "2021-10-17T17:50:11Z")

</div>

My gradients sometimes appear with keys of type GlobalRef. I do not understand why and I do not understand how to change that. Example code: using Flux function h(x; bs=bs) for b in bs\[1:end-1\] x = x+b …

---

## [Data augmentation question (CIFAR10)](https://discourse.julialang.org/t/data-augmentation-question-cifar10/69667)

<div class="topic-metadata">

**Author:** [@Rasmus\_Hoier](https://discourse.julialang.org/u/Rasmus_Hoier)\
**Replies:** 9\
**Last updated:** [October 17, 2021, 9:36am UTC](https://discourse.julialang.org/t/data-augmentation-question-cifar10/69667 "2021-10-17T09:36:22Z")

</div>

Hi, I am training a CNN on CIFAR10 (via Flux.DataLoader) and am trying to apply some stochastic data transformations to each batch of data at runtime. My goal is to apply the following operations to each batch I get fr…

---

## [Using PPOPolicy with custom environment with action masking in ReinforcementLearning.jl](https://discourse.julialang.org/t/using-ppopolicy-with-custom-environment-with-action-masking-in-reinforcementlearning-jl/69625)

<div class="topic-metadata">

**Author:** [@mfg](https://discourse.julialang.org/u/mfg)\
**Replies:** 14\
**Last updated:** [October 16, 2021, 3:30am UTC](https://discourse.julialang.org/t/using-ppopolicy-with-custom-environment-with-action-masking-in-reinforcementlearning-jl/69625 "2021-10-16T03:30:47Z")

</div>

In order to use Action Masking with he PPOPolicy i think i have to use a MaskedPPOTrajectory. The legal\_actions\_mask gets updated in the update! function with the result of legal\_action\_space\_mask(env), but afaiu this sh…

---

## [Multilayer perceptron with multidimensional output array using Flux](https://discourse.julialang.org/t/multilayer-perceptron-with-multidimensional-output-array-using-flux/69747)

<div class="topic-metadata">

**Author:** [@FrootLoops](https://discourse.julialang.org/u/FrootLoops)\
**Replies:** 2\
**Last updated:** [October 14, 2021, 12:50pm UTC](https://discourse.julialang.org/t/multilayer-perceptron-with-multidimensional-output-array-using-flux/69747 "2021-10-14T12:50:22Z")

</div>

Hi, I have some problems coding a multilayer perceptron using Flux. My data is given in the form D=(x\_i, y\_i)\_{i=1}^n where x\_i is a scalar and y\_i is a 3-dim vector . I want to train a neural network using flux. Due to…

[Previous page](https://discourse.julialang.org/c/domain/ml/24.md?page=28)

[Next page](https://discourse.julialang.org/c/domain/ml/24.md?page=30)
