diff --git a/readme.md b/readme.md
index 584fe90..74fca1d 100644
--- a/readme.md
+++ b/readme.md
@@ -39,9 +39,7 @@ ACE is a unified foundational model framework that supports a wide range of visu
context CU, we introduce historical contextual information into visual generation tasks, paving
the way for ChatGPT-like dialog systems in visual generation.
-
-
-
+[](https://ali-vilab.github.io/ace-page/)
### FLUX Tuners
@@ -81,6 +79,12 @@ the way for ChatGPT-like dialog systems in visual generation.
Example Workflow Case
+
+ Base
+ +Mantra
+ +Tuner
+ +Control
+
@@ -139,17 +143,18 @@ pip install scepter
### Currently supported approaches
-| Tasks | Methods | Links |
-|:----------------------------:|:-------------------------------------------:|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
-| Text-to-image Generation | SD v1.5 | [](https://huggingface.co/runwayml/stable-diffusion-v1-5) |
-| Text-to-image Generation | SD v2.1 | [](https://huggingface.co/runwayml/stable-diffusion-v1-5) |
-| Text-to-image Generation | SD-XL | [](https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0) |
-| Efficient Tuning | LoRA | [](https://arxiv.org/abs/2106.09685) |
-| Efficient Tuning | Res-Tuning(NeurIPS23) | [](https://arxiv.org/abs/2310.19859) [](https://res-tuning.github.io/) |
-| Controllable Image Synthesis | [🌟SCEdit(CVPR24)](docs/en/tasks/scedit.md) | [](https://arxiv.org/abs/2312.11392) [](https://scedit.github.io/) |
-| Image Editing | [🌟LAR-Gen](docs/en/tasks/largen.md) | [](https://arxiv.org/abs/2403.19534) [](https://ali-vilab.github.io/largen-page/) |
-| Image Editing | [🌟StyleBooth](docs/en/tasks/stylebooth.md) | [](https://arxiv.org/abs/2404.12154) [](https://ali-vilab.github.io/stylebooth-page/) |
-| Image Generation and Editing | [🌟ACE](https://ali-vilab.github.io/ace-page/) | [](https://arxiv.org/abs/2410.00086) [](https://ali-vilab.github.io/ace-page/) |
+| Tasks | Methods | Links |
+|:----------------------------:|:----------------------------------------------:|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
+| Text-to-image Generation | SD v1.5 | [](https://huggingface.co/runwayml/stable-diffusion-v1-5) |
+| Text-to-image Generation | SD v2.1 | [](https://huggingface.co/runwayml/stable-diffusion-v1-5) |
+| Text-to-image Generation | SD-XL | [](https://huggingface.co/stabilityai/stable-diffusion-xl-base-1.0) |
+| Text-to-image Generation | FLUX | [](https://huggingface.co/black-forest-labs/FLUX.1-dev) |
+| Efficient Tuning | LoRA | [](https://arxiv.org/abs/2106.09685) |
+| Efficient Tuning | Res-Tuning(NeurIPS23) | [](https://arxiv.org/abs/2310.19859) [](https://res-tuning.github.io/) |
+| Controllable Image Synthesis | [🌟SCEdit(CVPR24)](docs/en/tasks/scedit.md) | [](https://arxiv.org/abs/2312.11392) [](https://scedit.github.io/) |
+| Image Editing | [🌟LAR-Gen](docs/en/tasks/largen.md) | [](https://arxiv.org/abs/2403.19534) [](https://ali-vilab.github.io/largen-page/) |
+| Image Editing | [🌟StyleBooth](docs/en/tasks/stylebooth.md) | [](https://arxiv.org/abs/2404.12154) [](https://ali-vilab.github.io/stylebooth-page/) |
+| Image Generation and Editing | [🌟ACE](https://ali-vilab.github.io/ace-page/) | [](https://arxiv.org/abs/2410.00086) [](https://ali-vilab.github.io/ace-page/) |
## 🖥️ SCEPTER Studio
diff --git a/scepter/modules/inference/diffusion_inference.py b/scepter/modules/inference/diffusion_inference.py
index f00989a..0af1883 100644
--- a/scepter/modules/inference/diffusion_inference.py
+++ b/scepter/modules/inference/diffusion_inference.py
@@ -90,7 +90,10 @@ class DiffusionInference():
from safetensors.torch import load_file as load_safetensors
sd = load_safetensors(local_path)
else:
- sd = torch.load(local_path, map_location='cpu', weights_only=True)
+ if 'weights_only' in torch.load.__code__.co_varnames:
+ sd = torch.load(local_path, map_location='cpu', weights_only=True)
+ else:
+ sd = torch.load(local_path, map_location='cpu')
first_stage_model_path = os.path.join(
os.path.dirname(local_path), 'first_stage_model.pth')
cond_stage_model_path = os.path.join(
diff --git a/scepter/modules/inference/largen_inference.py b/scepter/modules/inference/largen_inference.py
index 55c43fd..86c4848 100644
--- a/scepter/modules/inference/largen_inference.py
+++ b/scepter/modules/inference/largen_inference.py
@@ -40,8 +40,10 @@ class LargenInference(DiffusionInference):
from safetensors.torch import load_file as load_safetensors
sd = load_safetensors(local_path)
else:
- sd = torch.load(local_path, map_location='cpu', weights_only=True)
-
+ if 'weights_only' in torch.load.__code__.co_varnames:
+ sd = torch.load(local_path, map_location='cpu', weights_only=True)
+ else:
+ sd = torch.load(local_path, map_location='cpu')
if 'model' in sd:
sd = sd['model']
diff --git a/scepter/modules/inference/tuner_inference.py b/scepter/modules/inference/tuner_inference.py
index 48f758d..e7c512a 100644
--- a/scepter/modules/inference/tuner_inference.py
+++ b/scepter/modules/inference/tuner_inference.py
@@ -143,7 +143,10 @@ class TunerInference():
state_dict = {}
is_bin_file = True
if os.path.isfile(bin_file):
- state_dict = torch.load(bin_file, weights_only=True)
+ if 'weights_only' in torch.load.__code__.co_varnames:
+ state_dict = torch.load(bin_file, weights_only=True)
+ else:
+ state_dict = torch.load(bin_file)
elif os.path.isfile(safe_file):
is_bin_file = False
from safetensors.torch import \