Skip to content

Commit 72812db

Browse files
committed
tiny
1 parent 047ab9a commit 72812db

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

python/sglang/srt/mem_cache/mamba_radix_cache.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -515,7 +515,7 @@ def cache_unfinished_req(self, req: Req, chunked=False) -> None:
515515
)
516516

517517
if not mamba_exist:
518-
assert new_last_node.mamba_value == mamba_value_forked
518+
assert torch.equal(new_last_node.mamba_value, mamba_value_forked)
519519
assert len(req.prefix_indices) <= len(
520520
new_indices
521521
), f"{req.prefix_indices=}, {new_indices=}"

python/sglang/srt/mem_cache/memory_pool.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ def copy_from(self, src_index: torch.Tensor, dst_index: torch.Tensor):
216216
self.mamba_cache[1][:, dst_index] = self.mamba_cache[1][:, src_index]
217217
return
218218

219-
def fork_from(self, src_index: torch.Tensor) -> Optional[int]:
219+
def fork_from(self, src_index: torch.Tensor) -> Optional[torch.Tensor]:
220220
dst_index = self.alloc(1)
221221
if dst_index == None:
222222
return None

0 commit comments

Comments
 (0)