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

Use CUDA_VISIBLE_DEVICES by default #712

Merged
merged 18 commits into from
Nov 22, 2024

Conversation

benoit-cty
Copy link
Contributor

Following #567 it will be better for CodeCarbon to use the env variable CUDA_VISIBLE_DEVICES as a default value for the parameter gpu_ids.

I also drop Python 3.8 from CI as it is deprecated https://devguide.python.org/versions/ and use the same Python version everywhere in CI for consistency. I kept 3.8 in supported version to allow our users to continue to use CodeCarbon in 3.8 until it stop working.

@benoit-cty benoit-cty linked an issue Nov 15, 2024 that may be closed by this pull request
3 tasks
tests/test_gpu.py Outdated Show resolved Hide resolved
@benoit-cty benoit-cty marked this pull request as ready for review November 18, 2024 19:55
@benoit-cty benoit-cty force-pushed the 689-use-cuda_visible_devices-by-default branch from 8dd14d6 to dc72396 Compare November 18, 2024 19:55
Copy link
Contributor

@inimaz inimaz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this @benoit-cty !
Just small typo in one of the checks.

codecarbon/external/hardware.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@SaboniAmine SaboniAmine left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks Benoît! I'll let Inigo approve when his change request is done.

codecarbon/emissions_tracker.py Show resolved Hide resolved
Co-authored-by: inimaz <49730431+inimaz@users.noreply.github.com>
@benoit-cty benoit-cty merged commit 801fbe3 into master Nov 22, 2024
10 checks passed
@benoit-cty benoit-cty deleted the 689-use-cuda_visible_devices-by-default branch November 22, 2024 20:48
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 this pull request may close these issues.

Use CUDA_VISIBLE_DEVICES by default
3 participants