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

cuVS docs updates for release #161

Merged
merged 7 commits into from
May 30, 2024
Merged

Conversation

cjnolet
Copy link
Member

@cjnolet cjnolet commented May 28, 2024

No description provided.

@cjnolet cjnolet added doc Improvements or additions to documentation improvement Improves an existing functionality labels May 28, 2024
@cjnolet cjnolet self-assigned this May 28, 2024
@cjnolet cjnolet requested review from a team as code owners May 28, 2024 22:45
@github-actions github-actions bot added the cpp label May 28, 2024
@codecov-commenter
Copy link

codecov-commenter commented May 29, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 70.21%. Comparing base (1912355) to head (4c7c175).
Report is 3 commits behind head on branch-24.06.

Additional details and impacted files
@@              Coverage Diff              @@
##           branch-24.06     #161   +/-   ##
=============================================
  Coverage         70.21%   70.21%           
=============================================
  Files                11       11           
  Lines                47       47           
=============================================
  Hits                 33       33           
  Misses               14       14           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@cjnolet cjnolet added non-breaking Introduces a non-breaking change and removed improvement Improves an existing functionality labels May 29, 2024
cpp/include/cuvs/neighbors/nn_descent.hpp Outdated Show resolved Hide resolved
docs/source/cpp_api/neighbors_nn_descent.rst Outdated Show resolved Hide resolved
docs/source/python_api.rst Show resolved Hide resolved
@cjnolet
Copy link
Member Author

cjnolet commented May 30, 2024

/merge

@rapids-bot rapids-bot bot merged commit a4c3a6f into branch-24.06 May 30, 2024
57 checks passed
@atbraoy
Copy link

atbraoy commented Jun 27, 2024

Hi Corey (@cjnolet), first thank you all for the great effort.
We are trying to use RAFT to take advantages of its acceleration. We just started and are trying to execute the notebook "VectorSearch_QuestionRetrieval.ipynb" on Azure instant (running the notebook on Databricks, 4 GPUs 'Tesla V100-PCIE-16GB' with enough memory). We are getting the error below when executing the function 'search_cuvs_pq(query="Who was Grace Hopper?")'. Note, we getting same error with 'pylibraft'

TypeError: The like argument must be an array-like that implements the __array_function__ protocol.
File , line 9
5 print("Original dataset: {:.1f} MB".format(original_mem / 2**20))
7 print("Memory saved: {:.1f}%".format(100 * (1 - pq_index_mem / original_mem)))
----> 9 search_raft_pq(query="Who was Grace Hopper?")
File /local_disk0/.ephemeral_nfs/envs/pythonEnv-aae71dcc-9f46-4c89-8451-4501a1d9016d/lib/python3.11/site-packages/pylibraft/common/device_ndarray.py:174, in device_ndarray.copy_to_host(self)
169 def copy_to_host(self):
170 """
171 Returns a new numpy.ndarray object on host with the current contents of
172 this device_ndarray
173 """
--> 174 ret = np.frombuffer(
175 self.device_buffer_.tobytes(),
176 dtype=self.dtype,
177 like=self.ndarray_,
178 ).astype(self.dtype)
179 ret = np.lib.stride_tricks.as_strided(ret, self.shape, self.strides)
180 return ret

And below is the terminal error, no Databricks notebook used in this case, just executing directly from a python file:

Traceback (most recent call last):
File "/Workspace/Users/cagra_test.py", line 78, in
search_raft_pq(query="Who was Grace Hopper?")
File "/Workspace/Users/cagra_test.py", line 61, in search_raft_pq
hits = ivf_pq.search(search_params, pq_index, question_embedding[None], top_k)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "handle.pyx", line 225, in pylibraft.common.handle.auto_sync_handle.wrapper
File "/local_disk0/.ephemeral_nfs/cluster_libraries/python/lib/python3.11/site-packages/pylibraft/common/outputs.py", line 88, in wrapper
return tuple(conv(ret_value))
^^^^^^^^^^^^^^^^^^^^^^
File "/local_disk0/.ephemeral_nfs/cluster_libraries/python/lib/python3.11/site-packages/pylibraft/common/outputs.py", line 71, in conv
yield convert_to_cai_type(i)
^^^^^^^^^^^^^^^^^^^^^^
File "/local_disk0/.ephemeral_nfs/cluster_libraries/python/lib/python3.11/site-packages/pylibraft/common/outputs.py", line 57, in convert_to_cai_type
return output_as_(device_ndarray)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Workspace/Users/cagra_test.py", line 9, in
pylibraft.config.set_output_as(lambda device_ndarray: device_ndarray.copy_to_host())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/local_disk0/.ephemeral_nfs/cluster_libraries/python/lib/python3.11/site-packages/pylibraft/common/device_ndarray.py", line 173, in copy_to_host
ret = np.frombuffer(
^^^^^^^^^^^^^^
TypeError: The like argument must be an array-like that implements the __array_function__ protocol.

I will appreciate your feedback!

Note: @cjnolet, our org has a direct connection with nvidia, if you would like to connect from there please dm me!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cpp doc Improvements or additions to documentation non-breaking Introduces a non-breaking change
Projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants