Skip to content

Commit

Permalink
Merge pull request #1053 from akx/sdpa
Browse files Browse the repository at this point in the history
Fix typo `--spda` (it's `--sdpa`)
  • Loading branch information
kohya-ss committed Jan 16, 2024
2 parents 26d3579 + ef50436 commit e6b15c7
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ ControlNet-LLLite, a novel method for ControlNet with SDXL, is added. See [docum
- This feature works only on Linux or WSL.
- Please specify `--torch_compile` option in each training script.
- You can select the backend with `--dynamo_backend` option. The default is `"inductor"`. `inductor` or `eager` seems to work.
- Please use `--spda` option instead of `--xformers` option.
- Please use `--sdpa` option instead of `--xformers` option.
- PyTorch 2.1 or later is recommended.
- Please see [PR](https://github.com/kohya-ss/sd-scripts/pull/1024) for details.
- The session name for wandb can be specified with `--wandb_run_name` option. PR [#1032](https://github.com/kohya-ss/sd-scripts/pull/1032) Thanks to hopl1t!
Expand All @@ -270,7 +270,7 @@ ControlNet-LLLite, a novel method for ControlNet with SDXL, is added. See [docum
- Linux または WSL でのみ動作します。
- 各学習スクリプトで `--torch_compile` オプションを指定してください。
- `--dynamo_backend` オプションで使用される backend を選択できます。デフォルトは `"inductor"` です。 `inductor` または `eager` が動作するようです。
- `--xformers` オプションとは互換性がありません。 代わりに `--spda` オプションを使用してください。
- `--xformers` オプションとは互換性がありません。 代わりに `--sdpa` オプションを使用してください。
- PyTorch 2.1以降を推奨します。
- 詳細は [PR](https://github.com/kohya-ss/sd-scripts/pull/1024) をご覧ください。
- wandb 保存時のセッション名が各学習スクリプトの `--wandb_run_name` オプションで指定できるようになりました。 PR [#1032](https://github.com/kohya-ss/sd-scripts/pull/1032) hopl1t 氏に感謝します。
Expand Down
4 changes: 2 additions & 2 deletions library/original_unet.py
Original file line number Diff line number Diff line change
Expand Up @@ -1262,9 +1262,9 @@ def set_use_memory_efficient_attention(self, xformers, mem_eff):
for attn in self.attentions:
attn.set_use_memory_efficient_attention(xformers, mem_eff)

def set_use_sdpa(self, spda):
def set_use_sdpa(self, sdpa):
for attn in self.attentions:
attn.set_use_sdpa(spda)
attn.set_use_sdpa(sdpa)

def forward(
self,
Expand Down

0 comments on commit e6b15c7

Please sign in to comment.