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

Error module object: os.unsetenv('OMP_THREAD_LIMIT') doesn't work #1

Open
IsabelCanoA opened this issue Jul 14, 2023 · 1 comment
Open

Comments

@IsabelCanoA
Copy link

In BOWaves/scripts/run_sikmeans.py code, there is a line os.unsetenv('OMP_THREAD_LIMIT'). However, this line of code throws an error module 'os' has no attribute 'unsetenv'. As a result, the code cannot be executed correctly in my local environment.

I suggest replacing the line os.unsetenv('OMP_THREAD_LIMIT') with os.environ.pop('OMP_THREAD_LIMIT', None). It's another way to remove an environment variable in python and could help the code runs smoothly in different environments.

Environment Used:

Python Version: I tested it using python version 3.8.3 and 3.11.4
Operating System: Microsoft Windows 11 Home Single Language [10.0.22621]

Thanks for your attention and your contribution to this project!

@chmendoza
Copy link
Member

@IsabelCanoA , please open a PR to merge your suggested change and add me as a reviewer. I think we also need to move that line before numpy is imported.

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