Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -442,7 +442,7 @@ To install FastSD CPU on Windows run the following steps :

![FastSD CPU running on Mac](https://raw.githubusercontent.com/rupeshs/fastsdcpu/main/docs/images/fastsdcpu-mac-gui.jpg)

:exclamation:**Ensure that you have Python 3.9 or 3.10 or 3.11 version installed.**
:exclamation:**Ensure that you have Python 3.9 or 3.10 or 3.11 or 3.12 version installed.**

Run the following commands to install FastSD CPU on Mac :

Expand Down
4 changes: 2 additions & 2 deletions benchmark-openvino.bat
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand Down
4 changes: 2 additions & 2 deletions benchmark.bat
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand Down
4 changes: 2 additions & 2 deletions install-mac.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PYTHON_COMMAND="python3"

if ! command -v python3 &>/dev/null; then
if ! command -v python &>/dev/null; then
echo "Error: Python not found, please install python 3.8 or higher and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi
fi
Expand All @@ -26,7 +26,7 @@ fi

BASEDIR=$(pwd)

uv venv --python 3.11.6 "$BASEDIR/env"
uv venv --python 3.12.3 "$BASEDIR/env"
# shellcheck disable=SC1091
source "$BASEDIR/env/bin/activate"
uv pip install torch==2.8.0
Expand Down
7 changes: 3 additions & 4 deletions install.bat
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

@echo off
setlocal
echo Starting FastSD CPU env installation...
Expand All @@ -7,9 +6,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found,please install Python(Recommended : Python 3.10 or Python 3.11) and try again."
echo "Error: Python command not found, please install Python(Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand All @@ -31,7 +30,7 @@ for /f "tokens=2" %%I in ('%PYTHON_COMMAND% --version 2^>^&1') do (

echo Python version: %python_version%

uv venv --python 3.11.6 "%~dp0env"
uv venv --python 3.12.3 "%~dp0env"
call "%~dp0env\Scripts\activate.bat" && uv pip install torch==2.8.0 --index-url https://download.pytorch.org/whl/cpu
call "%~dp0env\Scripts\activate.bat" && uv pip install -r "%~dp0requirements.txt"
echo FastSD CPU env installation completed.
Expand Down
6 changes: 3 additions & 3 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PYTHON_COMMAND="python3"

if ! command -v python3 &>/dev/null; then
if ! command -v python &>/dev/null; then
echo "Error: Python not found, please install python 3.8 or higher and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi
fi
Expand All @@ -26,10 +26,10 @@ fi

BASEDIR=$(pwd)

uv venv --python 3.11.6 "$BASEDIR/env"
uv venv --python 3.12.3 "$BASEDIR/env"
# shellcheck disable=SC1091
source "$BASEDIR/env/bin/activate"
uv pip install torch==2.8.0 --index-url https://download.pytorch.org/whl/cpu
uv pip install torch==2.8.0 torchvision --index-url https://download.pytorch.org/whl/cpu
if [[ "$1" == "--disable-gui" ]]; then
#! For termux , we don't need Qt based GUI
packages="$(grep -v "^ *#\|^PyQt5" requirements.txt | grep .)"
Expand Down
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ accelerate==1.6.0
diffusers==0.33.0
transformers==4.48.0
PyQt5
Pillow==9.4.0
Pillow==11.3.0
openvino==2025.1.0
optimum-intel==1.23.0
onnx==1.16.0
numpy==1.26.4
onnxruntime==1.17.3
pydantic
typing-extensions==4.10.0
typing-extensions==4.12.2
pyyaml==6.0.1
gradio==5.6.0
peft==0.6.1
Expand Down
2 changes: 1 addition & 1 deletion src/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@
parser.add_argument(
"--lora",
type=str,
help="LoRA model full path e.g D:\lora_models\CuteCartoon15V-LiberteRedmodModel-Cartoon-CuteCartoonAF.safetensors",
help=r"LoRA model full path e.g D:\lora_models\CuteCartoon15V-LiberteRedmodModel-Cartoon-CuteCartoonAF.safetensors",
default=None,
)
parser.add_argument(
Expand Down
60 changes: 30 additions & 30 deletions src/backend/openvino/stable_diffusion_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from typing import Union, Optional, Any, List, Dict
import numpy as np
# openvino
from openvino.runtime import Core
from openvino import Core
# tokenizer
from transformers import CLIPTokenizer
import torch
Expand Down Expand Up @@ -1781,37 +1781,37 @@ def print_npu_turbo_art():
random_number = random.randint(1, 3)

if random_number == 1:
print(" ")
print(" ___ ___ ___ ___ ___ ___ ")
print(" /\ \ /\ \ /\ \ /\ \ /\ \ _____ /\ \ ")
print(" \:\ \ /::\ \ \:\ \ ___ \:\ \ /::\ \ /::\ \ /::\ \ ")
print(" \:\ \ /:/\:\__\ \:\ \ /\__\ \:\ \ /:/\:\__\ /:/\:\ \ /:/\:\ \ ")
print(" _____\:\ \ /:/ /:/ / ___ \:\ \ /:/ / ___ \:\ \ /:/ /:/ / /:/ /::\__\ /:/ \:\ \ ")
print(" /::::::::\__\ /:/_/:/ / /\ \ \:\__\ /:/__/ /\ \ \:\__\ /:/_/:/__/___ /:/_/:/\:|__| /:/__/ \:\__\ ")
print(" \:\~~\~~\/__/ \:\/:/ / \:\ \ /:/ / /::\ \ \:\ \ /:/ / \:\/:::::/ / \:\/:/ /:/ / \:\ \ /:/ / ")
print(" \:\ \ \::/__/ \:\ /:/ / /:/\:\ \ \:\ /:/ / \::/~~/~~~~ \::/_/:/ / \:\ /:/ / ")
print(" \:\ \ \:\ \ \:\/:/ / \/__\:\ \ \:\/:/ / \:\~~\ \:\/:/ / \:\/:/ / ")
print(" \:\__\ \:\__\ \::/ / \:\__\ \::/ / \:\__\ \::/ / \::/ / ")
print(" \/__/ \/__/ \/__/ \/__/ \/__/ \/__/ \/__/ \/__/ ")
print(" ")
print(r" ")
print(r" ___ ___ ___ ___ ___ ___ ")
print(r" /\ \ /\ \ /\ \ /\ \ /\ \ _____ /\ \ ")
print(r" \:\ \ /::\ \ \:\ \ ___ \:\ \ /::\ \ /::\ \ /::\ \ ")
print(r" \:\ \ /:/\:\__\ \:\ \ /\__\ \:\ \ /:/\:\__\ /:/\:\ \ /:/\:\ \ ")
print(r" _____\:\ \ /:/ /:/ / ___ \:\ \ /:/ / ___ \:\ \ /:/ /:/ / /:/ /::\__\ /:/ \:\ \ ")
print(r" /::::::::\__\ /:/_/:/ / /\ \ \:\__\ /:/__/ /\ \ \:\__\ /:/_/:/__/___ /:/_/:/\:|__| /:/__/ \:\__\ ")
print(r" \:\~~\~~\/__/ \:\/:/ / \:\ \ /:/ / /::\ \ \:\ \ /:/ / \:\/:::::/ / \:\/:/ /:/ / \:\ \ /:/ / ")
print(r" \:\ \ \::/__/ \:\ /:/ / /:/\:\ \ \:\ /:/ / \::/~~/~~~~ \::/_/:/ / \:\ /:/ / ")
print(r" \:\ \ \:\ \ \:\/:/ / \/__\:\ \ \:\/:/ / \:\~~\ \:\/:/ / \:\/:/ / ")
print(r" \:\__\ \:\__\ \::/ / \:\__\ \::/ / \:\__\ \::/ / \::/ / ")
print(r" \/__/ \/__/ \/__/ \/__/ \/__/ \/__/ \/__/ \/__/ ")
print(r" ")
elif random_number == 2:
print(" _ _ ____ _ _ _____ _ _ ____ ____ ___ ")
print("| \ | | | _ \ | | | | |_ _| | | | | | _ \ | __ ) / _ \ ")
print("| \| | | |_) | | | | | | | | | | | | |_) | | _ \ | | | |")
print("| |\ | | __/ | |_| | | | | |_| | | _ < | |_) | | |_| |")
print("|_| \_| |_| \___/ |_| \___/ |_| \_\ |____/ \___/ ")
print(" ")
print(r" _ _ ____ _ _ _____ _ _ ____ ____ ___ ")
print(r"| \ | | | _ \ | | | | |_ _| | | | | | _ \ | __ ) / _ \ ")
print(r"| \| | | |_) | | | | | | | | | | | | |_) | | _ \ | | | |")
print(r"| |\ | | __/ | |_| | | | | |_| | | _ < | |_) | | |_| |")
print(r"|_| \_| |_| \___/ |_| \___/ |_| \_\ |____/ \___/ ")
print(r" ")
else:
print("")
print(" ) ( ( ) ")
print(" ( /( )\ ) * ) )\ ) ( ( /( ")
print(" )\()) (()/( ( ` ) /( ( (()/( ( )\ )\()) ")
print("((_)\ /(_)) )\ ( )(_)) )\ /(_)) )((_) ((_)\ ")
print(" _((_) (_)) _ ((_) (_(_()) _ ((_) (_)) ((_)_ ((_) ")
print("| \| | | _ \ | | | | |_ _| | | | | | _ \ | _ ) / _ \ ")
print("| .` | | _/ | |_| | | | | |_| | | / | _ \ | (_) | ")
print("|_|\_| |_| \___/ |_| \___/ |_|_\ |___/ \___/ ")
print(" ")
print(r"")
print(r" ) ( ( ) ")
print(r" ( /( )\ ) * ) )\ ) ( ( /( ")
print(r" )\()) (()/( ( ` ) /( ( (()/( ( )\ )\()) ")
print(r"((_)\ /(_)) )\ ( )(_)) )\ /(_)) )((_) ((_)\ ")
print(r" _((_) (_)) _ ((_) (_(_()) _ ((_) (_)) ((_)_ ((_) ")
print(r"| \| | | _ \ | | | | |_ _| | | | | | _ \ | _ ) / _ \ ")
print(r"| .` | | _/ | |_| | | | | |_| | | / | _ \ | (_) | ")
print(r"|_|\_| |_| \___/ |_| \___/ |_|_\ |___/ \___/ ")
print(r" ")



4 changes: 2 additions & 2 deletions start-mcpserver.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python command not found, please install Python (Recommended: Python 3.10..3.12) and try again"
pause
exit /b 1

Expand Down
2 changes: 1 addition & 1 deletion start-mcpserver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PYTHON_COMMAND="python3"

if ! command -v python3 &>/dev/null; then
if ! command -v python &>/dev/null; then
echo "Error: Python not found, please install python 3.8 or higher and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi
fi
Expand Down
4 changes: 2 additions & 2 deletions start-realtime.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand Down
2 changes: 1 addition & 1 deletion start-realtime.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ PYTHON_COMMAND="python3"
if command -v $PYTHON_COMMAND >/dev/null 2>&1; then
echo "Python command check: OK"
else
echo "Error: Python command not found, please install Python (Recommended: Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi

Expand Down
4 changes: 2 additions & 2 deletions start-webserver.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand Down
2 changes: 1 addition & 1 deletion start-webserver.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PYTHON_COMMAND="python3"

if ! command -v python3 &>/dev/null; then
if ! command -v python &>/dev/null; then
echo "Error: Python not found, please install python 3.8 or higher and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi
fi
Expand Down
6 changes: 3 additions & 3 deletions start-webui.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand All @@ -22,4 +22,4 @@ for /f "tokens=2" %%I in ('%PYTHON_COMMAND% --version 2^>^&1') do (
echo Python version: %python_version%

set PATH=%PATH%;%~dp0env\Lib\site-packages\openvino\libs
call "%~dp0env\Scripts\activate.bat" && %PYTHON_COMMAND% "%~dp0\src\app.py" -w
call "%~dp0env\Scripts\activate.bat" && %PYTHON_COMMAND% "%~dp0\src\app.py" -w --port 8000
2 changes: 1 addition & 1 deletion start-webui.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PYTHON_COMMAND="python3"

if ! command -v python3 &>/dev/null; then
if ! command -v python &>/dev/null; then
echo "Error: Python not found, please install python 3.8 or higher and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi
fi
Expand Down
4 changes: 2 additions & 2 deletions start.bat
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ set "PYTHON_COMMAND=python"

call python --version > nul 2>&1
if %errorlevel% equ 0 (
echo Python command check :OK
echo Python command check: OK
) else (
echo "Error: Python command not found, please install Python (Recommended : Python 3.10 or Python 3.11) and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
pause
exit /b 1

Expand Down
2 changes: 1 addition & 1 deletion start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ PYTHON_COMMAND="python3"

if ! command -v python3 &>/dev/null; then
if ! command -v python &>/dev/null; then
echo "Error: Python not found, please install python 3.8 or higher and try again"
echo "Error: Python not found, please install Python (Recommended: Python 3.10..3.12) and try again."
exit 1
fi
fi
Expand Down