My model can't be transfered to gpu. Adapt.jl problem?

Because closures are represented behind the scenes as anonymous Julia structs, any value a closure captures becomes on of the fields of that struct type. I believe static parameters here is referring to type parameters of the same struct type, which are required because the captured values could have arbitrary types. For more on this, see the official Julia documentation.

But to Carlo’s point, per Please read: make it easier to help you the very least we’d need is a full stacktrace if you’re unable to create a MWE. The next best thing to a MWE is a not-minimal working (i.e. runnable by a 3rd party) example, but note that the longer the reproducer the harder it will be to get help. But at least with a stacktrace and reproducible example, we might be able to help narrow things down to a MWE.