NeuralPDE.jl slow with integro diff. equations

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))

?

It’s kind of inherent to the method, though we could make it 100x faster than it currently is. It just needs work.

Hi Chris, thank you for your time and response.

To clarify, my message wasn’t intended as a complaint. I was simply trying to understand if there is a more efficient way to add or use integrals within the NeuralPDE.jl framework.

Would it be more practical to construct a standard PINN using Lux or Flux and numerically compute the integrals over discrete sampling points, similar to what one woudl have to do in JAX, PyTorch, etc.?

NeuralPDE.jl just isn’t building it well. If you setup Lux.jl with Gauss points and Reactant you can probably to it a bit faster. Though Integrals.jl works inside of the loss function so you can just use that directly. We just need to update NeuralPDE.jl to use our more modern tooling.