mirror of
https://github.com/oobabooga/text-generation-webui.git
synced 2024-11-25 17:29:22 +01:00
Remove OOBABOOGA_FLAGS
This commit is contained in:
parent
ccfc919016
commit
967dda17a0
16
webui.py
16
webui.py
@ -14,18 +14,12 @@ conda_env_path = os.path.join(script_dir, "installer_files", "env")
|
|||||||
# os.environ["HCC_AMDGPU_TARGET"] = 'gfx1030'
|
# os.environ["HCC_AMDGPU_TARGET"] = 'gfx1030'
|
||||||
|
|
||||||
# Command-line flags
|
# Command-line flags
|
||||||
if "OOBABOOGA_FLAGS" in os.environ:
|
cmd_flags_path = os.path.join(script_dir, "CMD_FLAGS.txt")
|
||||||
CMD_FLAGS = os.environ["OOBABOOGA_FLAGS"]
|
if os.path.exists(cmd_flags_path):
|
||||||
print("The following flags have been taken from the environment variable 'OOBABOOGA_FLAGS':")
|
with open(cmd_flags_path, 'r') as f:
|
||||||
print(CMD_FLAGS)
|
CMD_FLAGS = ' '.join(line.strip() for line in f.read().splitlines() if line.strip())
|
||||||
print("To use the CMD_FLAGS Inside webui.py, unset 'OOBABOOGA_FLAGS'.\n")
|
|
||||||
else:
|
else:
|
||||||
cmd_flags_path = os.path.join(script_dir, "CMD_FLAGS.txt")
|
CMD_FLAGS = ''
|
||||||
if os.path.exists(cmd_flags_path):
|
|
||||||
with open(cmd_flags_path, 'r') as f:
|
|
||||||
CMD_FLAGS = ' '.join(line.strip() for line in f.read().splitlines() if line.strip())
|
|
||||||
else:
|
|
||||||
CMD_FLAGS = ''
|
|
||||||
|
|
||||||
|
|
||||||
def is_linux():
|
def is_linux():
|
||||||
|
Loading…
Reference in New Issue
Block a user