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

Dynamically detect CUDA availability #174

Closed
mdekstrand opened this issue Nov 29, 2018 · 3 comments · Fixed by #518
Closed

Dynamically detect CUDA availability #174

mdekstrand opened this issue Nov 29, 2018 · 3 comments · Fixed by #518

Comments

@mdekstrand
Copy link

It'd be useful in my environment to dynamically detect whether CUDA is actually available when Implicit has been built with CUDA.

Our cluster has some nodes with GPUs and some without. As it is, my experiment code has logic to detect which queue I submitted an experiment to and set use_cuda appropriately; falling back to non-CUDA operation (possibly with a warning?) if CUDA is compiled but not available at runtime would simplify driver code operating in heterogeneous environments.

@lethaiq
Copy link

lethaiq commented Jun 14, 2019

I think this is incorporated in the latest version of the library.

@benfred benfred linked a pull request Jan 14, 2022 that will close this issue
@benfred
Copy link
Owner

benfred commented Jan 14, 2022

This is done with #518 - and will be in the next release. Sorry for the delay in getting this in.

The next release will also include some breaking API changes - and I'm wondering if this will affect the shims in lenskit ? #481 has details of the changes, but the big ones are that we're changing model.fit to take a user/items sparse matrix (instead of a item/users sparse matrix) and that we're also changing the return value type from the recommend/similar_items methods.

@mdekstrand
Copy link
Author

@benfred thanks! In the next release of LensKit (0.14), I am splitting the various shims into their own packages (implicit's is here), which will hopefully ease maintenance a bit. Can update that so it uses 0.5 easily enough, I think.

My only concern is that the current (and older) versions of LensKit don't have a max version bound on the implicit dependency, so they might pull in the newer version and break. I can push an update to the conda-forge package that puts in the max bound easily enough though.

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 a pull request may close this issue.

3 participants