importing.py 398 Bytes
Newer Older
1
2
3
from importlib.util import find_spec

from vllm.logger import init_logger
4
from vllm.platforms import current_platform
5
6
7

logger = init_logger(__name__)

8
9
10
# neuron has too old torch
HAS_TRITON = find_spec(
    "triton") is not None and not current_platform.is_neuron()
11
12
13

if not HAS_TRITON:
    logger.info("Triton not installed; certain GPU-related functions"
14
                " will not be available.")