[platforms] enable platform plugins (#11602)
Signed-off-by: youkaichao <youkaichao@gmail.com>
This commit is contained in:
11
tests/plugins/vllm_add_dummy_platform/setup.py
Normal file
11
tests/plugins/vllm_add_dummy_platform/setup.py
Normal file
@ -0,0 +1,11 @@
|
||||
from setuptools import setup
|
||||
|
||||
setup(
|
||||
name='vllm_add_dummy_platform',
|
||||
version='0.1',
|
||||
packages=['vllm_add_dummy_platform'],
|
||||
entry_points={
|
||||
'vllm.platform_plugins': [
|
||||
"dummy_platform_plugin = vllm_add_dummy_platform:dummy_platform_plugin" # noqa
|
||||
]
|
||||
})
|
||||
@ -0,0 +1,5 @@
|
||||
from typing import Optional
|
||||
|
||||
|
||||
def dummy_platform_plugin() -> Optional[str]:
|
||||
return "vllm_add_dummy_platform.dummy_platform.DummyPlatform"
|
||||
@ -0,0 +1,5 @@
|
||||
from vllm.platforms.cuda import CudaPlatform
|
||||
|
||||
|
||||
class DummyPlatform(CudaPlatform):
|
||||
device_name = "DummyDevice"
|
||||
Reference in New Issue
Block a user