# ContinuousDataDrivenProblem stuck if no time derivatives provided

**URL:** https://discourse.julialang.org/t/continuousdatadrivenproblem-stuck-if-no-time-derivatives-provided/105758
**Category:** Modelling & Simulations
**Created:** [November 3, 2023, 2:39pm UTC](https://discourse.julialang.org/t/continuousdatadrivenproblem-stuck-if-no-time-derivatives-provided/105758 "2023-11-03T14:39:11Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Maxime-Fantino](https://avatars.discourse-cdn.com/v4/letter/m/b5e925/32.png) [@Maxime-Fantino](https://discourse.julialang.org/u/Maxime-Fantino)
#### Post date: [November 3, 2023, 2:39pm UTC](https://discourse.julialang.org/t/continuousdatadrivenproblem-stuck-if-no-time-derivatives-provided/105758/1 "2023-11-03T14:39:11Z")

</div>

Hello,

I am trying to do inference on particle dynamics with data coming from a simulator, using the DataDrivenDiffEq package.

Similarly to what is done in the documentation ([Automatically Discover Missing Physics by Embedding Machine Learning into Differential Equations · Overview of Julia's SciML](https://docs.sciml.ai/Overview/stable/showcase/missing_physics/#Symbolic-regression-via-sparse-regression-(SINDy-based))), I want to use sparse regression with the SINDy method.  
I tried a first version with very simple relations between variables and using a collocation method to obtain the time derivatives ([Utilities · DataDrivenDiffEq.jl](https://docs.sciml.ai/DataDrivenDiffEq/stable/utils/#collocation)) but it wasn’t successful. I saw that it was possible to pass only positional data `X` and times `t` to `ContinuousDataDrivenProblem` in the documentation example cited above, and I thought it would handle the derivatives better than I did.

But with the following simple version, the code seems to get stuck at the  
`prob = ContinuousDataDrivenProblem(X, t)` line. No error returned, just an extremely long running time, potentially completely stuck (I had a result only once trying different data coming from ODE resolution but it was also extremely long).

```julia
using DataDrivenDiffEq
using DataDrivenSparse

N = 10
t = Float64.(collect(1:N))
X = Matrix(2.0t') + 0.5 * rand(N)'
prob = ContinuousDataDrivenProblem(X, t)

```

About the context and versions :

versioninfo()

```julia
Julia Version 1.9.1
Commit 147bdf428cd (2023-06-07 08:27 UTC)
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 20 × 13th Gen Intel(R) Core(TM) i9-13900H
  WORD_SIZE: 64
  LIBM: libopenlibm
  LLVM: libLLVM-14.0.6 (ORCJIT, goldmont)
  Threads: 20 on 20 virtual cores
Environment:
  JULIA_EDITOR = code

```

]st

```julia
  [6e4b80f9] BenchmarkTools v1.3.2
  [69e1c6dd] CellListMap v0.8.23
  [b0b7db55] ComponentArrays v0.15.4
  [2445eb08] DataDrivenDiffEq v1.3.0
  [5b588203] DataDrivenSparse v0.1.2
  [0c46a032] DifferentialEquations v7.11.0
  [31c24e10] Distributions v0.25.102
  [634d3b9d] DrWatson v2.13.0
  [5789e2e9] FileIO v1.16.1
  [70c4c096] Indicators v0.8.2
  [033835bb] JLD2 v0.4.37
  [b2108857] Lux v0.5.9
  [961ee093] ModelingToolkit v8.72.2
  [429524aa] Optim v1.7.8
  [7f7a1694] Optimization v3.19.3
  [3e6eede4] OptimizationBBO v0.1.5
  [36348300] OptimizationOptimJL v0.1.12
  [42dfb2eb] OptimizationOptimisers v0.1.6
  [1dea7af3] OrdinaryDiffEq v6.58.1
  [91a5bcdd] Plots v1.39.0
  [c46f51b8] ProfileView v1.7.2
  [49802e3a] ProgressBars v1.5.1
  [1ed8b502] SciMLSensitivity v7.46.0
  [860ef19b] StableRNGs v1.0.0
  [f3b207a7] StatsPlots v0.15.6
  [a110ec8f] Temporal v0.8.1
  [e88e6eb3] Zygote v0.6.67
  [37e2e46d] LinearAlgebra
  [10745b16] Statistics v1.9.0

```

Do you have any idea of what is happening ?  
Thank you very much for your support

---

<div class="post-metadata">

### Author: ![ChrisRackauckas](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chrisrackauckas/32/77_2.png) [@ChrisRackauckas](https://discourse.julialang.org/u/ChrisRackauckas)
#### Post date: [April 7, 2024, 1:44pm UTC](https://discourse.julialang.org/t/continuousdatadrivenproblem-stuck-if-no-time-derivatives-provided/105758/2 "2024-04-07T13:44:55Z")

</div>

There was a bug that is now fixed on the latest version (v1.4)
