# Machine Learning

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

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

**Page:** 6

---

## [AD Troubles in Flux and Unusual Loss](https://discourse.julialang.org/t/ad-troubles-in-flux-and-unusual-loss/122995)

<div class="topic-metadata">

**Author:** [@gideonsimpson](https://discourse.julialang.org/u/gideonsimpson)\
**Replies:** 1\
**Last updated:** [November 24, 2024, 12:09am UTC](https://discourse.julialang.org/t/ad-troubles-in-flux-and-unusual-loss/122995 "2024-11-24T00:09:08Z")

</div>

I’m struggling with the following issue. I want to train on a somewhat nonstandard loss function involving the gradient of the target. If everything worked, I would. use the following code: using Flux using Random usi…

---

## [Crash when tuning SVC with multithreading in MLJ.jl](https://discourse.julialang.org/t/crash-when-tuning-svc-with-multithreading-in-mlj-jl/122908)

<div class="topic-metadata">

**Author:** [@Yuan-Ru-Lin](https://discourse.julialang.org/u/Yuan-Ru-Lin)\
**Replies:** 4\
**Last updated:** [November 21, 2024, 10:11pm UTC](https://discourse.julialang.org/t/crash-when-tuning-svc-with-multithreading-in-mlj-jl/122908 "2024-11-21T22:11:41Z")

</div>

I have been trying to tune a set of hyper-parameters of a SVC. The SVC is from LIBSVM.jl. It works when I use only one thread, but crashes indeterministically with multiple threads. Not only did it may or may not crash,…

---

## [Kernel methods inside of Flux](https://discourse.julialang.org/t/kernel-methods-inside-of-flux/122820)

<div class="topic-metadata">

**Author:** [@gideonsimpson](https://discourse.julialang.org/u/gideonsimpson)\
**Replies:** 1\
**Last updated:** [November 20, 2024, 4:01am UTC](https://discourse.julialang.org/t/kernel-methods-inside-of-flux/122820 "2024-11-20T04:01:51Z")

</div>

I’m experimenting with setting up a classical RBF kernel method wtihin Flux, i.e., I want to train the model: \\sum\_{i=1}^n a\_i k(x, X\_i), where, for simplicity, take the kernel k to be a Gaussian. n is fixed, and the…

---

## [Flux conv with GPU Arrays](https://discourse.julialang.org/t/flux-conv-with-gpu-arrays/122513)

<div class="topic-metadata">

**Author:** [@trasor](https://discourse.julialang.org/u/trasor)\
**Replies:** 5\
**Last updated:** [November 12, 2024, 3:35pm UTC](https://discourse.julialang.org/t/flux-conv-with-gpu-arrays/122513 "2024-11-12T15:35:00Z")

</div>

Hello everyone, i managed to build a UNet with Flux. On the cpu, everything works. But when i transfer the model on the gpu (using Metal.jl), the convoltional layers throw me an error. using Flux using Meta…

---

## [Compile FastDifferentiation derivatives one time only](https://discourse.julialang.org/t/compile-fastdifferentiation-derivatives-one-time-only/121816)

<div class="topic-metadata">

**Author:** [@KeitaNakamura](https://discourse.julialang.org/u/KeitaNakamura)\
**Replies:** 27\
**Last updated:** [November 12, 2024, 6:09am UTC](https://discourse.julialang.org/t/compile-fastdifferentiation-derivatives-one-time-only/121816 "2024-11-12T06:09:09Z")

</div>

Hi @brianguenter, I’m currently using FastDifferentiation.jl, and I must say, the package is fantastic—it’s incredibly fast. Thank you very much for sharing this! I have a question regarding the differentiation processe…

---

## [NeuralPDE.jl slow with integro diff. equations](https://discourse.julialang.org/t/neuralpde-jl-slow-with-integro-diff-equations/122511)

<div class="topic-metadata">

**Author:** [@nico](https://discourse.julialang.org/u/nico)\
**Replies:** 3\
**Last updated:** [November 11, 2024, 8:42pm UTC](https://discourse.julialang.org/t/neuralpde-jl-slow-with-integro-diff-equations/122511 "2024-11-11T20:42:40Z")

</div>

Is there a reason why with integro-differential equations NeuralPDE.jl becomes very slow? Is there a better way to deal with integrals than with, e.g., Ii = Symbolics.Integral(t in DomainSets.ClosedInterval(0, t)) ?

---

## [(RL) Introducing the Julia community to PufferLib](https://discourse.julialang.org/t/rl-introducing-the-julia-community-to-pufferlib/122481)

<div class="topic-metadata">

**Author:** [@Tarny\_GG\_Channie](https://discourse.julialang.org/u/Tarny_GG_Channie)\
**Replies:** 0\
**Last updated:** [November 11, 2024, 3:26am UTC](https://discourse.julialang.org/t/rl-introducing-the-julia-community-to-pufferlib/122481 "2024-11-11T03:26:29Z")

</div>

This is not Julia-specific, but I’d like to post this anyway since I think Julia could be really good for it. Julia is a fast and easy language, which could be quite suitable for a reinforcement learning environment. P…

---

## [Machine learning in Julia decouples the Tensor and the autograd library, what was the practical benefit?](https://discourse.julialang.org/t/machine-learning-in-julia-decouples-the-tensor-and-the-autograd-library-what-was-the-practical-benefit/122447)

<div class="topic-metadata">

**Author:** [@Tarny\_GG\_Channie](https://discourse.julialang.org/u/Tarny_GG_Channie)\
**Replies:** 4\
**Last updated:** [November 9, 2024, 11:56am UTC](https://discourse.julialang.org/t/machine-learning-in-julia-decouples-the-tensor-and-the-autograd-library-what-was-the-practical-benefit/122447 "2024-11-09T11:56:57Z")

</div>

A typical machine learning framework is like this: First, you have a Tensor library that expresses computing and does matrix multiplication, among other things, and then you add automatic differentiation to the system an…

---

## [Dimension mismatch in Flux.jl RNN example](https://discourse.julialang.org/t/dimension-mismatch-in-flux-jl-rnn-example/122410)

<div class="topic-metadata">

**Author:** [@arinbasu1](https://discourse.julialang.org/u/arinbasu1)\
**Replies:** 2\
**Last updated:** [November 8, 2024, 6:40pm UTC](https://discourse.julialang.org/t/dimension-mismatch-in-flux-jl-rnn-example/122410 "2024-11-08T18:40:34Z")

</div>

I was trying to run an RNN model in Flux and came up with an error in the RNN model. This error also occurred in the RNN example from Flux’s documentation site: Here is the code: using Flux output\_size = 5 input\_size …

---

## [What are the future plans for Scientific ML?](https://discourse.julialang.org/t/what-are-the-future-plans-for-scientific-ml/122255)

<div class="topic-metadata">

**Author:** [@fastwave](https://discourse.julialang.org/u/fastwave)\
**Replies:** 1\
**Last updated:** [November 4, 2024, 3:03pm UTC](https://discourse.julialang.org/t/what-are-the-future-plans-for-scientific-ml/122255 "2024-11-04T15:03:54Z")

</div>

I wonder if someone can tell us about future plans? I did not see Reactant.jl mentioned here. It seems to me that this would be the Julia version of JAX, openXLA. Just like openXLA, it uses the MLIR from LLVM. I also wo…

---

## [Understanding the need for Torch.jl?](https://discourse.julialang.org/t/understanding-the-need-for-torch-jl/48824)

<div class="topic-metadata">

**Author:** [@xiaodai](https://discourse.julialang.org/u/xiaodai)\
**Replies:** 23\
**Last updated:** [November 4, 2024, 6:00pm UTC](https://discourse.julialang.org/t/understanding-the-need-for-torch-jl/48824 "2024-11-04T18:00:40Z")

</div>

Seems like the fastest NN library is Torch.jl which is based on C++. Is it possible for Julia to have something similarly fast? What’s preventing something as fast? Given Julia is meant to be able to solve the two langu…

---

## [Understanding Neural Networks (and Lux)](https://discourse.julialang.org/t/understanding-neural-networks-and-lux/122073)

<div class="topic-metadata">

**Author:** [@BLI](https://discourse.julialang.org/u/BLI)\
**Replies:** 3\
**Last updated:** [October 31, 2024, 2:52pm UTC](https://discourse.julialang.org/t/understanding-neural-networks-and-lux/122073 "2024-10-31T14:52:38Z")

</div>

0. Overview I’m trying to understand neural networks and Lux in particular, and how it is related to interpolation and least squares regression. So this post is more on fundamental understanding than Lux-technicalities. …

---

## [Odd warning and issues with optimization only when inside Optimization.jl. Zygote.hessian works fine](https://discourse.julialang.org/t/odd-warning-and-issues-with-optimization-only-when-inside-optimization-jl-zygote-hessian-works-fine/121967)

<div class="topic-metadata">

**Author:** [@Hareruya](https://discourse.julialang.org/u/Hareruya)\
**Replies:** 8\
**Last updated:** [October 30, 2024, 7:39pm UTC](https://discourse.julialang.org/t/odd-warning-and-issues-with-optimization-only-when-inside-optimization-jl-zygote-hessian-works-fine/121967 "2024-10-30T19:39:55Z")

</div>

Greetings, everyone. Apologies if the query is too basic, as it does not impede optimization in one case. I have graduated from my PhD program and have gotten a job at a company that offers me freedom in what programmin…

---

## [Balanced clustering or assignment of 3D points in space](https://discourse.julialang.org/t/balanced-clustering-or-assignment-of-3d-points-in-space/121192)

<div class="topic-metadata">

**Author:** [@BambOoxX](https://discourse.julialang.org/u/BambOoxX)\
**Replies:** 15\
**Last updated:** [October 27, 2024, 10:08am UTC](https://discourse.julialang.org/t/balanced-clustering-or-assignment-of-3d-points-in-space/121192 "2024-10-27T10:08:37Z")

</div>

I’m currently trying to solve the following problem Let P be a set of points in 3D space Split P into smaller sets of approximately equal size, the maximum size being a hard constraint Some properties about P P is g…

---

## [Avoid allocation of a Flux model on the CPU](https://discourse.julialang.org/t/avoid-allocation-of-a-flux-model-on-the-cpu/121785)

<div class="topic-metadata">

**Author:** [@mesonepigreco](https://discourse.julialang.org/u/mesonepigreco)\
**Replies:** 3\
**Last updated:** [October 27, 2024, 8:12am UTC](https://discourse.julialang.org/t/avoid-allocation-of-a-flux-model-on-the-cpu/121785 "2024-10-27T08:12:19Z")

</div>

Hi everyone, I have to execute a flux model inside a Monte Carlo simulation. I am currently working on the CPU; I am facing the problem of executing a model(configuration)for each step of the Monte Carlo, which allocate…

---

## [Timeseries model training using Lux.jl](https://discourse.julialang.org/t/timeseries-model-training-using-lux-jl/121618)

<div class="topic-metadata">

**Author:** [@Rosejoycrocker](https://discourse.julialang.org/u/Rosejoycrocker)\
**Replies:** 0\
**Last updated:** [October 22, 2024, 10:36pm UTC](https://discourse.julialang.org/t/timeseries-model-training-using-lux-jl/121618 "2024-10-22T22:36:06Z")

</div>

Hi, I’m using the Lux.jl simple LSTM classifier example ( Training a Simple LSTM | Lux.jl Docs ) to try and train a simple LSTM to predict timeseries data. I’m having issues however, as the LSTM model example is design…

---

## [Neural ODE with irregular Data Observations?](https://discourse.julialang.org/t/neural-ode-with-irregular-data-observations/121544)

<div class="topic-metadata">

**Author:** [@patrickm663](https://discourse.julialang.org/u/patrickm663)\
**Replies:** 2\
**Last updated:** [October 22, 2024, 12:52pm UTC](https://discourse.julialang.org/t/neural-ode-with-irregular-data-observations/121544 "2024-10-22T12:52:51Z")

</div>

Hi I have a dataset where the observed data is measured at irregular timesteps. I would like to use a neural ODE to interpolate and forecast. At the moment, I am using a feed-forward NN with fairly good success, howeve…

---

## [Custom Flux.jl Layer Not Updating (problem with Flux.trainable?)](https://discourse.julialang.org/t/custom-flux-jl-layer-not-updating-problem-with-flux-trainable/112842)

<div class="topic-metadata">

**Author:** [@eahenle](https://discourse.julialang.org/u/eahenle)\
**Replies:** 2\
**Last updated:** [October 19, 2024, 7:59am UTC](https://discourse.julialang.org/t/custom-flux-jl-layer-not-updating-problem-with-flux-trainable/112842 "2024-10-19T07:59:48Z")

</div>

I am having a problem getting a custom layer to update, and have tracked the issue to an apparent disconnect between Flux.trainable and Flux.setup. I read through related-sounding posts and issues, which seem to general…

---

## [Flux - sigmoid in last layer destroys learning?](https://discourse.julialang.org/t/flux-sigmoid-in-last-layer-destroys-learning/121174)

<div class="topic-metadata">

**Author:** [@BioTurboNick](https://discourse.julialang.org/u/BioTurboNick)\
**Replies:** 13\
**Last updated:** [October 11, 2024, 3:12pm UTC](https://discourse.julialang.org/t/flux-sigmoid-in-last-layer-destroys-learning/121174 "2024-10-11T15:12:18Z")

</div>

I’m fairly new to ML. But my understanding is that inner layers should generally use relu, and the final layer should use whatever function constrains the output to the range you want. In my case, sigmoid to constrain be…

---

## [Lux.jl with GPU error](https://discourse.julialang.org/t/lux-jl-with-gpu-error/121060)

<div class="topic-metadata">

**Author:** [@Sushrut\_Deshpande](https://discourse.julialang.org/u/Sushrut_Deshpande)\
**Replies:** 3\
**Last updated:** [October 10, 2024, 7:25pm UTC](https://discourse.julialang.org/t/lux-jl-with-gpu-error/121060 "2024-10-10T19:25:53Z")

</div>

Hello, I have a toy problem to fit a NN for sin(x) using the GPU for Lux.jl - LuxCUDA.jl Here is the code I am running (very similar to the documentation): using Lux, Optimisers,Zygote, Random using LuxCUDA x = rand…

---

## [2nd order optimization for Julia](https://discourse.julialang.org/t/2nd-order-optimization-for-julia/120966)

<div class="topic-metadata">

**Author:** [@Tarny\_GG\_Channie](https://discourse.julialang.org/u/Tarny_GG_Channie)\
**Replies:** 1\
**Last updated:** [October 6, 2024, 10:34pm UTC](https://discourse.julialang.org/t/2nd-order-optimization-for-julia/120966 "2024-10-06T22:34:17Z")

</div>

Lately, I’ve seen second-order optimization suddenly becoming a trend in deep learning. Is this An opportunity that Julia neural network system can do well? Something that would rather shift the balance toward PyTorch…

---

## [Flux: combine two neural networks to run simultaneously?](https://discourse.julialang.org/t/flux-combine-two-neural-networks-to-run-simultaneously/120776)

<div class="topic-metadata">

**Author:** [@greatpet](https://discourse.julialang.org/u/greatpet)\
**Replies:** 4\
**Last updated:** [October 2, 2024, 12:21pm UTC](https://discourse.julialang.org/t/flux-combine-two-neural-networks-to-run-simultaneously/120776 "2024-10-02T12:21:34Z")

</div>

For example, I have an input which is a length-10 vector. I want the first neural network to output a length-3 vector based on the first 5 elements of the input, and the second neural network to output a length-4 vector …

---

## [Copy metadata between DataFrames](https://discourse.julialang.org/t/copy-metadata-between-dataframes/107293)

<div class="topic-metadata">

**Author:** [@alex-s-gardner](https://discourse.julialang.org/u/alex-s-gardner)\
**Replies:** 2\
**Last updated:** [September 30, 2024, 7:32pm UTC](https://discourse.julialang.org/t/copy-metadata-between-dataframes/107293 "2024-09-30T19:32:45Z")

</div>

Is there a method to copy all of the metadata from one DataFrame to another?

---

## [Avoid storing intermediate results from the forward pass by default](https://discourse.julialang.org/t/avoid-storing-intermediate-results-from-the-forward-pass-by-default/119694)

<div class="topic-metadata">

**Author:** [@Jakub\_Mitura](https://discourse.julialang.org/u/Jakub_Mitura)\
**Replies:** 14\
**Last updated:** [September 29, 2024, 4:10pm UTC](https://discourse.julialang.org/t/avoid-storing-intermediate-results-from-the-forward-pass-by-default/119694 "2024-09-29T16:10:01Z")

</div>

Hello, Is it possible in Zygote to change the default behavior for computing derivatives during backpropagation to use gradient checkpointing? I have a memory-constrained problem with a Lux.jl model that uses Zygote fo…

---

## [Nested and different AD methods altogether: How to add AD calculations inside my loss function when using neural differential equations?](https://discourse.julialang.org/t/nested-and-different-ad-methods-altogether-how-to-add-ad-calculations-inside-my-loss-function-when-using-neural-differential-equations/108985)

<div class="topic-metadata">

**Author:** [@facusapienza](https://discourse.julialang.org/u/facusapienza)\
**Replies:** 9\
**Last updated:** [September 28, 2024, 12:16am UTC](https://discourse.julialang.org/t/nested-and-different-ad-methods-altogether-how-to-add-ad-calculations-inside-my-loss-function-when-using-neural-differential-equations/108985 "2024-09-28T00:16:46Z")

</div>

Hi all, I am implementing regularization penalties inside Universal Differential Equations (also applicable to Physics-Informed neural networks) where I need to differentiate a (loss) function that includes in its calcu…

---

## [Parameters in the neural network not updating after training](https://discourse.julialang.org/t/parameters-in-the-neural-network-not-updating-after-training/119914)

<div class="topic-metadata">

**Author:** [@Ashima\_Kalathingal](https://discourse.julialang.org/u/Ashima_Kalathingal)\
**Replies:** 0\
**Last updated:** [September 26, 2024, 12:04pm UTC](https://discourse.julialang.org/t/parameters-in-the-neural-network-not-updating-after-training/119914 "2024-09-26T12:04:53Z")

</div>

I am implementing a Neural ODE in julia. When I complete the training using ADAM optimizer, the loss function decreases as expected. But after training, the parameters reset to the original initial value. So I am not abl…

---

## [Convergence of inverse problem of heat equation with PINN](https://discourse.julialang.org/t/convergence-of-inverse-problem-of-heat-equation-with-pinn/119866)

<div class="topic-metadata">

**Author:** [@AliaNajwaMY](https://discourse.julialang.org/u/AliaNajwaMY)\
**Replies:** 0\
**Last updated:** [September 25, 2024, 1:41pm UTC](https://discourse.julialang.org/t/convergence-of-inverse-problem-of-heat-equation-with-pinn/119866 "2024-09-25T13:41:49Z")

</div>

I’m having trouble getting my inverse problem of heat equation with multiple parameters to converge using the neuromancer package (which encodes the PINN model). I am coding using python but was told that I still could a…

---

## [Emulate Enzyme.Const with Zygote](https://discourse.julialang.org/t/emulate-enzyme-const-with-zygote/119594)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 1\
**Last updated:** [September 19, 2024, 3:05pm UTC](https://discourse.julialang.org/t/emulate-enzyme-const-with-zygote/119594 "2024-09-19T15:05:39Z")

</div>

In the next release, DifferentiationInterface.jl will accept constant (non-differentiated) arguments c in addition to the active (differentiated) argument x, I’m wondering how to implement this mechanism optimally for ea…

---

## [Difficulties writing a program that computes PDEs involving Laplacians with AD](https://discourse.julialang.org/t/difficulties-writing-a-program-that-computes-pdes-involving-laplacians-with-ad/98834)

<div class="topic-metadata">

**Author:** [@Hareruya](https://discourse.julialang.org/u/Hareruya)\
**Replies:** 1\
**Last updated:** [September 19, 2024, 1:51am UTC](https://discourse.julialang.org/t/difficulties-writing-a-program-that-computes-pdes-involving-laplacians-with-ad/98834 "2024-09-19T01:51:24Z")

</div>

Greetings, I have been continuously running into an issue with the usage of AD to calculate the Helmholtz equation and the wave equation. My main area of research is acoustic signal processing, specifically concerning e…

---

## [Tokenising using TextAnalysis 0.8](https://discourse.julialang.org/t/tokenising-using-textanalysis-0-8/119573)

<div class="topic-metadata">

**Author:** [@ablaom](https://discourse.julialang.org/u/ablaom)\
**Replies:** 1\
**Last updated:** [September 19, 2024, 1:21am UTC](https://discourse.julialang.org/t/tokenising-using-textanalysis-0-8/119573 "2024-09-19T01:21:42Z")

</div>

Thanks to the maintainers of TextAnalysis. This works in TextAnalysis 0.7.5, but not here in 0.8.1: julia\> docs = \["Hi my name is Sam.", "How are you today?"\] 2-element Vector{String}: "Hi my name is Sam." "How are y…

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

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