Skip to content
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

Expose stacking constructor to Python #37

Merged
merged 1 commit into from
Sep 18, 2023
Merged

Expose stacking constructor to Python #37

merged 1 commit into from
Sep 18, 2023

Conversation

jvansanten
Copy link
Collaborator

Expose the stacking ctor splinetable(std::vector<splinetable<Alloc>*> tables, std::vector<double> coordinates, int stackOrder) to Python via a class method SplineTable.stack(). Actually overloading the init method is somewhat awkward, but could be done if harmony between the C++ and Python APIs is important. Opinions welcome!

Fixes #25.

@jvansanten jvansanten requested a review from cnweaver September 18, 2023 12:42
Copy link
Collaborator

@cnweaver cnweaver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this solution is suitable; overloading __init__ is ugly and maybe confusing to users, so it seems worth allowing a small different in the interface in the two languages.

@jvansanten jvansanten merged commit fe57991 into master Sep 18, 2023
9 of 10 checks passed
@jvansanten jvansanten deleted the pystack branch September 18, 2023 18:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Spline Stacking in Python Bindings?
2 participants