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

[FEA] Strings scatter function needed for cudf #3437

Closed
davidwendt opened this issue Nov 21, 2019 · 2 comments · Fixed by #3440
Closed

[FEA] Strings scatter function needed for cudf #3437

davidwendt opened this issue Nov 21, 2019 · 2 comments · Fixed by #3440
Assignees
Labels
feature request New feature or request Needs Triage Need team to review and classify

Comments

@davidwendt
Copy link
Contributor

Current function needs to be reworked for cudf scatter port. Here is the proposed signature as discussed with @trevorsm7 in slack discussion:

template <typename MapIterator>
std::unique_ptr<cudf::column> scatter( strings_column_view const& source,
                                       MapIterator scatter_map,
                                       strings_column_view const& target,
                                       rmm::mr::device_memory_resource* mr = rmm::mr::get_default_resource(),
                                       cudaStream_t stream = 0 );

Also, the null mask in the output column will be set by the caller. It will be initialized by copying the target's null mask before returning.

@davidwendt davidwendt added feature request New feature or request Needs Triage Need team to review and classify labels Nov 21, 2019
@davidwendt davidwendt self-assigned this Nov 21, 2019
@davidwendt
Copy link
Contributor Author

davidwendt commented Nov 21, 2019

Looks like scatter will also need a scalar version. Propose this:

template<typename MapIterator>
std::unique_ptr<column> scatter(
      string_scalar const& source,
      MapIterator scatter_iter, size_type scatter_rows,
      string_column_view const& target,
      rmm::mr::device_memory_resource* mr = rmm::mr::get_default_resource(),
      cudaStream_t stream = 0);

@jrhemstad
Copy link
Contributor

Perhaps instead of two separate APIs for scattering a column/scalar, just make the source an iterator?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request Needs Triage Need team to review and classify
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants