-
Notifications
You must be signed in to change notification settings - Fork 40
Move to nanobind #455
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
base: main
Are you sure you want to change the base?
Move to nanobind #455
Conversation
flying-sheep
left a comment
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.
Oh wow, that looks super cool! Addresses all my previous concerns about manual specification of magic numbers for chunking, repetitive kernel wrapper code, and so on!
| from rapids_singlecell._cuda import _qc_cuda as _qc | ||
|
|
||
| if sparse.isspmatrix_csr(X): | ||
| _qc.sparse_qc_csr( |
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.
ditto, for all of these
2105d37 to
dddd9e8
Compare
flying-sheep
left a comment
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.
looks awesome, the module exports are much nicer now!
This is missing stub generation, otherwise really nice!
| static inline void launch_auc(std::uintptr_t ranks, int R, int C, std::uintptr_t cnct, | ||
| std::uintptr_t starts, std::uintptr_t lens, int n_sets, int n_up, | ||
| std::uintptr_t max_aucs, std::uintptr_t es, cudaStream_t stream) { | ||
| static inline void launch_auc(const int* ranks, int R, int C, const int* cnct, const int* starts, | ||
| const int* lens, int n_sets, int n_up, const float* max_aucs, | ||
| float* es, cudaStream_t stream) { |
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.
why do these stop being a pointer sized non-nullable ints and become a 🤷-sized signed ints? (same in many other places)
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.
because they are now typed by feeding them through nanobind
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.
so nanobind creates all this? then this shouldn’t be checked into Git and just be part of the build system.
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.
no this has to be specifically written for each function. I dont know if there is an abstraction that auto creates this in the build system
This for now is a test with precompiled cuda extensions.