mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2026-02-17 00:43:48 +08:00
Fix ruff.
This commit is contained in:
parent
15d3724cbd
commit
1f924fba71
@ -3,6 +3,7 @@ import torch.nn as nn
|
|||||||
from dataclasses import dataclass
|
from dataclasses import dataclass
|
||||||
from typing import Optional, Any
|
from typing import Optional, Any
|
||||||
import math
|
import math
|
||||||
|
import logging
|
||||||
|
|
||||||
from comfy.ldm.modules.attention import optimized_attention_for_device
|
from comfy.ldm.modules.attention import optimized_attention_for_device
|
||||||
import comfy.model_management
|
import comfy.model_management
|
||||||
@ -315,7 +316,7 @@ class TransformerBlockGemma2(nn.Module):
|
|||||||
if self.transformer_type == 'gemma3':
|
if self.transformer_type == 'gemma3':
|
||||||
if self.sliding_attention:
|
if self.sliding_attention:
|
||||||
if x.shape[1] > self.sliding_attention:
|
if x.shape[1] > self.sliding_attention:
|
||||||
print("Warning: sliding attention not implemented, results may be incorrect")
|
logging.warning("Warning: sliding attention not implemented, results may be incorrect")
|
||||||
freqs_cis = freqs_cis[1]
|
freqs_cis = freqs_cis[1]
|
||||||
else:
|
else:
|
||||||
freqs_cis = freqs_cis[0]
|
freqs_cis = freqs_cis[0]
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user