NeMo
NeMo copied to clipboard
Import pycuda.autoprimaryctx or pycuda.autoinit to init pycuda execut…
…ion environment
Signed-off-by: Jin Li [email protected]
What does this PR do ?
Import pycuda.autoprimaryctx or pycuda.autoinit to init pycuda execution environment to fix "invalid device context - no currently active context?" issue
Collection: [Note which collection this PR will affect]
Changelog
- Add specific line by line info of high level changes in this PR.
Usage
- You can potentially add a usage example below
# Add a code snippet demonstrating how to use this
Before your PR is "Ready for review"
Pre checks:
- [x] Make sure you read and followed Contributor guidelines
- [ ] Did you write any new necessary tests?
- [ ] Did you add or update any necessary documentation?
- [ ] Does the PR affect components that are optional to install? (Ex: Numba, Pynini, Apex etc)
- [ ] Reviewer: Does the PR have correct import guards for all optional libraries?
PR Type:
- [ ] New Feature
- [x] Bugfix
- [ ] Documentation
If you haven't finished some of the above items you can still open "Draft" PR.
Who can review?
Anyone in the community is free to review the PR once the checks have passed. Contributor guidelines contains specific people who can review PRs to various areas.
Additional Information
- Related to # (issue)
This pull request introduces 2 alerts when merging 28f9a5fd466d49d786c8cd37fe16e154c4d5a19f into f1825bc4b724b78c2d6ca392b616e8dc9a8cde04 - view on LGTM.com
new alerts:
- 2 for Unused import
What if pycuda isnt installed at all?
What if pycuda isnt installed at all?
@titu1994 This example cannot run without pycuda if I understand correctly.
This pull request introduces 2 alerts when merging 3b07c28c2c73196873099ccdec315b9590c8d298 into ed0282214f6f78fb21c1c18e0400a2f5ae4ec5b0 - view on LGTM.com
new alerts:
- 2 for Unused import