mirror of
https://github.com/huggingface/lerobot.git
synced 2026-07-24 02:06:15 +00:00
chore(style): fix pre-commit
This commit is contained in:
@@ -60,8 +60,7 @@ class ActionSelectKwargs(TypedDict, total=False):
|
|||||||
|
|
||||||
|
|
||||||
def _gated_residual(residual: torch.Tensor, hidden_states: torch.Tensor, gate: torch.Tensor) -> torch.Tensor:
|
def _gated_residual(residual: torch.Tensor, hidden_states: torch.Tensor, gate: torch.Tensor) -> torch.Tensor:
|
||||||
"""Gated residual connection: residual + gate * hidden_states.
|
"""Gated residual connection: residual + gate * hidden_states."""
|
||||||
"""
|
|
||||||
return residual + gate.unsqueeze(-1) * hidden_states
|
return residual + gate.unsqueeze(-1) * hidden_states
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -59,8 +59,7 @@ class ActionSelectKwargs(TypedDict, total=False):
|
|||||||
|
|
||||||
|
|
||||||
def _gated_residual(residual: torch.Tensor, hidden_states: torch.Tensor, gate: torch.Tensor) -> torch.Tensor:
|
def _gated_residual(residual: torch.Tensor, hidden_states: torch.Tensor, gate: torch.Tensor) -> torch.Tensor:
|
||||||
"""Gated residual connection: residual + gate * hidden_states.
|
"""Gated residual connection: residual + gate * hidden_states."""
|
||||||
"""
|
|
||||||
return residual + gate.unsqueeze(-1) * hidden_states
|
return residual + gate.unsqueeze(-1) * hidden_states
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -30,6 +30,7 @@ from transformers.utils import (
|
|||||||
|
|
||||||
from .configuration_qwen2_5_vl import Qwen2_5_VLConfig, Qwen2_5_VLVisionConfig
|
from .configuration_qwen2_5_vl import Qwen2_5_VLConfig, Qwen2_5_VLVisionConfig
|
||||||
|
|
||||||
|
|
||||||
# TODO(Steven): SlidingWindowCache was removed in transformers v5. Define a placeholder so isinstance checks
|
# TODO(Steven): SlidingWindowCache was removed in transformers v5. Define a placeholder so isinstance checks
|
||||||
# always return False (which is the correct behavior when no sliding window cache is in use).
|
# always return False (which is the correct behavior when no sliding window cache is in use).
|
||||||
class _SlidingWindowCachePlaceholder:
|
class _SlidingWindowCachePlaceholder:
|
||||||
|
|||||||
Reference in New Issue
Block a user