style: fix ruff lint warnings
- Remove unused local variable b in attention_backend.py - Remove unused variable rank0_sd in test_broadcast_state_dict.py - Remove unused imports across test files
This commit is contained in:
@@ -5,7 +5,6 @@ import torch
|
||||
|
||||
from astrai.config.model_config import AutoRegressiveLMConfig
|
||||
from astrai.model.transformer import AutoRegressiveLM
|
||||
from tests.conftest import skip_no_kernel
|
||||
|
||||
D = 64
|
||||
CFG = dict(
|
||||
|
||||
@@ -10,7 +10,6 @@ from astrai.extension import (
|
||||
ATTN_BACKEND,
|
||||
AttentionBackendFactory,
|
||||
CudaBackend,
|
||||
TorchNativeBackend,
|
||||
attn_backend,
|
||||
get_backend,
|
||||
)
|
||||
|
||||
@@ -31,7 +31,6 @@ def test_training_forward_matches_torch(cuda_model):
|
||||
or non-bf16 inputs it falls back to torch SDPA. Verify the fallback
|
||||
path matches the torch-native forward exactly.
|
||||
"""
|
||||
import pytest
|
||||
|
||||
model, _ = cuda_model
|
||||
input_ids = torch.randint(0, 1000, (2, 16), device="cuda")
|
||||
|
||||
Reference in New Issue
Block a user