Skip to content

Instantly share code, notes, and snippets.

@AustinRochford
Last active September 15, 2022 21:08
Show Gist options
  • Save AustinRochford/d640a240af12f6869a7b9b592485ca15 to your computer and use it in GitHub Desktop.
Save AustinRochford/d640a240af12f6869a7b9b592485ca15 to your computer and use it in GitHub Desktop.
PyMC3 BSplines
Display the source blob
Display the rendered blob
Raw
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Qiuchumo
Copy link

figure_1
I run your code in Pycharm, but I found delay phenomenon in spline line compare with true line, could you help me how can I solve this problem?

@sammosummo
Copy link

I think that's just what happened in your particular case. Here is the output from when I ran it (no delay):

bspline3

@siavashk
Copy link

I can understand most of what is happening here, but I am kind of stumped at this line. Why do we need to do a cumulative sum? Are we doing inverse CDF sampling here?
a = pm.Deterministic('a', a0 + (σ_a * Δ_a).cumsum())

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment