Skip to content

Commit

Permalink
Fix finetuner gui code issues
Browse files Browse the repository at this point in the history
  • Loading branch information
bmaltais committed Jul 24, 2023
1 parent 4849ea8 commit fcf087c
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
14 changes: 11 additions & 3 deletions finetune_gui.py
Original file line number Diff line number Diff line change
Expand Up @@ -423,8 +423,13 @@ def train_model(
run_cmd += f' --full_path'

log.info(run_cmd)

executor.execute_command(run_cmd=run_cmd)

if not print_only_bool:
# Run the command
if os.name == 'posix':
os.system(run_cmd)
else:
subprocess.run(run_cmd)

# create images buckets
if generate_image_buckets:
Expand All @@ -447,7 +452,10 @@ def train_model(

if not print_only_bool:
# Run the command
executor.execute_command(run_cmd=run_cmd)
if os.name == 'posix':
os.system(run_cmd)
else:
subprocess.run(run_cmd)

image_num = len(
[
Expand Down
2 changes: 2 additions & 0 deletions library/class_basic_training.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,8 @@ def __init__(
'DAdaptSGD',
'Lion',
'Lion8bit',
"PagedAdamW8bit",
"PagedLion8bit",
'Prodigy',
'SGDNesterov',
'SGDNesterov8bit',
Expand Down
3 changes: 2 additions & 1 deletion requirements_windows_torch2.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
torch==2.0.1+cu118 torchvision==0.15.2+cu118 --index-url https://download.pytorch.org/whl/cu118 # no_verify
xformers==0.0.20 bitsandbytes==0.35.0
xformers==0.0.20
https://github.com/jllllll/bitsandbytes-windows-webui/releases/download/wheels/bitsandbytes-0.39.1-py3-none-win_amd64.whl # no_verify
tensorboard==2.12.3 tensorflow==2.12.0
-r requirements.txt

0 comments on commit fcf087c

Please sign in to comment.