-
Notifications
You must be signed in to change notification settings - Fork 19
Added a cubic spline interpolator #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
Hmmm. Seems to be suffering from over-fitting. May be the algorithm itself... 😞 I'm going to close this until future development is required... |
| interp_and_extrap(shape=(500, 600, 100)) | ||
| parser = argparse.ArgumentParser(description='Run an interpolation.') | ||
| parser.add_argument('--shape', default='500,600,100', | ||
| help='The shape of the array to interpolate. Comma separated (no spaces).') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
E501 line too long (99 > 79 characters)
|
|
||
| def test_inbetween(self): | ||
| x = np.linspace(0, 4, 5) | ||
| xs = [0.5, 1.25, 2.5, 3.75] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
W291 trailing whitespace
|
Hey @pelson just noticed this. Really cool, is this interest driven? I see you closed it. |
|
I didn't delete the branch for a reason 😄 . Seems like an obvious extension to stratify, and one I'd love to see in here. Currently nobody actually needs this though (linear is typically good enough, even with atmospheric pressure, it seems) |

Surprisingly, this approach turns out to be ~4x faster than
Though the comparison is really apples vs oranges, as the algorithm implemented is different.
There is loads of room for improvement (and potentially even a better algorithm - this is the best I could find in a short search), but this is good enough to be useful already.