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

Using bifrost with a digitizer #193

Open
SBresler opened this issue Dec 14, 2022 · 2 comments
Open

Using bifrost with a digitizer #193

SBresler opened this issue Dec 14, 2022 · 2 comments

Comments

@SBresler
Copy link

SBresler commented Dec 14, 2022

Is it relatively straightforward to plug in data from a digitizer with this package?

Let's assume I can get this stuff off the card and into CPU RAM.

The digitizer is connected over PCI-e. Not ethernet.

I am thinking the answer is "Yes," just making sure i understand the purpose of this program.

@jaycedowell
Copy link
Collaborator

If you can get the address of the memory then, yes, you should be able to convert that to a bifrost.ndarray instance in the Python API or a BFarray in the C++ API.

@SBresler
Copy link
Author

OK. I have been using cupy for a lot of things and after getting nsight to work and tagging all of my stuff... it's just doing some stuff that I'm not so sure about.

for example:

If I do cp.ndarray = cupy.array(np.array)

I take that to mean that I already have an allocated cupy array, and I want to update it with the contents of another allocated numpy array, it should just point to the first element of the numpy array and do a memcpy using the pointer of the cupy array (making sure to check that the cupy and numpy array are C-contiguous and row major).

so I should see pci-e activity when I call cupy.array()

That's not what happens. So it's incentivizing me to go down a layer and do a little bit more memory management.

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

No branches or pull requests

2 participants