mirror of
https://github.com/lllyasviel/stable-diffusion-webui-forge.git
synced 2026-04-23 07:49:27 +00:00
SD3+ (#2688)
Co-authored-by: graemeniedermayer graemeniedermayer@users.noreply.github.com
This commit is contained in:
@@ -2,11 +2,13 @@ import torch
|
||||
import math
|
||||
|
||||
from backend.attention import attention_pytorch as attention_function
|
||||
from transformers.activations import NewGELUActivation
|
||||
|
||||
|
||||
activations = {
|
||||
"gelu_pytorch_tanh": lambda a: torch.nn.functional.gelu(a, approximate="tanh"),
|
||||
"relu": torch.nn.functional.relu,
|
||||
"gelu_new": lambda a: NewGELUActivation()(a),
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user