mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
check_env_flag now ignores case (#3317)
This commit is contained in:
committed by
Soumith Chintala
parent
d56713680d
commit
9735ddd899
@ -2,4 +2,4 @@ import os
|
||||
|
||||
|
||||
def check_env_flag(name):
|
||||
return os.getenv(name) in ['ON', '1', 'YES', 'TRUE', 'Y']
|
||||
return os.getenv(name, '').upper() in ['ON', '1', 'YES', 'TRUE', 'Y']
|
||||
|
Reference in New Issue
Block a user