Skip to content

Commit 7ac22a8

Browse files
committed
[Fix] Fix lint error
1 parent d172f74 commit 7ac22a8

2 files changed

Lines changed: 2 additions & 1 deletion

File tree

xtuner/v1/module/rms_norm/rms_norm.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def forward(self, hidden_states: torch.Tensor) -> torch.Tensor:
2828
# hidden_states = hidden_states * torch.rsqrt(variance + self.variance_epsilon)
2929
# return (weight * hidden_states).to(input_dtype) # gpt_oss
3030
# return weight * hidden_states.to(input_dtype) # Llama
31-
return rms_norm(hidden_states, weight, epsilon=self.variance_epsilon) # xtuner
31+
return rms_norm(hidden_states, weight, epsilon=self.variance_epsilon) # type: ignore[operator]
3232

3333
def init_weights(self):
3434
self.weight.data.fill_(1.0)

xtuner/v1/train/trainer.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@
5454

5555
from .toy_tokenizer import UTF8ByteTokenizer
5656

57+
5758
# TODO: Move DEVICE to `xtuner.utils.device`
5859
DEVICE = get_device()
5960
DEVICE_MODULE = get_torch_device_module()

0 commit comments

Comments
 (0)