[misc] remove is_cuda_available (#5319)
This commit is contained in:
@@ -4,9 +4,9 @@ from typing import List
|
||||
|
||||
import torch
|
||||
|
||||
from sglang.srt.utils import is_cuda_available, is_hip
|
||||
from sglang.srt.utils import is_cuda, is_hip
|
||||
|
||||
if is_cuda_available() or is_hip():
|
||||
if is_cuda() or is_hip():
|
||||
from sgl_kernel import (
|
||||
build_tree_kernel_efficient as sgl_build_tree_kernel_efficient,
|
||||
)
|
||||
|
||||
@@ -19,9 +19,9 @@ from sglang.srt.managers.schedule_batch import (
|
||||
from sglang.srt.mem_cache.memory_pool import TokenToKVPoolAllocator
|
||||
from sglang.srt.model_executor.forward_batch_info import CaptureHiddenMode
|
||||
from sglang.srt.speculative.build_eagle_tree import build_tree_kernel_efficient
|
||||
from sglang.srt.utils import fast_topk, is_cuda_available, is_hip, next_power_of_2
|
||||
from sglang.srt.utils import fast_topk, is_cuda, is_hip, next_power_of_2
|
||||
|
||||
if is_cuda_available():
|
||||
if is_cuda():
|
||||
from sgl_kernel import (
|
||||
top_k_renorm_prob,
|
||||
top_p_renorm_prob,
|
||||
|
||||
@@ -34,14 +34,9 @@ from sglang.srt.speculative.eagle_utils import (
|
||||
select_top_k_tokens,
|
||||
)
|
||||
from sglang.srt.speculative.spec_info import SpeculativeAlgorithm
|
||||
from sglang.srt.utils import (
|
||||
empty_context,
|
||||
fast_topk,
|
||||
get_available_gpu_memory,
|
||||
is_cuda_available,
|
||||
)
|
||||
from sglang.srt.utils import empty_context, fast_topk, get_available_gpu_memory, is_cuda
|
||||
|
||||
if is_cuda_available():
|
||||
if is_cuda():
|
||||
from sgl_kernel import segment_packbits
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
Reference in New Issue
Block a user