diff --git a/videollama2/lib/python3.10/site-packages/torch/include/ATen/ops/sqrt_cpu_dispatch.h b/videollama2/lib/python3.10/site-packages/torch/include/ATen/ops/sqrt_cpu_dispatch.h new file mode 100644 index 0000000000000000000000000000000000000000..de5d530a8cf30e1c82665705ee5d25de1647bc4b --- /dev/null +++ b/videollama2/lib/python3.10/site-packages/torch/include/ATen/ops/sqrt_cpu_dispatch.h @@ -0,0 +1,26 @@ +#pragma once +// @generated by torchgen/gen.py from DispatchKeyFunction.h + +// NB: The implementing C++ file is RegisterDispatchKey.cpp + +// The only #includes we need are for custom classes that have defaults in the C++ API +#include +#include +#include + +// Forward declarations of any types needed in the operator signatures. +// We can't directly include these classes because it will cause circular include dependencies. +// This file is included by TensorBody.h, which defines the Tensor class. +#include + +namespace at { + +namespace cpu { + +TORCH_API at::Tensor sqrt(const at::Tensor & self); +TORCH_API at::Tensor & sqrt_out(at::Tensor & out, const at::Tensor & self); +TORCH_API at::Tensor & sqrt_outf(const at::Tensor & self, at::Tensor & out); +TORCH_API at::Tensor & sqrt_(at::Tensor & self); + +} // namespace cpu +} // namespace at diff --git a/videollama2/lib/python3.10/site-packages/torch/include/ATen/ops/sum_compositeexplicitautograd_dispatch.h b/videollama2/lib/python3.10/site-packages/torch/include/ATen/ops/sum_compositeexplicitautograd_dispatch.h new file mode 100644 index 0000000000000000000000000000000000000000..1539e5e8740bca88c2504d7626decb22e3e7ad8f --- /dev/null +++ b/videollama2/lib/python3.10/site-packages/torch/include/ATen/ops/sum_compositeexplicitautograd_dispatch.h @@ -0,0 +1,25 @@ +#pragma once +// @generated by torchgen/gen.py from DispatchKeyFunction.h + +// NB: The implementing C++ file is RegisterDispatchKey.cpp + +// The only #includes we need are for custom classes that have defaults in the C++ API +#include +#include +#include + +// Forward declarations of any types needed in the operator signatures. +// We can't directly include these classes because it will cause circular include dependencies. +// This file is included by TensorBody.h, which defines the Tensor class. +#include + +namespace at { + +namespace compositeexplicitautograd { + +TORCH_API at::Tensor sum(const at::Tensor & self, c10::optional dtype=c10::nullopt); +TORCH_API at::Tensor & sum_out(at::Tensor & out, const at::Tensor & self, c10::optional dtype=c10::nullopt); +TORCH_API at::Tensor & sum_outf(const at::Tensor & self, c10::optional dtype, at::Tensor & out); + +} // namespace compositeexplicitautograd +} // namespace at diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/__init__.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/__init__.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e7ff887ca5e55038a2ce67e21ebd95ce69aab3db Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/__init__.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/_argcomplete.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/_argcomplete.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..51cd30930f7a07f5cf29bf5ae3b5b96ed408245a Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/_argcomplete.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/compat.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/compat.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..be8d8689c689f07b14801c3b9b76d1b111575125 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/compat.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/debugging.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/debugging.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..698d1b63337383613b677eccbaae5fd22f8fc59c Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/debugging.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/faulthandler.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/faulthandler.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..1be9bb86adf5c8b4a20aa3a22859f59cdcf6f81c Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/faulthandler.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/freeze_support.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/freeze_support.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..0ba71adb3270387daaaca68e0b8847b71421cdef Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/freeze_support.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/legacypath.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/legacypath.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..03ba915b6083122df7f4a5ca28465f3846a67a0d Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/legacypath.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/main.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/main.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..1bccc1c5a590fc58cabf296e9bf40521b07586a4 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/main.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/monkeypatch.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/monkeypatch.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..c207f94d51b861dc3e5e92c7808eade609aaafd9 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/monkeypatch.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/nodes.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/nodes.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..7684e3d8e4f7d322b8d949729dfa4e42026fc784 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/nodes.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/pathlib.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/pathlib.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..aec2cd1afdbfb910516011804fd60640734f2cb4 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/pathlib.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/pytester_assertions.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/pytester_assertions.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..4e3a7afd7b1bfd41c69d5d82ddf8f561a5d6f6c3 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/pytester_assertions.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/python.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/python.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..7cf5b67ae3dda8511c0bdbb264190c2d9eb53349 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/python.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/python_path.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/python_path.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..db9c9ef525ef11e377cbcc376e1a82afdccf643d Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/python_path.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/scope.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/scope.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..b19e692376dcb5e481402d96f7ef2cf59ed157d7 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/scope.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/skipping.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/skipping.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..39b6359d6e786901277a13e5f83101f89dec64ac Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/skipping.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/stash.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/stash.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..3bc861a92a7763bc725b2d49a2ea439b2da63565 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/stash.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/stepwise.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/stepwise.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e33aa1ce15fdb4d0a5d6ff1b8290784fea2789a4 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/stepwise.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/threadexception.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/threadexception.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..2ff509656a8f61c51354f6a4643efec2747e99b2 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/threadexception.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/timing.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/timing.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e723bfbd0588892289fe5ddc44a3dc46f9faa3dc Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/timing.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/unittest.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/unittest.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..a2326829af8584b7ccc0157f43dcaeb4a41aada0 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/unittest.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/_pytest/__pycache__/unraisableexception.cpython-310.pyc b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/unraisableexception.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..0acdd719eb6879a696130cf0c74ff538fc6b8c09 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/_pytest/__pycache__/unraisableexception.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__init__.py b/vllm/lib/python3.10/site-packages/gpustat/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..2b337e404e8b65711b225b833282f1b42fcf7d7a --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/__init__.py @@ -0,0 +1,30 @@ +""" +The gpustat module. +""" + +# isort: skip_file +try: + from ._version import version as __version__ + from ._version import version_tuple as __version_tuple__ +except (ImportError, AttributeError) as ex: + raise ImportError( + "Unable to find `gpustat.__version__` string. " + "Please try reinstalling gpustat; or if you are on a development " + "version, then run `pip install -e .` and try again." + ) from ex + +from .core import GPUStat, GPUStatCollection +from .core import new_query, gpu_count, is_available +from .cli import print_gpustat, main + + +__all__ = ( + '__version__', + 'GPUStat', + 'GPUStatCollection', + 'new_query', + 'gpu_count', + 'is_available', + 'print_gpustat', + 'main', +) diff --git a/vllm/lib/python3.10/site-packages/gpustat/__main__.py b/vllm/lib/python3.10/site-packages/gpustat/__main__.py new file mode 100644 index 0000000000000000000000000000000000000000..434e00e74a1b4aea990f48b79a85acb6090c5fbb --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/__main__.py @@ -0,0 +1,9 @@ +""" +gpustat.__main__ module (to support python -m gpustat) +""" + +from .cli import main + + +if __name__ == '__main__': + main() diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/__main__.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/__main__.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..d894951cd08c97428bcd4c56d36fb3d2674582d2 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/__main__.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/_shtab.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/_shtab.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..cfdf877b4b573e8d9e8b6d715e1c73350f4eb7b6 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/_shtab.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/_version.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/_version.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..89cd721c63d14f7f65c3964e6a838d399bc3644e Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/_version.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/core.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/core.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..c76f2b71e190e82b213a64d2be9e388272c49c4d Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/core.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/nvml.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/nvml.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..7f6faadd932c5e6b68586739206d45e2bfa65fa0 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/nvml.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/test_gpustat.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/test_gpustat.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..d47538979a5bc7ed7b26f6fc6c5886d12fdd4baf Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/test_gpustat.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/__pycache__/util_test.cpython-310.pyc b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/util_test.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..e45f4c590691d39928ee5a09ba200d6240df102c Binary files /dev/null and b/vllm/lib/python3.10/site-packages/gpustat/__pycache__/util_test.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/gpustat/_shtab.py b/vllm/lib/python3.10/site-packages/gpustat/_shtab.py new file mode 100644 index 0000000000000000000000000000000000000000..cbdce10cd6221cbf653587fda46b841b01550476 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/_shtab.py @@ -0,0 +1,8 @@ +FILE = None +DIRECTORY = DIR = None + + +def add_argument_to(parser, *args, **kwargs): + from argparse import Action + Action.complete = None + return parser diff --git a/vllm/lib/python3.10/site-packages/gpustat/_version.py b/vllm/lib/python3.10/site-packages/gpustat/_version.py new file mode 100644 index 0000000000000000000000000000000000000000..3d3d60a07601b0145b504798f2262cdafb48109c --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/_version.py @@ -0,0 +1,21 @@ +# file generated by setuptools-scm +# don't change, don't track in version control + +__all__ = ["__version__", "__version_tuple__", "version", "version_tuple"] + +TYPE_CHECKING = False +if TYPE_CHECKING: + from typing import Tuple + from typing import Union + + VERSION_TUPLE = Tuple[Union[int, str], ...] +else: + VERSION_TUPLE = object + +version: str +__version__: str +__version_tuple__: VERSION_TUPLE +version_tuple: VERSION_TUPLE + +__version__ = version = '1.1.1' +__version_tuple__ = version_tuple = (1, 1, 1) diff --git a/vllm/lib/python3.10/site-packages/gpustat/cli.py b/vllm/lib/python3.10/site-packages/gpustat/cli.py new file mode 100644 index 0000000000000000000000000000000000000000..dbc4e6197840352f0b52c40fcc1acddbc90a8247 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/cli.py @@ -0,0 +1,221 @@ +import os +import sys +import time +from contextlib import suppress + +from blessed import Terminal + +from gpustat import __version__ +from gpustat.core import GPUStatCollection + + +SHTAB_PREAMBLE = { + 'zsh': '''\ +# % gpustat -i +# float +# % gpustat -i - +# option +# -a Display all gpu properties above +# ... +_complete_for_one_or_zero() { + if [[ ${words[CURRENT]} == -* ]]; then + # override the original options + _shtab_gpustat_options=(${words[CURRENT - 1]} $_shtab_gpustat_options) + _arguments -C $_shtab_gpustat_options + else + eval "${@[-1]}" + fi +} +''' +} + + +def zsh_choices_to_complete(choices, tag='', description=''): + '''Change choices to complete for zsh. + + https://github.com/zsh-users/zsh/blob/master/Etc/completion-style-guide#L224 + ''' + complete = 'compadd - ' + ' '.join(filter(len, choices)) + if description == '': + description = tag + if tag != '': + complete = '_wanted ' + tag + ' expl ' + description + ' ' + complete + return complete + + +def get_complete_for_one_or_zero(input): + '''Get shell complete for nargs='?'. Now only support zsh.''' + output = {} + for sh, complete in input.items(): + if sh == 'zsh': + output[sh] = "_complete_for_one_or_zero '" + complete + "'" + return output + + +def print_gpustat(*, id=None, json=False, debug=False, **kwargs): + '''Display the GPU query results into standard output.''' + try: + gpu_stats = GPUStatCollection.new_query(debug=debug, id=id) + except Exception as e: + sys.stderr.write('Error on querying NVIDIA devices. ' + 'Use --debug flag to see more details.\n') + term = Terminal(stream=sys.stderr) + sys.stderr.write(term.red(str(e)) + '\n') + + if debug: + sys.stderr.write('\n') + try: + import traceback + traceback.print_exc(file=sys.stderr) + except Exception: + # NVMLError can't be processed by traceback: + # https://bugs.python.org/issue28603 + # as a workaround, simply re-throw the exception + raise e + + sys.stderr.flush() + sys.exit(1) + + if json: + gpu_stats.print_json(sys.stdout) + else: + gpu_stats.print_formatted(sys.stdout, **kwargs) + + +def loop_gpustat(interval=1.0, **kwargs): + term = Terminal() + + with term.fullscreen(): + while 1: + try: + query_start = time.time() + + # Move cursor to (0, 0) but do not restore original cursor loc + print(term.move(0, 0), end='') + print_gpustat(eol_char=term.clear_eol + os.linesep, **kwargs) + print(term.clear_eos, end='') + + query_duration = time.time() - query_start + sleep_duration = interval - query_duration + if sleep_duration > 0: + time.sleep(sleep_duration) + except KeyboardInterrupt: + return 0 + + +def main(*argv): + if not argv: + argv = list(sys.argv) + + # attach SIGPIPE handler to properly handle broken pipe + try: # sigpipe not available under windows. just ignore in this case + import signal + signal.signal(signal.SIGPIPE, signal.SIG_DFL) + except Exception as e: + pass + # arguments to gpustat + import argparse + try: + import shtab + except ImportError: + from . import _shtab as shtab + parser = argparse.ArgumentParser('gpustat') + shtab.add_argument_to(parser, preamble=SHTAB_PREAMBLE) + + def nonnegative_int(value): + value = int(value) + if value < 0: + raise argparse.ArgumentTypeError( + "Only non-negative integers are allowed.") + return value + + parser_color = parser.add_mutually_exclusive_group() + parser_color.add_argument('--force-color', '--color', action='store_true', + help='Force to output with colors') + parser_color.add_argument('--no-color', action='store_true', + help='Suppress colored output') + parser.add_argument('--id', help='Target a specific GPU (index).') + parser.add_argument('-a', '--show-all', action='store_true', + help='Display all gpu properties above') + parser.add_argument('-c', '--show-cmd', action='store_true', + help='Display cmd name of running process') + parser.add_argument( + '-f', '--show-full-cmd', action='store_true', default=False, + help='Display full command and cpu stats of running process' + ) + parser.add_argument('-u', '--show-user', action='store_true', + help='Display username of running process') + parser.add_argument('-p', '--show-pid', action='store_true', + help='Display PID of running process') + parser.add_argument('-F', '--show-fan-speed', '--show-fan', + action='store_true', help='Display GPU fan speed') + codec_choices = ['', 'enc', 'dec', 'enc,dec'] + parser.add_argument( + '-e', '--show-codec', nargs='?', const='enc,dec', default='', + choices=codec_choices, + help='Show encoder/decoder utilization' + ).complete = get_complete_for_one_or_zero( # type: ignore + {'zsh': zsh_choices_to_complete(codec_choices, 'codec')} + ) + power_choices = ['', 'draw', 'limit', 'draw,limit', 'limit,draw'] + parser.add_argument( + '-P', '--show-power', nargs='?', const='draw,limit', + choices=power_choices, + help='Show GPU power usage or draw (and/or limit)' + ).complete = get_complete_for_one_or_zero( # type: ignore + {'zsh': zsh_choices_to_complete(power_choices, 'power')} + ) + parser.add_argument('--json', action='store_true', default=False, + help='Print all the information in JSON format') + parser.add_argument( + '-i', '--interval', '--watch', nargs='?', type=float, default=0, + help='Use watch mode if given; seconds to wait between updates' + ).complete = get_complete_for_one_or_zero({'zsh': '_numbers float'}) # type: ignore + parser.add_argument( + '--no-header', dest='show_header', action='store_false', default=True, + help='Suppress header message' + ) + parser.add_argument( + '--gpuname-width', type=nonnegative_int, default=None, + help='The width at which GPU names will be displayed.' + ) + parser.add_argument( + '--debug', action='store_true', default=False, + help='Allow to print additional informations for debugging.' + ) + parser.add_argument( + '--no-processes', dest='no_processes', action='store_true', + help='Do not display running process information (memory, user, etc.)' + ) + parser.add_argument('-v', '--version', action='version', + version=('gpustat %s' % __version__)) + args = parser.parse_args(argv[1:]) + # TypeError: GPUStatCollection.print_formatted() got an unexpected keyword argument 'print_completion' + with suppress(AttributeError): + del args.print_completion # type: ignore + if args.show_all: + args.show_cmd = True + args.show_user = True + args.show_pid = True + args.show_fan_speed = True + args.show_codec = 'enc,dec' + args.show_power = 'draw,limit' + del args.show_all + + if args.interval is None: # with default value + args.interval = 1.0 + if args.interval > 0: + args.interval = max(0.1, args.interval) + if args.json: + sys.stderr.write("Error: --json and --interval/-i " + "can't be used together.\n") + sys.exit(1) + + loop_gpustat(**vars(args)) + else: + del args.interval + print_gpustat(**vars(args)) + + +if __name__ == '__main__': + main(*sys.argv) diff --git a/vllm/lib/python3.10/site-packages/gpustat/core.py b/vllm/lib/python3.10/site-packages/gpustat/core.py new file mode 100644 index 0000000000000000000000000000000000000000..dffda79ad5dc62b47e93baa45a30ca0302c1e792 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/core.py @@ -0,0 +1,764 @@ +#!/usr/bin/env python + +""" +Implementation of gpustat + +@author Jongwook Choi +@url https://github.com/wookayin/gpustat +""" + +from typing import Sequence +import json +import locale +import os.path +import platform +import sys +import time +from datetime import datetime +from io import StringIO + +import psutil +from blessed import Terminal + +import gpustat.util as util +from gpustat.nvml import pynvml as N + + +NOT_SUPPORTED = 'Not Supported' +MB = 1024 * 1024 + +DEFAULT_GPUNAME_WIDTH = 16 + +IS_WINDOWS = 'windows' in platform.platform().lower() + + +class GPUStat(object): + + def __init__(self, entry): + if not isinstance(entry, dict): + raise TypeError( + 'entry should be a dict, {} given'.format(type(entry)) + ) + self.entry = entry + + def __repr__(self): + return self.print_to(StringIO()).getvalue() + + def keys(self): + return self.entry.keys() + + def __getitem__(self, key): + return self.entry[key] + + @property + def available(self): + return True + + @property + def index(self): + """ + Returns the index of GPU (as in nvidia-smi). + """ + return self.entry['index'] + + @property + def uuid(self): + """ + Returns the uuid returned by nvidia-smi, + e.g. GPU-12345678-abcd-abcd-uuid-123456abcdef + """ + return self.entry['uuid'] + + @property + def name(self): + """ + Returns the name of GPU card (e.g. Geforce Titan X) + """ + return self.entry['name'] + + @property + def memory_total(self): + """ + Returns the total memory (in MB) as an integer. + """ + return int(self.entry['memory.total']) + + @property + def memory_used(self): + """ + Returns the occupied memory (in MB) as an integer. + """ + return int(self.entry['memory.used']) + + @property + def memory_free(self): + """ + Returns the free (available) memory (in MB) as an integer. + """ + v = self.memory_total - self.memory_used + return max(v, 0) + + @property + def memory_available(self): + """ + Returns the available memory (in MB) as an integer. + Alias of memory_free. + """ + return self.memory_free + + @property + def temperature(self): + """ + Returns the temperature (in celcius) of GPU as an integer, + or None if the information is not available. + """ + v = self.entry['temperature.gpu'] + return int(v) if v is not None else None + + @property + def fan_speed(self): + """ + Returns the fan speed percentage (0-100) of maximum intended speed + as an integer, or None if the information is not available. + """ + v = self.entry['fan.speed'] + return int(v) if v is not None else None + + @property + def utilization(self): + """ + Returns the GPU utilization (in percentile), + or None if the information is not available. + """ + v = self.entry['utilization.gpu'] + return int(v) if v is not None else None + + @property + def utilization_enc(self): + """ + Returns the GPU encoder utilization (in percentile), + or None if the information is not available. + """ + v = self.entry['utilization.enc'] + return int(v) if v is not None else None + + @property + def utilization_dec(self): + """ + Returns the GPU decoder utilization (in percentile), + or None if the information is not available. + """ + v = self.entry['utilization.dec'] + return int(v) if v is not None else None + + @property + def power_draw(self): + """ + Returns the GPU power usage in Watts, + or None if the information is not available. + """ + v = self.entry['power.draw'] + return int(v) if v is not None else None + + @property + def power_limit(self): + """ + Returns the (enforced) GPU power limit in Watts, + or None if the information is not available. + """ + v = self.entry['enforced.power.limit'] + return int(v) if v is not None else None + + @property + def processes(self): + """ + Get the list of running processes on the GPU. + """ + return self.entry['processes'] + + def print_to(self, fp, *, + with_colors=True, # deprecated arg + show_cmd=False, + show_full_cmd=False, + no_processes=False, + show_user=False, + show_pid=False, + show_fan_speed=None, + show_codec="", + show_power=None, + gpuname_width=None, + eol_char=os.linesep, + term=None, + ): + if term is None: + term = Terminal(stream=sys.stdout) + + # color settings + colors = {} + + def _conditional(cond_fn, true_value, false_value, + error_value=term.bold_black): + try: + return cond_fn() and true_value or false_value + except Exception: + return error_value + + _ENC_THRESHOLD = 50 + + colors['C0'] = term.normal + colors['C1'] = term.cyan + colors['CBold'] = term.bold + colors['CName'] = _conditional(lambda: self.available, + term.blue, term.red) + colors['CTemp'] = _conditional(lambda: self.temperature < 50, + term.red, term.bold_red) + colors['FSpeed'] = _conditional(lambda: self.fan_speed < 30, + term.cyan, term.bold_cyan) + colors['CMemU'] = _conditional(lambda: self.available, + term.bold_yellow, term.bold_black) + colors['CMemT'] = _conditional(lambda: self.available, + term.yellow, term.bold_black) + colors['CMemP'] = term.yellow + colors['CCPUMemU'] = term.yellow + colors['CUser'] = term.bold_black # gray + colors['CUtil'] = _conditional(lambda: self.utilization < 30, + term.green, term.bold_green) + colors['CUtilEnc'] = _conditional( + lambda: self.utilization_enc < _ENC_THRESHOLD, + term.green, term.bold_green) + colors['CUtilDec'] = _conditional( + lambda: self.utilization_dec < _ENC_THRESHOLD, + term.green, term.bold_green) + colors['CCPUUtil'] = term.green + colors['CPowU'] = _conditional( + lambda: (self.power_limit is not None and + float(self.power_draw) / self.power_limit < 0.4), + term.magenta, term.bold_magenta + ) + colors['CPowL'] = term.magenta + colors['CCmd'] = term.color(24) # a bit dark + + if not with_colors: + for k in list(colors.keys()): + colors[k] = '' + + def _repr(v, none_value='??'): + return none_value if v is None else v + + # build one-line display information + # we want power use optional, but if deserves being grouped with + # temperature and utilization + reps = u"%(C1)s[{entry[index]}]%(C0)s " + if gpuname_width is None or gpuname_width != 0: + reps += u"%(CName)s{entry_name:{gpuname_width}}%(C0)s |" + reps += u"%(CTemp)s{entry[temperature.gpu]:>3}°C%(C0)s, " + + if show_fan_speed: + reps += "%(FSpeed)s{entry[fan.speed]:>3} %%%(C0)s, " + + reps += "%(CUtil)s{entry[utilization.gpu]:>3} %%%(C0)s" + + if show_codec: + codec_info = [] + if "enc" in show_codec: + codec_info.append( + "%(CBold)sE: %(C0)s" + "%(CUtilEnc)s{entry[utilization.enc]:>3} %%%(C0)s") + if "dec" in show_codec: + codec_info.append( + "%(CBold)sD: %(C0)s" + "%(CUtilDec)s{entry[utilization.dec]:>3} %%%(C0)s") + reps += " ({})".format(" ".join(codec_info)) + + if show_power: + reps += ", %(CPowU)s{entry[power.draw]:>3}%(C0)s " + if show_power is True or 'limit' in show_power: + reps += "/ %(CPowL)s{entry[enforced.power.limit]:>3}%(C0)s " + reps += "%(CPowL)sW%(C0)s" + else: + reps += "%(CPowU)sW%(C0)s" + + reps += " | %(C1)s%(CMemU)s{entry[memory.used]:>5}%(C0)s " \ + "/ %(CMemT)s{entry[memory.total]:>5}%(C0)s MB" + reps = (reps) % colors + + class entry_repr_accessor: + def __init__(self, entry): + self.entry = entry + def __getitem__(self, key): + return _repr(self.entry[key]) + + reps = reps.format( + entry=entry_repr_accessor(self.entry), + entry_name=util.shorten_left( + self.entry["name"], width=gpuname_width, placeholder='…'), + gpuname_width=gpuname_width or DEFAULT_GPUNAME_WIDTH + ) + + # Add " |" only if processes information is to be added. + if not no_processes: + reps += " |" + + def process_repr(p): + r = '' + if not show_cmd or show_user: + r += "{CUser}{}{C0}".format( + _repr(p['username'], '--'), **colors + ) + if show_cmd: + if r: + r += ':' + r += "{C1}{}{C0}".format( + _repr(p.get('command', p['pid']), '--'), **colors + ) + + if show_pid: + r += ("/%s" % _repr(p['pid'], '--')) + r += '({CMemP}{}M{C0})'.format( + _repr(p['gpu_memory_usage'], '?'), **colors + ) + return r + + def full_process_info(p): + r = "{C0} ├─ {:>6} ".format( + _repr(p['pid'], '--'), **colors + ) + r += "{C0}({CCPUUtil}{:4.0f}%{C0}, {CCPUMemU}{:>6}{C0})".format( + _repr(p['cpu_percent'], '--'), + util.bytes2human(_repr(p['cpu_memory_usage'], 0)), **colors + ) + full_command_pretty = util.prettify_commandline( + p['full_command'], colors['C1'], colors['CCmd']) + r += "{C0}: {CCmd}{}{C0}".format( + _repr(full_command_pretty, '?'), + **colors + ) + return r + + processes = self.entry['processes'] + full_processes = [] + if processes is None and not no_processes: + # None (not available) + reps += ' ({})'.format(NOT_SUPPORTED) + elif not no_processes: + for p in processes: + reps += ' ' + process_repr(p) + if show_full_cmd: + full_processes.append(eol_char + full_process_info(p)) + if show_full_cmd and full_processes: + full_processes[-1] = full_processes[-1].replace('├', '└', 1) + reps += ''.join(full_processes) + fp.write(reps) + return fp + + def jsonify(self): + o = self.entry.copy() + if self.entry['processes'] is not None: + o['processes'] = [{k: v for (k, v) in p.items() if k != 'gpu_uuid'} + for p in self.entry['processes']] + return o + + +class InvalidGPU(GPUStat): + class FallbackDict(dict): + def __missing__(self, key): + return "?" + + def __init__(self, gpu_index, message, ex): + super().__init__(self.FallbackDict( + index=gpu_index, + name=message, + processes=None + )) + self.exception = ex + + @property + def available(self): + return False + + +class GPUStatCollection(Sequence[GPUStat]): + + global_processes = {} + + def __init__(self, gpu_list, driver_version=None): + self.gpus = gpu_list + + # attach additional system information + self.hostname = platform.node() + self.query_time = datetime.now() + self.driver_version = driver_version + + @staticmethod + def clean_processes(): + for pid in list(GPUStatCollection.global_processes.keys()): + if not psutil.pid_exists(pid): + del GPUStatCollection.global_processes[pid] + + @staticmethod + def new_query(debug=False, id=None) -> 'GPUStatCollection': + """Query the information of all the GPUs on local machine""" + + N.nvmlInit() + log = util.DebugHelper() + + def _decode(b): + if isinstance(b, bytes): + return b.decode('utf-8') # for python3, to unicode + return b + + def get_gpu_info(handle): + """Get one GPU information specified by nvml handle""" + + def safepcall(fn, error_value): + # Ignore the exception from psutil when the process is gone + # at the moment of querying. See #144. + return util.safecall( + fn, error_value=error_value, + exc_types=(psutil.AccessDenied, psutil.NoSuchProcess, + FileNotFoundError)) + + def get_process_info(nv_process): + """Get the process information of specific pid""" + process = {} + if nv_process.pid not in GPUStatCollection.global_processes: + GPUStatCollection.global_processes[nv_process.pid] = \ + psutil.Process(pid=nv_process.pid) + ps_process: psutil.Process = GPUStatCollection.global_processes[nv_process.pid] + + # TODO: ps_process is being cached, but the dict below is not. + process['username'] = safepcall(ps_process.username, '?') + # cmdline returns full path; + # as in `ps -o comm`, get short cmdnames. + _cmdline = safepcall(ps_process.cmdline, []) + if not _cmdline: + # sometimes, zombie or unknown (e.g. [kworker/8:2H]) + process['command'] = '?' + process['full_command'] = ['?'] + else: + process['command'] = os.path.basename(_cmdline[0]) + process['full_command'] = _cmdline + # Bytes to MBytes + # if drivers are not TTC this will be None. + usedmem = nv_process.usedGpuMemory // MB if \ + nv_process.usedGpuMemory else None + process['gpu_memory_usage'] = usedmem + + process['cpu_percent'] = safepcall(ps_process.cpu_percent, 0.0) + process['cpu_memory_usage'] = safepcall( + lambda: round((ps_process.memory_percent() / 100.0) * + psutil.virtual_memory().total), + 0.0) + + process['pid'] = nv_process.pid + return process + + name = _decode(N.nvmlDeviceGetName(handle)) + uuid = _decode(N.nvmlDeviceGetUUID(handle)) + + try: + temperature = N.nvmlDeviceGetTemperature( + handle, N.NVML_TEMPERATURE_GPU + ) + except N.NVMLError as e: + log.add_exception("temperature", e) + temperature = None # Not supported + + try: + fan_speed = N.nvmlDeviceGetFanSpeed(handle) + except N.NVMLError as e: + log.add_exception("fan_speed", e) + fan_speed = None # Not supported + + try: + # memory: in Bytes + # Note that this is a compat-patched API (see gpustat.nvml) + memory = N.nvmlDeviceGetMemoryInfo(handle) + except N.NVMLError as e: + log.add_exception("memory", e) + memory = None # Not supported + + try: + utilization = N.nvmlDeviceGetUtilizationRates(handle) + except N.NVMLError as e: + log.add_exception("utilization", e) + utilization = None # Not supported + + try: + utilization_enc = N.nvmlDeviceGetEncoderUtilization(handle) + except N.NVMLError as e: + log.add_exception("utilization_enc", e) + utilization_enc = None # Not supported + + try: + utilization_dec = N.nvmlDeviceGetDecoderUtilization(handle) + except N.NVMLError as e: + log.add_exception("utilization_dec", e) + utilization_dec = None # Not supported + + try: + power = N.nvmlDeviceGetPowerUsage(handle) + except N.NVMLError as e: + log.add_exception("power", e) + power = None + + try: + power_limit = N.nvmlDeviceGetEnforcedPowerLimit(handle) + except N.NVMLError as e: + log.add_exception("power_limit", e) + power_limit = None + + try: + nv_comp_processes = \ + N.nvmlDeviceGetComputeRunningProcesses(handle) + except N.NVMLError as e: + log.add_exception("compute_processes", e) + nv_comp_processes = None # Not supported + try: + nv_graphics_processes = \ + N.nvmlDeviceGetGraphicsRunningProcesses(handle) + except N.NVMLError as e: + log.add_exception("graphics_processes", e) + nv_graphics_processes = None # Not supported + + if nv_comp_processes is None and nv_graphics_processes is None: + processes = None + else: + processes = [] + nv_comp_processes = nv_comp_processes or [] + nv_graphics_processes = nv_graphics_processes or [] + # A single process might run in both of graphics and compute mode, + # However we will display the process only once + seen_pids = set() + for nv_process in nv_comp_processes + nv_graphics_processes: + if nv_process.pid in seen_pids: + continue + seen_pids.add(nv_process.pid) + try: + process = get_process_info(nv_process) + processes.append(process) + except psutil.NoSuchProcess: + # TODO: add some reminder for NVML broken context + # e.g. nvidia-smi reset or reboot the system + pass + except psutil.AccessDenied: + pass + except FileNotFoundError: + # Ignore the exception which probably has occured + # from psutil, due to a non-existent PID (see #95). + # The exception should have been translated, but + # there appears to be a bug of psutil. It is unlikely + # FileNotFoundError is thrown in different situations. + pass + + # TODO: Do not block if full process info is not requested + time.sleep(0.1) + for process in processes: + pid = process['pid'] + cache_process: psutil.Process = GPUStatCollection.global_processes[pid] + process['cpu_percent'] = safepcall(cache_process.cpu_percent, 0) + + index = N.nvmlDeviceGetIndex(handle) + + # GPU Info. + # We use the same key/spec as per `nvidia-smi --query-help-gpu` + gpu_info = { + 'index': index, + 'uuid': uuid, + 'name': name, + 'temperature.gpu': temperature, + 'fan.speed': fan_speed, + 'utilization.gpu': utilization.gpu if utilization else None, + 'utilization.enc': + utilization_enc[0] if utilization_enc else None, + 'utilization.dec': + utilization_dec[0] if utilization_dec else None, + 'power.draw': power // 1000 if power is not None else None, + 'enforced.power.limit': power_limit // 1000 + if power_limit is not None else None, + # Convert bytes into MBytes + 'memory.used': memory.used // MB if memory else None, + 'memory.total': memory.total // MB if memory else None, + 'processes': processes, + } + GPUStatCollection.clean_processes() + return gpu_info + + # 1. get the list of gpu and status + gpu_list = [] + device_count = N.nvmlDeviceGetCount() + + if id is None: + gpus_to_query = range(device_count) + elif isinstance(id, str): + gpus_to_query = [int(i) for i in id.split(',')] + elif isinstance(id, Sequence): + gpus_to_query = [int(i) for i in id] + else: + raise TypeError(f"Unknown id: {id}") + + for index in gpus_to_query: + try: + handle = N.nvmlDeviceGetHandleByIndex(index) + gpu_info = get_gpu_info(handle) + gpu_stat = GPUStat(gpu_info) + except N.NVMLError_Unknown as e: + gpu_stat = InvalidGPU(index, "((Unknown Error))", e) + except N.NVMLError_GpuIsLost as e: + gpu_stat = InvalidGPU(index, "((GPU is lost))", e) + + if isinstance(gpu_stat, InvalidGPU): + log.add_exception("GPU %d" % index, gpu_stat.exception) + gpu_list.append(gpu_stat) + + # 2. additional info (driver version, etc). + try: + driver_version = _decode(N.nvmlSystemGetDriverVersion()) + except N.NVMLError as e: + log.add_exception("driver_version", e) + driver_version = None # N/A + + if debug: + log.report_summary() + + N.nvmlShutdown() + return GPUStatCollection(gpu_list, driver_version=driver_version) + + def __len__(self): + return len(self.gpus) + + def __iter__(self): + return iter(self.gpus) + + def __getitem__(self, index): + return self.gpus[index] + + def __repr__(self): + s = 'GPUStatCollection(host=%s, [\n' % self.hostname + s += '\n'.join(' ' + str(g) for g in self.gpus) + s += '\n])' + return s + + # --- Printing Functions --- + + def print_formatted(self, fp=sys.stdout, *, + force_color=False, no_color=False, + show_cmd=False, show_full_cmd=False, show_user=False, + show_pid=False, show_fan_speed=None, + show_codec="", show_power=None, + gpuname_width=None, show_header=True, + no_processes=False, + eol_char=os.linesep, + ): + # ANSI color configuration + if force_color and no_color: + raise ValueError("--color and --no_color can't" + " be used at the same time") + + if force_color: + TERM = os.getenv('TERM') or 'xterm-256color' + t_color = Terminal(kind=TERM, force_styling=True) + + # workaround of issue #32 (watch doesn't recognize sgr0 characters) + t_color._normal = u'\x1b[0;10m' + elif no_color: + t_color = Terminal(force_styling=None) + else: + t_color = Terminal() # auto, depending on isatty + + # appearance settings + if gpuname_width is None: + gpuname_width = max([len(g.entry['name']) for g in self] + [0]) + + # header + if show_header: + if IS_WINDOWS: + # no localization is available; just use a reasonable default + # same as str(timestr) but without ms + timestr = self.query_time.strftime('%Y-%m-%d %H:%M:%S') + else: + time_format = locale.nl_langinfo(locale.D_T_FMT) + timestr = self.query_time.strftime(time_format) + header_template = '{t.bold_white}{hostname:{width}}{t.normal} ' + header_template += '{timestr} ' + header_template += '{t.bold_black}{driver_version}{t.normal}' + + header_msg = header_template.format( + hostname=self.hostname, + width=(gpuname_width or DEFAULT_GPUNAME_WIDTH) + 3, # len("[?]") + timestr=timestr, + driver_version=self.driver_version, + t=t_color, + ) + + fp.write(header_msg.strip()) + fp.write(eol_char) + + # body + for g in self: + g.print_to(fp, + show_cmd=show_cmd, + show_full_cmd=show_full_cmd, + no_processes=no_processes, + show_user=show_user, + show_pid=show_pid, + show_fan_speed=show_fan_speed, + show_codec=show_codec, + show_power=show_power, + gpuname_width=gpuname_width, + eol_char=eol_char, + term=t_color) + fp.write(eol_char) + + if len(self.gpus) == 0: + print(t_color.yellow("(No GPUs are available)")) + + fp.flush() + + def jsonify(self): + return { + 'hostname': self.hostname, + 'driver_version': self.driver_version, + 'query_time': self.query_time, + "gpus": [g.jsonify() for g in self] + } + + def print_json(self, fp=sys.stdout): + def date_handler(obj): + if hasattr(obj, 'isoformat'): + return obj.isoformat() + else: + raise TypeError(type(obj)) + + o = self.jsonify() + json.dump(o, fp, indent=4, separators=(',', ': '), + default=date_handler) + fp.write(os.linesep) + fp.flush() + + +def new_query() -> GPUStatCollection: + ''' + Obtain a new GPUStatCollection instance by querying nvidia-smi + to get the list of GPUs and running process information. + ''' + return GPUStatCollection.new_query() + + +def gpu_count() -> int: + '''Return the number of available GPUs in the system.''' + try: + N.nvmlInit() + return N.nvmlDeviceGetCount() + except N.NVMLError: + return 0 # fallback + finally: + try: + N.nvmlShutdown() + except N.NVMLError: + pass + + +def is_available() -> bool: + '''Return True if the NVML library and GPU devices are available.''' + return gpu_count() > 0 diff --git a/vllm/lib/python3.10/site-packages/gpustat/nvml.py b/vllm/lib/python3.10/site-packages/gpustat/nvml.py new file mode 100644 index 0000000000000000000000000000000000000000..fcf684cec71da144dd73e09b3e1782227b667f7e --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/nvml.py @@ -0,0 +1,160 @@ +"""Imports pynvml with sanity checks and custom patches.""" + +import warnings +import functools +import os +import sys +import textwrap + +# If this environment variable is set, we will bypass pynvml version validation +# so that legacy pynvml (nvidia-ml-py3) can be used. This would be useful +# in a case where there are conflicts on pynvml dependencies. +# However, beware that pynvml might produce wrong results (see #107). +ALLOW_LEGACY_PYNVML = os.getenv("ALLOW_LEGACY_PYNVML", "") +ALLOW_LEGACY_PYNVML = ALLOW_LEGACY_PYNVML.lower() not in ('false', '0', '') + + +try: + # Check pynvml version: we require 11.450.129 or newer. + # https://github.com/wookayin/gpustat/pull/107 + import pynvml + if not ( + # Requires nvidia-ml-py >= 11.460.79 + hasattr(pynvml, 'NVML_BRAND_NVIDIA_RTX') or + # Requires nvidia-ml-py >= 11.450.129, < 11.510.69 + hasattr(pynvml, 'nvmlDeviceGetComputeRunningProcesses_v2') + ) and not ALLOW_LEGACY_PYNVML: + raise ImportError("pynvml library is outdated.") + + if not hasattr(pynvml, '_nvmlGetFunctionPointer'): + # Unofficial pynvml from @gpuopenanalytics/pynvml, see #153 + import pynvml.nvml as pynvml + +except (ImportError, SyntaxError, RuntimeError) as e: + _pynvml = sys.modules.get('pynvml', None) + + raise ImportError(textwrap.dedent( + """\ + pynvml is missing or an outdated version is installed. + + We require nvidia-ml-py>=11.450.129, and the official NVIDIA python bindings + should be used; neither nvidia-ml-py3 nor gpuopenanalytics/pynvml. + For more details, please refer to: https://github.com/wookayin/gpustat/issues/107 + + The root cause: """ + str(e) + + """ + + Your pynvml installation: """ + repr(_pynvml) + + """ + + ----------------------------------------------------------- + Please reinstall `gpustat`: + + $ pip install --force-reinstall gpustat + + If it still does not fix the problem, please uninstall pynvml packages and reinstall nvidia-ml-py manually: + + $ pip uninstall nvidia-ml-py3 pynvml + $ pip install --force-reinstall --ignore-installed 'nvidia-ml-py' + """)) from e + + +# Monkey-patch nvml due to breaking changes in pynvml. +# See #107, #141, and test_gpustat.py for more details. + +_original_nvmlGetFunctionPointer = pynvml._nvmlGetFunctionPointer +_original_nvmlDeviceGetMemoryInfo = pynvml.nvmlDeviceGetMemoryInfo + + +class pynvml_monkeypatch: + + @staticmethod # Note: must be defined as a staticmethod to allow mocking. + def original_nvmlGetFunctionPointer(name): + return _original_nvmlGetFunctionPointer(name) + + FUNCTION_FALLBACKS = { + # for pynvml._nvmlGetFunctionPointer + 'nvmlDeviceGetComputeRunningProcesses_v3': 'nvmlDeviceGetComputeRunningProcesses_v2', + 'nvmlDeviceGetGraphicsRunningProcesses_v3': 'nvmlDeviceGetGraphicsRunningProcesses_v2', + } + + @staticmethod + @functools.wraps(pynvml._nvmlGetFunctionPointer) + def _nvmlGetFunctionPointer(name): + """Our monkey-patched pynvml._nvmlGetFunctionPointer(). + + See also: + test_gpustat::NvidiaDriverMock for test scenarios. See #107. + """ + M = pynvml_monkeypatch + + try: + ret = M.original_nvmlGetFunctionPointer(name) + return ret + except pynvml.NVMLError_FunctionNotFound: # type: ignore + if name in M.FUNCTION_FALLBACKS: + # Lack of ...Processes_v3 APIs happens for + # OLD drivers < 510.39.01 && pynvml >= 11.510, where + # we fallback to v2 APIs. (see #107 for more details) + + ret = M.original_nvmlGetFunctionPointer( + M.FUNCTION_FALLBACKS[name] + ) + # populate the cache, so this handler won't get executed again + pynvml._nvmlGetFunctionPointer_cache[name] = ret + + else: + # Unknown case, cannot handle. re-raise again + raise + + return ret + + @staticmethod # Note: must be defined as a staticmethod to allow mocking. + def original_nvmlDeviceGetMemoryInfo(*args, **kwargs): + return _original_nvmlDeviceGetMemoryInfo(*args, **kwargs) + + has_memoryinfo_v2 = None + + @staticmethod + @functools.wraps(pynvml.nvmlDeviceGetMemoryInfo) + def nvmlDeviceGetMemoryInfo(handle): + """A patched version of nvmlDeviceGetMemoryInfo. + + This tries `version=N.nvmlMemory_v2` if the nvmlDeviceGetMemoryInfo_v2 + function is available (for driver >= 515), or fallback to the legacy + v1 API for (driver < 515) to yield a correct result. See #141. + """ + M = pynvml_monkeypatch + + if M.has_memoryinfo_v2 is None: + try: + pynvml._nvmlGetFunctionPointer("nvmlDeviceGetMemoryInfo_v2") + M.has_memoryinfo_v2 = True + except pynvml.NVMLError_FunctionNotFound: # type: ignore + M.has_memoryinfo_v2 = False + + if hasattr(pynvml, 'nvmlMemory_v2'): # pynvml >= 11.510.69 + try: + memory = M.original_nvmlDeviceGetMemoryInfo( + handle, version=pynvml.nvmlMemory_v2) + except pynvml.NVMLError_FunctionNotFound: # type: ignore + # pynvml >= 11.510 but driver is old (<515.39) + memory = M.original_nvmlDeviceGetMemoryInfo(handle) + else: + if M.has_memoryinfo_v2: + warnings.warn( + "Your NVIDIA driver requires a compatible version of " + "pynvml (>= 11.510.69) installed to display the correct " + "memory usage information (See #141 for more details). " + "Please try `pip install --upgrade nvidia-ml-py`.", + category=UserWarning) + memory = M.original_nvmlDeviceGetMemoryInfo(handle) + + return memory + + +setattr(pynvml, '_nvmlGetFunctionPointer', pynvml_monkeypatch._nvmlGetFunctionPointer) +setattr(pynvml, 'nvmlDeviceGetMemoryInfo', pynvml_monkeypatch.nvmlDeviceGetMemoryInfo) + + +__all__ = ['pynvml'] diff --git a/vllm/lib/python3.10/site-packages/gpustat/test_gpustat.py b/vllm/lib/python3.10/site-packages/gpustat/test_gpustat.py new file mode 100644 index 0000000000000000000000000000000000000000..d9be9c7af9458222d0a70e28377148f3a00df8ba --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/test_gpustat.py @@ -0,0 +1,703 @@ +""" +Unit or integration tests for gpustat +""" +# flake8: ignore=E501 + +import ctypes +import os +import shlex +import sys +import types +from collections import namedtuple +from io import StringIO +from typing import Any + +import psutil +import pytest +from mockito import ANY, mock, unstub, when, when2 + +import gpustat +from gpustat.nvml import pynvml, pynvml_monkeypatch + +MB = 1024 * 1024 + + +def remove_ansi_codes(s): + import re + s = re.compile(r'\x1b[^m]*m').sub('', s) + s = re.compile(r'\x0f').sub('', s) + return s + +# ----------------------------------------------------------------------------- + +mock_gpu_handles = [types.SimpleNamespace(value='mock-handle-%d' % i, index=i) + for i in range(3)] + +def _configure_mock(N=pynvml, + _scenario_nonexistent_pid=False, # GH-95 + _scenario_failing_one_gpu=None, # GH-125, GH-81 + ): + """Define mock behaviour for pynvml and psutil.{Process,virtual_memory}.""" + + # without following patch, unhashable NVMLError makes unit test crash + N.NVMLError.__hash__ = lambda _: 0 + assert issubclass(N.NVMLError, BaseException) + + unstub(N) # reset all the stubs + + when(N).nvmlInit().thenReturn() + when(N).nvmlShutdown().thenReturn() + when(N).nvmlSystemGetDriverVersion().thenReturn('415.27.mock') + + when(N)._nvmlGetFunctionPointer(...).thenCallOriginalImplementation() + + NUM_GPUS = 3 + when(N).nvmlDeviceGetCount().thenReturn(NUM_GPUS) + + def _return_or_raise(v): + """Return a callable for thenAnswer() to let exceptions re-raised.""" + def _callable(*args, **kwargs): + del args, kwargs + if isinstance(v, Exception): + raise v + return v + return _callable + + for i in range(NUM_GPUS): + handle = mock_gpu_handles[i] + if _scenario_failing_one_gpu and i == 2: # see #81, #125 + assert (_scenario_failing_one_gpu is N.NVMLError_Unknown or + _scenario_failing_one_gpu is N.NVMLError_GpuIsLost) + handle = _scenario_failing_one_gpu() # see 81 + + when(N).nvmlDeviceGetHandleByIndex(i)\ + .thenAnswer(_return_or_raise(handle)) + when(N).nvmlDeviceGetIndex(handle)\ + .thenReturn(i) + when(N).nvmlDeviceGetName(handle)\ + .thenReturn({ + 0: 'GeForce GTX TITAN 0', + 1: 'GeForce GTX TITAN 1', + 2: 'GeForce RTX 2', + }[i].encode()) + when(N).nvmlDeviceGetUUID(handle)\ + .thenReturn({ + 0: b'GPU-10fb0fbd-2696-43f3-467f-d280d906a107', + 1: b'GPU-d1df4664-bb44-189c-7ad0-ab86c8cb30e2', + 2: b'GPU-50205d95-57b6-f541-2bcb-86c09afed564', + }[i]) + + when(N).nvmlDeviceGetTemperature(handle, N.NVML_TEMPERATURE_GPU)\ + .thenReturn([80, 36, 71][i]) + when(N).nvmlDeviceGetFanSpeed(handle)\ + .thenReturn([16, 53, 100][i]) + when(N).nvmlDeviceGetPowerUsage(handle)\ + .thenAnswer(_return_or_raise({ + 0: 125000, 1: N.NVMLError_NotSupported(), 2: 250000 + }[i])) + when(N).nvmlDeviceGetEnforcedPowerLimit(handle)\ + .thenAnswer(_return_or_raise({ + 0: 250000, 1: 250000, 2: N.NVMLError_NotSupported() + }[i])) + + # see also: NvidiaDriverMock + mock_memory_t = namedtuple("Memory_t", ['total', 'used']) # c_nvmlMemory_t + when(N).nvmlDeviceGetMemoryInfo(handle)\ + .thenAnswer(_return_or_raise({ + 0: mock_memory_t(total=12883853312, used=8000*MB), + 1: mock_memory_t(total=12781551616, used=9000*MB), + 2: mock_memory_t(total=12781551616, used=0), + }[i])) + # this mock function assumes <510.39 behavior (#141) + when(N, strict=False)\ + .nvmlDeviceGetMemoryInfo(handle, version=ANY())\ + .thenRaise(N.NVMLError_FunctionNotFound) + + mock_utilization_t = namedtuple("Utilization_t", ['gpu', 'memory']) + when(N).nvmlDeviceGetUtilizationRates(handle)\ + .thenAnswer(_return_or_raise({ + 0: mock_utilization_t(gpu=76, memory=0), + 1: mock_utilization_t(gpu=0, memory=0), + 2: N.NVMLError_NotSupported(), # Not Supported + }[i])) + + when(N).nvmlDeviceGetEncoderUtilization(handle)\ + .thenAnswer(_return_or_raise({ + 0: [88, 167000], # [value, sample_rate] + 1: [0, 167000], # [value, sample_rate] + 2: N.NVMLError_NotSupported(), # Not Supported + }[i])) + when(N).nvmlDeviceGetDecoderUtilization(handle)\ + .thenAnswer(_return_or_raise({ + 0: [67, 167000], # [value, sample_rate] + 1: [0, 167000], # [value, sample_rate] + 2: N.NVMLError_NotSupported(), # Not Supported + }[i])) + + # running process information: a bit annoying... + mock_process_t = namedtuple("Process_t", ['pid', 'usedGpuMemory']) + + if _scenario_nonexistent_pid: + mock_processes_gpu2_erratic = [ + mock_process_t(99999, 9999*MB), + mock_process_t(99995, 9995*MB), # see issue #95 + ] + else: + mock_processes_gpu2_erratic = N.NVMLError_NotSupported() + + # see NvidiaDriverMock as well + when(N).nvmlDeviceGetComputeRunningProcesses(handle)\ + .thenAnswer(_return_or_raise({ + 0: [mock_process_t(48448, 4000*MB), mock_process_t(153223, 4000*MB)], + 1: [mock_process_t(192453, 3000*MB), mock_process_t(194826, 6000*MB)], + 2: mock_processes_gpu2_erratic, # Not Supported or non-existent + }[i])) + + when(N).nvmlDeviceGetGraphicsRunningProcesses(handle)\ + .thenAnswer(_return_or_raise({ + 0: [mock_process_t(48448, 4000*MB)], + 1: [], + 2: N.NVMLError_NotSupported(), + }[i])) + + # for psutil + mock_pid_map = { # mock/stub information for psutil... + 48448: ('user1', 'python', 85.25, 3.1415), + 154213: ('user1', 'caffe', 16.89, 100.00), + 38310: ('user3', 'python', 26.23, 99.9653), + 153223: ('user2', 'python', 15.25, 0.0000), + 194826: ('user3', 'caffe', 0.0, 12.5236), + 192453: ('user1', 'torch', 123.2, 0.7312), + } + assert 99999 not in mock_pid_map, 'scenario_nonexistent_pid' + assert 99995 not in mock_pid_map, 'scenario_nonexistent_pid (#95)' + + def _MockedProcess(pid): + if pid not in mock_pid_map: + if pid == 99995: + # simulate a bug reported in #95 + raise FileNotFoundError("/proc/99995/stat") + else: + # for a process that does not exist, NoSuchProcess is the + # type of exceptions supposed to be raised by psutil + raise psutil.NoSuchProcess(pid=pid) + username, cmdline, cpuutil, memutil = mock_pid_map[pid] + p: Any = mock(strict=True) # psutil.Process + p.username = lambda: username + p.cmdline = lambda: [cmdline] + p.cpu_percent = lambda: cpuutil + p.memory_percent = lambda: memutil + p.pid = pid + return p + + when(psutil).Process(...)\ + .thenAnswer(_MockedProcess) + when(psutil).virtual_memory()\ + .thenReturn(mock_memory_t(total=8589934592, used=0)) + + +MOCK_EXPECTED_OUTPUT_DEFAULT = os.linesep.join("""\ +[0] GeForce GTX TITAN 0 | 80°C, 76 % | 8000 / 12287 MB | user1(4000M) user2(4000M) +[1] GeForce GTX TITAN 1 | 36°C, 0 % | 9000 / 12189 MB | user1(3000M) user3(6000M) +[2] GeForce RTX 2 | 71°C, ?? % | 0 / 12189 MB | (Not Supported) +""".splitlines()) # noqa: E501 + +MOCK_EXPECTED_OUTPUT_FULL = os.linesep.join("""\ +[0] GeForce GTX TITAN 0 | 80°C, 16 %, 76 % (E: 88 % D: 67 %), 125 / 250 W | 8000 / 12287 MB | user1:python/48448(4000M) user2:python/153223(4000M) +[1] GeForce GTX TITAN 1 | 36°C, 53 %, 0 % (E: 0 % D: 0 %), ?? / 250 W | 9000 / 12189 MB | user1:torch/192453(3000M) user3:caffe/194826(6000M) +[2] GeForce RTX 2 | 71°C, 100 %, ?? % (E: ?? % D: ?? %), 250 / ?? W | 0 / 12189 MB | (Not Supported) +""".splitlines()) # noqa: E501 + +MOCK_EXPECTED_OUTPUT_FULL_PROCESS = os.linesep.join("""\ +[0] GeForce GTX TITAN 0 | 80°C, 16 %, 76 % (E: 88 % D: 67 %), 125 / 250 W | 8000 / 12287 MB | user1:python/48448(4000M) user2:python/153223(4000M) + ├─ 48448 ( 85%, 257MB): python + └─ 153223 ( 15%, 0B): python +[1] GeForce GTX TITAN 1 | 36°C, 53 %, 0 % (E: 0 % D: 0 %), ?? / 250 W | 9000 / 12189 MB | user1:torch/192453(3000M) user3:caffe/194826(6000M) + ├─ 192453 ( 123%, 59MB): torch + └─ 194826 ( 0%, 1025MB): caffe +[2] GeForce RTX 2 | 71°C, 100 %, ?? % (E: ?? % D: ?? %), 250 / ?? W | 0 / 12189 MB | (Not Supported) +""".splitlines()) # noqa: E501 + +MOCK_EXPECTED_OUTPUT_NO_PROCESSES = os.linesep.join("""\ +[0] GeForce GTX TITAN 0 | 80°C, 76 % | 8000 / 12287 MB +[1] GeForce GTX TITAN 1 | 36°C, 0 % | 9000 / 12189 MB +[2] GeForce RTX 2 | 71°C, ?? % | 0 / 12189 MB +""".splitlines()) # noqa: E501 + +# ----------------------------------------------------------------------------- + + +@pytest.fixture +def scenario_basic(): + _configure_mock() + + +@pytest.fixture +def scenario_nonexistent_pid(): + _configure_mock(_scenario_nonexistent_pid=True) + + +@pytest.fixture +def scenario_failing_one_gpu(request: pytest.FixtureRequest): + # request.param should be either NVMLError_Unknown or NVMLError_GpuIsLost + _configure_mock(_scenario_failing_one_gpu=request.param) + return dict(expected_message={ + pynvml.NVMLError_GpuIsLost: 'GPU is lost', + pynvml.NVMLError_Unknown: 'Unknown Error', + }[request.param]) + + +@pytest.fixture +def nvidia_driver_version(request: pytest.FixtureRequest): + """See NvidiaDriverMock.""" + + nvidia_mock: NvidiaDriverMock = request.param + nvidia_mock(pynvml) + + if nvidia_mock.name.startswith('430'): + # AssertionError: gpustat will print (Not Supported) in this case + request.node.add_marker(pytest.mark.xfail( + reason="nvmlDeviceGetComputeRunningProcesses_v2 does not exist")) + + yield nvidia_mock + + +class NvidiaDriverMock: + """Simulate the behavior of nvml's low-level functions according to a + specific nvidia driver versions, with backward compatibility in concern. + In all the scenarios, gpustat should work well with a compatible version + of pynvml installed. + + For what has changed on the nvidia driver side (a non-exhaustive list), see + https://github.com/NVIDIA/nvidia-settings/blame/main/src/nvml.h + https://github.com/NVIDIA/nvidia-settings/blame/main/src/libXNVCtrlAttributes/NvCtrlAttributesPrivate.h + + Noteworthy changes of nvml driviers: + 450.66: nvmlDeviceGetComputeRunningProcesses_v2 + 510.39.01: nvmlDeviceGetComputeRunningProcesses_v3 (_v2 removed) + nvmlDeviceGetMemoryInfo_v2 + + Relevant github issues: + #107: nvmlDeviceGetComputeRunningProcesses_v2 added + #141: nvmlDeviceGetMemoryInfo (v1) broken for 510.39.01+ + """ + INSTANCES = [] + + def __init__(self, name, **kwargs): + self.name = name + self.feat = kwargs + + def __call__(self, N): + self.mock_processes(N) + self.mock_memoryinfo(N) + + def mock_processes(self, N): + when(N).nvmlDeviceGetComputeRunningProcesses(...).thenCallOriginalImplementation() + when(N).nvmlDeviceGetGraphicsRunningProcesses(...).thenCallOriginalImplementation() + when(N).nvmlSystemGetDriverVersion().thenReturn(self.name) + + def process_t(pid, usedGpuMemory): + return pynvml.c_nvmlProcessInfo_t( + pid=ctypes.c_uint(pid), + usedGpuMemory=ctypes.c_ulonglong(usedGpuMemory), + ) + + # more low-level mocking for + # nvmlDeviceGetComputeRunningProcesses_{v2, v3} & c_nvmlProcessInfo_t + def _nvmlDeviceGetComputeRunningProcesses_v2(handle, c_count, c_procs): + # handle: SimpleNamespace (see _configure_mock) + if c_count._obj.value == 0: + return pynvml.NVML_ERROR_INSUFFICIENT_SIZE + else: + c_count._obj.value = 2 + if handle.index == 0: + c = process_t(pid=48448, usedGpuMemory=4000*MB); c_procs[0] = c + c = process_t(pid=153223, usedGpuMemory=4000*MB); c_procs[1] = c + elif handle.index == 1: + c = process_t(pid=192453, usedGpuMemory=3000*MB); c_procs[0] = c + c = process_t(pid=194826, usedGpuMemory=6000*MB); c_procs[1] = c + else: + return pynvml.NVML_ERROR_NOT_SUPPORTED + return pynvml.NVML_SUCCESS + + def _nvmlDeviceGetGraphicsRunningProcesses_v2(handle, c_count, c_procs): + if c_count._obj.value == 0: + return pynvml.NVML_ERROR_INSUFFICIENT_SIZE + else: + if handle.index == 0: + c_count._obj.value = 1 + c = process_t(pid=48448, usedGpuMemory=4000*MB); c_procs[0] = c + elif handle.index == 1: + c_count._obj.value = 0 + else: + return pynvml.NVML_ERROR_NOT_SUPPORTED + return pynvml.NVML_SUCCESS + + # Note: N._nvmlGetFunctionPointer might have been monkey-patched, + # so this mock should decorate the underlying, unwrapped raw function, + # NOT a monkey-patched version of pynvml._nvmlGetFunctionPointer. + for v in [1, 2, 3]: + _v = f'_v{v}' if v != 1 else '' # backward compatible v3 -> v2 + stub = when2(pynvml_monkeypatch.original_nvmlGetFunctionPointer, + f'nvmlDeviceGetComputeRunningProcesses{_v}') + if v <= self.nvmlDeviceGetComputeRunningProcesses_v: + stub.thenReturn(_nvmlDeviceGetComputeRunningProcesses_v2) + else: + stub.thenRaise(pynvml.NVMLError(pynvml.NVML_ERROR_FUNCTION_NOT_FOUND)) + + stub = when2(pynvml_monkeypatch.original_nvmlGetFunctionPointer, + f'nvmlDeviceGetGraphicsRunningProcesses{_v}') + if v <= self.nvmlDeviceGetComputeRunningProcesses_v: + stub.thenReturn(_nvmlDeviceGetGraphicsRunningProcesses_v2) + else: + stub.thenRaise(pynvml.NVMLError(pynvml.NVML_ERROR_FUNCTION_NOT_FOUND)) + + def mock_memoryinfo(self, N): + nvmlMemory_v2 = 0x02000028 + if self.nvmlDeviceGetMemoryInfo_v == 1: + mock_memory_t = namedtuple( + "c_nvmlMemory_t", + ['total', 'used'], + ) + elif self.nvmlDeviceGetMemoryInfo_v == 2: + mock_memory_t = namedtuple( + "c_nvmlMemory_v2_t", + ['version', 'total', 'reserved', 'free', 'used'], + ) + mock_memory_t.__new__.__defaults__ = (nvmlMemory_v2, 0, 0, 0, 0) + else: + raise NotImplementedError + + # simulates drivers >= 510.39, where memoryinfo v2 is introduced + if self.nvmlDeviceGetMemoryInfo_v == 2: + for handle in mock_gpu_handles: + # a correct API requires version=... parameter + # this assumes nvidia driver is also recent enough. + when(pynvml_monkeypatch, strict=False)\ + .original_nvmlDeviceGetMemoryInfo(handle, version=nvmlMemory_v2)\ + .thenReturn({ + 0: mock_memory_t(total=12883853312, used=8000*MB), + 1: mock_memory_t(total=12781551616, used=9000*MB), + 2: mock_memory_t(total=12781551616, used=0), + }[handle.index]) + # simulate #141: without the v2 parameter, gives wrong result + when(pynvml_monkeypatch)\ + .original_nvmlDeviceGetMemoryInfo(handle)\ + .thenReturn({ + 0: mock_memory_t(total=12883853312, used=8099*MB), + 1: mock_memory_t(total=12781551616, used=9099*MB), + 2: mock_memory_t(total=12781551616, used=99*MB), + }[handle.index]) + + else: # old drivers < 510.39 + for handle in mock_gpu_handles: + # when pynvml>=11.510, v2 API can be called but can't be used + when(N, strict=False)\ + .nvmlDeviceGetMemoryInfo(handle, version=ANY())\ + .thenRaise(N.NVMLError_FunctionNotFound) + # The v1 API will give a correct result for the v1 API + when(N).nvmlDeviceGetMemoryInfo(handle)\ + .thenReturn({ + 0: mock_memory_t(total=12883853312, used=8000*MB), + 1: mock_memory_t(total=12781551616, used=9000*MB), + 2: mock_memory_t(total=12781551616, used=0), + }[handle.index]) + + def __getattr__(self, k): + return self.feat[k] + + @property + def __name__(self): + return self.name + + def __repr__(self): + return self.__name__ + + +NvidiaDriverMock.INSTANCES = [ + NvidiaDriverMock('430.xx.xx', + nvmlDeviceGetComputeRunningProcesses_v=1, + nvmlDeviceGetMemoryInfo_v=1, + ), + NvidiaDriverMock('450.66', + nvmlDeviceGetComputeRunningProcesses_v=2, + nvmlDeviceGetMemoryInfo_v=1, + ), + NvidiaDriverMock('510.39.01', + nvmlDeviceGetComputeRunningProcesses_v=3, + nvmlDeviceGetMemoryInfo_v=2, + ), +] + + +# ----------------------------------------------------------------------------- + + +class TestGPUStat(object): + """A pytest class suite for gpustat.""" + + def setup_method(self): + print("") + self.maxDiff = 4096 + + def teardown_method(self): + unstub() + + @staticmethod + def capture_output(*args): + f = StringIO() + import contextlib + + with contextlib.redirect_stdout(f): # requires python 3.4+ + try: + gpustat.main(*args) + except SystemExit as e: + if e.code != 0: + raise AssertionError( + "Argparse failed (see above error message)") + return f.getvalue() + + # ----------------------------------------------------------------------- + + @pytest.mark.parametrize("nvidia_driver_version", + NvidiaDriverMock.INSTANCES, indirect=True) + def test_new_query_mocked_basic(self, scenario_basic, nvidia_driver_version): + """A basic functionality test, in a case where everything is normal.""" + + gpustats = gpustat.new_query() + fp = StringIO() + gpustats.print_formatted( + fp=fp, no_color=False, show_user=True, + show_cmd=True, show_full_cmd=True, show_pid=True, + show_fan_speed=True, show_codec="enc,dec", show_power=True, + ) + + result = fp.getvalue() + print(result) + + unescaped = remove_ansi_codes(result) + # remove first line (header) + unescaped = os.linesep.join(unescaped.splitlines()[1:]) + + assert unescaped == MOCK_EXPECTED_OUTPUT_FULL_PROCESS + + # verify gpustat results (not exhaustive yet) + assert gpustats.driver_version == nvidia_driver_version.name + g: gpustat.GPUStat = gpustats.gpus[0] + assert g.memory_used == 8000 + assert g.power_draw == 125 + assert g.utilization == 76 + assert g.processes and g.processes[0]['pid'] == 48448 + + def test_new_query_mocked_nonexistent_pid(self, scenario_nonexistent_pid): + """ + Test a case where nvidia query returns non-existent pids (see #16, #18) + for GPU index 2. + """ + fp = StringIO() + + gpustats = gpustat.new_query() + gpustats.print_formatted(fp=fp) + + ret = fp.getvalue() + print(ret) + + # gpu 2: should ignore process id + line = remove_ansi_codes(ret).split('\n')[3] + assert '[2] GeForce RTX 2' in line, str(line) + assert '99999' not in line + assert '(Not Supported)' not in line + + @pytest.mark.parametrize("scenario_failing_one_gpu", [ + pynvml.NVMLError_GpuIsLost, + pynvml.NVMLError_Unknown, + ], indirect=True) + def test_new_query_mocked_failing_one_gpu(self, scenario_failing_one_gpu): + """Test a case where one GPU is failing (see #125).""" + fp = StringIO() + gpustats = gpustat.new_query() + gpustats.print_formatted(fp=fp, show_header=False) + ret = fp.getvalue() + print(ret) + + lines = remove_ansi_codes(ret).split('\n') + message = scenario_failing_one_gpu['expected_message'] + + # gpu 2: failing due to unknown error + line = lines[2] + assert '[2] ((' + message + '))' in line, str(line) + assert '99999' not in line + assert '?°C, ? %' in line, str(line) + assert '? / ? MB' in line, str(line) + + # other gpus should be displayed normally + assert '[0] GeForce GTX TITAN 0' in lines[0] + assert '[1] GeForce GTX TITAN 1' in lines[1] + + def test_attributes_and_items(self, scenario_basic): + """Test whether each property of `GPUStat` instance is well-defined.""" + + g = gpustat.new_query()[1] # includes N/A + print("(keys) : %s" % str(g.keys())) + print(g) + + assert g['name'] == g.entry['name'] + assert g['uuid'] == g.uuid + + with pytest.raises(KeyError): + g['unknown_key'] + + print("uuid : %s" % g.uuid) + print("name : %s" % g.name) + print("memory : used %d total %d avail %d" % ( + g.memory_used, g.memory_total, g.memory_available)) + print("temperature : %d" % (g.temperature)) + print("utilization : %s" % (g.utilization)) + print("utilization_enc : %s" % (g.utilization_enc)) + print("utilization_dec : %s" % (g.utilization_dec)) + + def test_main(self, scenario_basic): + """Test whether gpustat.main() works well. + The behavior is mocked exactly as in test_new_query_mocked(). + """ + sys.argv = ['gpustat'] + gpustat.main() + + def test_args_commandline(self, scenario_basic): + """Tests the end gpustat CLI.""" + capture_output = self.capture_output + + def _remove_ansi_codes_and_header_line(s): + unescaped = remove_ansi_codes(s) + # remove first line (header) + unescaped = os.linesep.join(unescaped.splitlines()[1:]) + return unescaped + + s = capture_output('gpustat', ) + assert _remove_ansi_codes_and_header_line(s) == MOCK_EXPECTED_OUTPUT_DEFAULT + + s = capture_output('gpustat', '--version') + assert s.startswith('gpustat ') + print(s) + + s = capture_output('gpustat', '--no-header') + assert "[0]" in s.splitlines()[0] + + s = capture_output('gpustat', '-a') # --show-all + assert _remove_ansi_codes_and_header_line(s) == MOCK_EXPECTED_OUTPUT_FULL + + s = capture_output('gpustat', '--color') + assert '\x0f' not in s, "Extra \\x0f found (see issue #32)" + assert _remove_ansi_codes_and_header_line(s) == MOCK_EXPECTED_OUTPUT_DEFAULT + + s = capture_output('gpustat', '--no-color') + unescaped = remove_ansi_codes(s) + assert s == unescaped # should have no ansi code + assert _remove_ansi_codes_and_header_line(s) == MOCK_EXPECTED_OUTPUT_DEFAULT + + s = capture_output('gpustat', '--no-processes') + assert _remove_ansi_codes_and_header_line(s) == MOCK_EXPECTED_OUTPUT_NO_PROCESSES + + s = capture_output('gpustat', '--id', '1,2') + assert _remove_ansi_codes_and_header_line(s) == \ + os.linesep.join(MOCK_EXPECTED_OUTPUT_DEFAULT.splitlines()[1:3]) + + def test_args_commandline_width(self, scenario_basic): + capture_output = self.capture_output + + # see MOCK_EXPECTED_OUTPUT_DEFAULT + assert len("GeForce GTX TITAN 0") == 19 + + s = capture_output('gpustat', '--gpuname-width', '25') + print("- Should have width=25") + print(s) + assert 'GeForce GTX TITAN 0 |' in remove_ansi_codes(s) + assert 'GeForce RTX 2 |' in remove_ansi_codes(s) + # ^012345 + # 19 + + # See #47 (since v1.0) + print("- Should have width=10 (with truncation)") + s = capture_output('gpustat', '--gpuname-width', '10') + print(s) + assert '…X TITAN 0 |' in remove_ansi_codes(s) + assert '…rce RTX 2 |' in remove_ansi_codes(s) + # 1234567890 + + print("- Should have width=1 (too short)") + s = capture_output('gpustat', '--gpuname-width', '1') + print(s) + assert '… |' in remove_ansi_codes(s) + + print("- Should have width=0: no name displayed.") + s = capture_output('gpustat', '--gpuname-width', '0') + print(s) + assert '[0] 80°C' in remove_ansi_codes(s) + + print("- Invalid inputs") + with pytest.raises(AssertionError, match="Argparse failed"): + s = capture_output('gpustat', '--gpuname-width', '-1') + with pytest.raises(AssertionError, match="Argparse failed"): + s = capture_output('gpustat', '--gpuname-width', 'None') + + def test_args_commandline_showoptions(self, scenario_basic): + """Tests gpustat CLI with a variety of --show-xxx options. """ + + capture_output = self.capture_output + print('') + + TEST_OPTS = [] + TEST_OPTS += ['-a', '-c', '-u', '-p', '-e', '-P', '-f'] + TEST_OPTS += [('-e', ''), ('-P', '')] + TEST_OPTS += [('-e', 'enc,dec'), '-Plimit,draw'] + TEST_OPTS += ['-cup', '-cpu', '-cufP'] # 'cpuePf' + + for opt in TEST_OPTS: + if isinstance(opt, str): + opt = [opt] + + print('\x1b[30m\x1b[43m', # black_on_yellow + '$ gpustat ' + ' '.join(shlex.quote(o) for o in opt), + '\x1b(B\x1b[m', sep='') + s = capture_output('gpustat', *opt) + + # TODO: Validate output without hardcoding expected outputs + print(s) + + # Finally, unknown args + with pytest.raises(AssertionError): + capture_output('gpustat', '--unrecognized-args-in-test') + + @pytest.mark.skipif(sys.platform == 'win32', reason="Do not run on Windows") + def test_no_TERM(self, scenario_basic, monkeypatch): + """--color should work well even when executed without TERM, + e.g. ssh localhost gpustat --color""" + monkeypatch.setenv("TERM", "") + + s = self.capture_output('gpustat', '--color', '--no-header').rstrip() + print(s) + assert remove_ansi_codes(s) == MOCK_EXPECTED_OUTPUT_DEFAULT, \ + "wrong gpustat output" + + assert '\x1b[36m' in s, "should contain cyan color code" + assert '\x0f' not in s, "Extra \\x0f found (see issue #32)" + + def test_json_mocked(self, scenario_basic): + gpustats = gpustat.new_query() + + fp = StringIO() + gpustats.print_json(fp=fp) + + import json + j = json.loads(fp.getvalue()) + + from pprint import pprint + pprint(j) + + assert j['driver_version'] == '415.27.mock' + assert j['hostname'] + assert j['gpus'] + + +if __name__ == '__main__': + pytest.main() diff --git a/vllm/lib/python3.10/site-packages/gpustat/util.py b/vllm/lib/python3.10/site-packages/gpustat/util.py new file mode 100644 index 0000000000000000000000000000000000000000..7335dca8bb4052b54283600acad486fd88f3107b --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/util.py @@ -0,0 +1,103 @@ +""" Miscellaneous Utilities. """ + +import collections +import os.path +import sys +import traceback +from typing import Callable, Tuple, Type, TypeVar, Union + +T = TypeVar('T') + + +def bytes2human(in_bytes): + '''Convert bytes (int) to a human-readable string.''' + suffixes = ('B', 'KB', 'MB', 'GB', 'TB', 'PB') + suffix = 0 + result = int(in_bytes) + while result > 9999 and suffix < len(suffixes): + result = result >> 10 + suffix += 1 + + if suffix >= len(suffixes): + suffix -= 1 + return "%d%s" % (result, suffixes[suffix]) + + +def prettify_commandline(cmdline, color_command='', color_text=''): + ''' + Prettify and colorize a full command-line (given as list of strings), + where command (basename) is highlighted in a different color. + ''' + # cmdline: Iterable[str] + if isinstance(cmdline, str): + return cmdline + assert cmdline + + command_p, command_b = os.path.split(cmdline[0]) + s = color_text + os.path.join(command_p, + color_command + command_b + color_text) + + if len(cmdline) > 1: + s += ' ' + s += ' '.join(cmdline[1:]) + return s + + +def shorten_left(text, width, placeholder="…"): + # text: str + if width is None: + return text + if text is None or len(text) <= width: + return text + if width < 0: + raise ValueError("width must be non-negative.") + if width == 0: + return "" + + if width == len(placeholder): + return placeholder + elif width - len(placeholder) < 0: + return placeholder[:width] + # raise ValueError("width is smaller than the length of placeholder.") + return placeholder + text[-(width - len(placeholder)):] + + +def safecall(fn: Callable[[], T], + *, + exc_types: Union[Type, Tuple[Type, ...]] = Exception, + error_value: T) -> T: + """A protected call that suppress certain types of exceptions.""" + try: + return fn() + except exc_types: # pylint: disable=broad-except + return error_value + + +class DebugHelper: + + def __init__(self): + self._reports = [] + + def add_exception(self, column, e=None): + msg = "> An error while retrieving `{column}`: {e}".format( + column=column, e=str(e)) + self._reports.append((msg, e)) + + def _write(self, msg): + sys.stderr.write(msg) + sys.stderr.write('\n') + + def report_summary(self, concise=True): + _seen_messages = collections.defaultdict(int) + for msg, e in self._reports: + if msg not in _seen_messages or not concise: + self._write(msg) + self._write(''.join( + traceback.format_exception(None, e, e.__traceback__))) + _seen_messages[msg] += 1 + + if concise: + for msg, value in _seen_messages.items(): + self._write("{msg} -> Total {value} occurrences.".format( + msg=msg, value=value)) + self._write('') diff --git a/vllm/lib/python3.10/site-packages/gpustat/util_test.py b/vllm/lib/python3.10/site-packages/gpustat/util_test.py new file mode 100644 index 0000000000000000000000000000000000000000..cd18d39db2779c7cd2b0f00a77c0b9df74dc51ca --- /dev/null +++ b/vllm/lib/python3.10/site-packages/gpustat/util_test.py @@ -0,0 +1,29 @@ +import sys +import pytest + +from gpustat import util + + +def test_safecall(): + + def _success(): + return 42 + + def _error(): + raise FileNotFoundError("oops") + + assert util.safecall(_success, error_value=None) == 42 + assert util.safecall(_error, error_value=-1) == -1 + + with pytest.raises(FileNotFoundError): + # not catched because exc_types does not match + assert util.safecall(_error, exc_types=ValueError, error_value=-1) + + assert util.safecall(_error, error_value=-1, + exc_types=FileNotFoundError) == -1 + assert util.safecall(_error, error_value=-1, + exc_types=(FileNotFoundError, OSError)) == -1 + + +if __name__ == '__main__': + sys.exit(pytest.main(["-s", "-v"] + sys.argv)) diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/INSTALLER b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a1b589e38a32041e49332e5e81c2d363dc418d68 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/INSTALLER @@ -0,0 +1 @@ +pip diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/LICENSE b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..79a03ca513a7c94562cb1f8d83aa8bfc736ba0c2 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/LICENSE @@ -0,0 +1,21 @@ +The MIT License + +Copyright (c) 2015 MagicStack Inc. http://magic.io + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/METADATA b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..57c5f5c27548ff066a3641292a6688101873ae4a --- /dev/null +++ b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/METADATA @@ -0,0 +1,133 @@ +Metadata-Version: 2.1 +Name: httptools +Version: 0.6.4 +Summary: A collection of framework independent HTTP protocol utils. +Home-page: https://github.com/MagicStack/httptools +Author: Yury Selivanov +Author-email: yury@magic.io +License: MIT +Platform: macOS +Platform: POSIX +Platform: Windows +Classifier: License :: OSI Approved :: MIT License +Classifier: Intended Audience :: Developers +Classifier: Programming Language :: Python :: 3 +Classifier: Operating System :: POSIX +Classifier: Operating System :: MacOS :: MacOS X +Classifier: Environment :: Web Environment +Classifier: Development Status :: 5 - Production/Stable +Requires-Python: >=3.8.0 +Description-Content-Type: text/markdown +License-File: LICENSE +Provides-Extra: test +Requires-Dist: Cython>=0.29.24; extra == "test" + +![Tests](https://github.com/MagicStack/httptools/workflows/Tests/badge.svg) + +httptools is a Python binding for the nodejs HTTP parser. + +The package is available on PyPI: `pip install httptools`. + + +# APIs + +httptools contains two classes `httptools.HttpRequestParser`, +`httptools.HttpResponseParser` (fulfilled through +[llhttp](https://github.com/nodejs/llhttp)) and a function for +parsing URLs `httptools.parse_url` (through +[http-parse](https://github.com/nodejs/http-parser) for now). +See unittests for examples. + + +```python + +class HttpRequestParser: + + def __init__(self, protocol): + """HttpRequestParser + + protocol -- a Python object with the following methods + (all optional): + + - on_message_begin() + - on_url(url: bytes) + - on_header(name: bytes, value: bytes) + - on_headers_complete() + - on_body(body: bytes) + - on_message_complete() + - on_chunk_header() + - on_chunk_complete() + - on_status(status: bytes) + """ + + def get_http_version(self) -> str: + """Return an HTTP protocol version.""" + + def should_keep_alive(self) -> bool: + """Return ``True`` if keep-alive mode is preferred.""" + + def should_upgrade(self) -> bool: + """Return ``True`` if the parsed request is a valid Upgrade request. + The method exposes a flag set just before on_headers_complete. + Calling this method earlier will only yield `False`. + """ + + def feed_data(self, data: bytes): + """Feed data to the parser. + + Will eventually trigger callbacks on the ``protocol`` + object. + + On HTTP upgrade, this method will raise an + ``HttpParserUpgrade`` exception, with its sole argument + set to the offset of the non-HTTP data in ``data``. + """ + + def get_method(self) -> bytes: + """Return HTTP request method (GET, HEAD, etc)""" + + +class HttpResponseParser: + + """Has all methods except ``get_method()`` that + HttpRequestParser has.""" + + def get_status_code(self) -> int: + """Return the status code of the HTTP response""" + + +def parse_url(url: bytes): + """Parse URL strings into a structured Python object. + + Returns an instance of ``httptools.URL`` class with the + following attributes: + + - schema: bytes + - host: bytes + - port: int + - path: bytes + - query: bytes + - fragment: bytes + - userinfo: bytes + """ +``` + + +# Development + +1. Clone this repository with + `git clone --recursive git@github.com:MagicStack/httptools.git` + +2. Create a virtual environment with Python 3: + `python3 -m venv envname` + +3. Activate the environment with `source envname/bin/activate` + +4. Install development requirements with `pip install -e .[test]` + +5. Run `make` and `make test`. + + +# License + +MIT. diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/RECORD b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..e83c5daeabe5d5dae0465092a038027f54efede4 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/RECORD @@ -0,0 +1,22 @@ +httptools-0.6.4.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +httptools-0.6.4.dist-info/LICENSE,sha256=9Fc-fLdnZ0X7W402-lSKqT45HPtoct2s1lEwxF6mqS0,1093 +httptools-0.6.4.dist-info/METADATA,sha256=U4VRvayKRJbdHp18Fagk4_L7RvIQJ4anhwtwS64rO9A,3583 +httptools-0.6.4.dist-info/RECORD,, +httptools-0.6.4.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +httptools-0.6.4.dist-info/WHEEL,sha256=2JiXcU0-Qfy9gwog3WAIw4e5slUs9ReZ9xqrxqqbExM,224 +httptools-0.6.4.dist-info/top_level.txt,sha256=APjJKTbZcj0OQ4fdgf2eTCk82nK1n2BFXOD7ky41MPY,10 +httptools/__init__.py,sha256=plt3MIbueJdco9Dy7zoH3ksLNeyirqWagat5rwRmAjo,147 +httptools/__pycache__/__init__.cpython-310.pyc,, +httptools/__pycache__/_version.cpython-310.pyc,, +httptools/_version.py,sha256=ASqOB8fLS7jwZsM551Lc49WxYPyjteqnz1iDWmka-KA,575 +httptools/parser/__init__.py,sha256=fWyconPEHZlJojzRwmBKSn4C85OGXmKEwiEcdjHqXO8,166 +httptools/parser/__pycache__/__init__.cpython-310.pyc,, +httptools/parser/__pycache__/errors.cpython-310.pyc,, +httptools/parser/cparser.pxd,sha256=4qBxnma83Vz86Z9sOZRxjqYj20A-aLSWVGXZgTVLJqE,4977 +httptools/parser/errors.py,sha256=ZVrtN1smPIb_opQ2Ud3uCbGlNLMlECYM2-6S7r5LnHs,566 +httptools/parser/parser.cpython-310-x86_64-linux-gnu.so,sha256=gUJVhgrfY6kfy5lOsa1_8lIFPtbRLot_obcQUnrfRuk,1028176 +httptools/parser/parser.pyx,sha256=x0BUY9EzHNKCDaw-U8bkZ1MaKGtrOQ8iVCm1IuOtEQI,15140 +httptools/parser/python.pxd,sha256=zWCdGZh34fyQNt3BUHIUjPqY8a5sodRUkfdABxqYHgQ,138 +httptools/parser/url_cparser.pxd,sha256=X5dDI8A7T0l5HL_Czt0mTs0l_d2lXnUDHx1TN8LeiCM,779 +httptools/parser/url_parser.cpython-310-x86_64-linux-gnu.so,sha256=rG1YT8DYa7kfGmsTITKzLi1H-ZJShJEkJWXnziUo0JU,426712 +httptools/parser/url_parser.pyx,sha256=ZJVUZqrIDdhzVodA7tTtoFb570av-SczIyh2oAZXKzM,3758 diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/REQUESTED b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/WHEEL b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..5d79f5676bcd9b2cd48440916083f8129fc7be69 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/WHEEL @@ -0,0 +1,8 @@ +Wheel-Version: 1.0 +Generator: setuptools (75.1.0) +Root-Is-Purelib: false +Tag: cp310-cp310-manylinux_2_5_x86_64 +Tag: cp310-cp310-manylinux1_x86_64 +Tag: cp310-cp310-manylinux_2_17_x86_64 +Tag: cp310-cp310-manylinux2014_x86_64 + diff --git a/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/top_level.txt b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..bef3b40b2f33a46ae13d46456df480f77ab712e3 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/httptools-0.6.4.dist-info/top_level.txt @@ -0,0 +1 @@ +httptools diff --git a/vllm/lib/python3.10/site-packages/inflection/__init__.py b/vllm/lib/python3.10/site-packages/inflection/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..c18a0b65b6b16d4d97b7c7f6cb3fea9f04fff327 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/inflection/__init__.py @@ -0,0 +1,426 @@ +# -*- coding: utf-8 -*- +""" + inflection + ~~~~~~~~~~~~ + + A port of Ruby on Rails' inflector to Python. + + :copyright: (c) 2012-2020 by Janne Vanhala + + :license: MIT, see LICENSE for more details. +""" +import re +import unicodedata + +__version__ = '0.5.1' + +PLURALS = [ + (r"(?i)(quiz)$", r'\1zes'), + (r"(?i)^(oxen)$", r'\1'), + (r"(?i)^(ox)$", r'\1en'), + (r"(?i)(m|l)ice$", r'\1ice'), + (r"(?i)(m|l)ouse$", r'\1ice'), + (r"(?i)(passer)s?by$", r'\1sby'), + (r"(?i)(matr|vert|ind)(?:ix|ex)$", r'\1ices'), + (r"(?i)(x|ch|ss|sh)$", r'\1es'), + (r"(?i)([^aeiouy]|qu)y$", r'\1ies'), + (r"(?i)(hive)$", r'\1s'), + (r"(?i)([lr])f$", r'\1ves'), + (r"(?i)([^f])fe$", r'\1ves'), + (r"(?i)sis$", 'ses'), + (r"(?i)([ti])a$", r'\1a'), + (r"(?i)([ti])um$", r'\1a'), + (r"(?i)(buffal|potat|tomat)o$", r'\1oes'), + (r"(?i)(bu)s$", r'\1ses'), + (r"(?i)(alias|status)$", r'\1es'), + (r"(?i)(octop|vir)i$", r'\1i'), + (r"(?i)(octop|vir)us$", r'\1i'), + (r"(?i)^(ax|test)is$", r'\1es'), + (r"(?i)s$", 's'), + (r"$", 's'), +] + +SINGULARS = [ + (r"(?i)(database)s$", r'\1'), + (r"(?i)(quiz)zes$", r'\1'), + (r"(?i)(matr)ices$", r'\1ix'), + (r"(?i)(vert|ind)ices$", r'\1ex'), + (r"(?i)(passer)sby$", r'\1by'), + (r"(?i)^(ox)en", r'\1'), + (r"(?i)(alias|status)(es)?$", r'\1'), + (r"(?i)(octop|vir)(us|i)$", r'\1us'), + (r"(?i)^(a)x[ie]s$", r'\1xis'), + (r"(?i)(cris|test)(is|es)$", r'\1is'), + (r"(?i)(shoe)s$", r'\1'), + (r"(?i)(o)es$", r'\1'), + (r"(?i)(bus)(es)?$", r'\1'), + (r"(?i)(m|l)ice$", r'\1ouse'), + (r"(?i)(x|ch|ss|sh)es$", r'\1'), + (r"(?i)(m)ovies$", r'\1ovie'), + (r"(?i)(s)eries$", r'\1eries'), + (r"(?i)([^aeiouy]|qu)ies$", r'\1y'), + (r"(?i)([lr])ves$", r'\1f'), + (r"(?i)(tive)s$", r'\1'), + (r"(?i)(hive)s$", r'\1'), + (r"(?i)([^f])ves$", r'\1fe'), + (r"(?i)(t)he(sis|ses)$", r"\1hesis"), + (r"(?i)(s)ynop(sis|ses)$", r"\1ynopsis"), + (r"(?i)(p)rogno(sis|ses)$", r"\1rognosis"), + (r"(?i)(p)arenthe(sis|ses)$", r"\1arenthesis"), + (r"(?i)(d)iagno(sis|ses)$", r"\1iagnosis"), + (r"(?i)(b)a(sis|ses)$", r"\1asis"), + (r"(?i)(a)naly(sis|ses)$", r"\1nalysis"), + (r"(?i)([ti])a$", r'\1um'), + (r"(?i)(n)ews$", r'\1ews'), + (r"(?i)(ss)$", r'\1'), + (r"(?i)s$", ''), +] + +UNCOUNTABLES = { + 'equipment', + 'fish', + 'information', + 'jeans', + 'money', + 'rice', + 'series', + 'sheep', + 'species'} + + +def _irregular(singular: str, plural: str) -> None: + """ + A convenience function to add appropriate rules to plurals and singular + for irregular words. + + :param singular: irregular word in singular form + :param plural: irregular word in plural form + """ + def caseinsensitive(string: str) -> str: + return ''.join('[' + char + char.upper() + ']' for char in string) + + if singular[0].upper() == plural[0].upper(): + PLURALS.insert(0, ( + r"(?i)({}){}$".format(singular[0], singular[1:]), + r'\1' + plural[1:] + )) + PLURALS.insert(0, ( + r"(?i)({}){}$".format(plural[0], plural[1:]), + r'\1' + plural[1:] + )) + SINGULARS.insert(0, ( + r"(?i)({}){}$".format(plural[0], plural[1:]), + r'\1' + singular[1:] + )) + else: + PLURALS.insert(0, ( + r"{}{}$".format(singular[0].upper(), + caseinsensitive(singular[1:])), + plural[0].upper() + plural[1:] + )) + PLURALS.insert(0, ( + r"{}{}$".format(singular[0].lower(), + caseinsensitive(singular[1:])), + plural[0].lower() + plural[1:] + )) + PLURALS.insert(0, ( + r"{}{}$".format(plural[0].upper(), caseinsensitive(plural[1:])), + plural[0].upper() + plural[1:] + )) + PLURALS.insert(0, ( + r"{}{}$".format(plural[0].lower(), caseinsensitive(plural[1:])), + plural[0].lower() + plural[1:] + )) + SINGULARS.insert(0, ( + r"{}{}$".format(plural[0].upper(), caseinsensitive(plural[1:])), + singular[0].upper() + singular[1:] + )) + SINGULARS.insert(0, ( + r"{}{}$".format(plural[0].lower(), caseinsensitive(plural[1:])), + singular[0].lower() + singular[1:] + )) + + +def camelize(string: str, uppercase_first_letter: bool = True) -> str: + """ + Convert strings to CamelCase. + + Examples:: + + >>> camelize("device_type") + 'DeviceType' + >>> camelize("device_type", False) + 'deviceType' + + :func:`camelize` can be thought of as a inverse of :func:`underscore`, + although there are some cases where that does not hold:: + + >>> camelize(underscore("IOError")) + 'IoError' + + :param uppercase_first_letter: if set to `True` :func:`camelize` converts + strings to UpperCamelCase. If set to `False` :func:`camelize` produces + lowerCamelCase. Defaults to `True`. + """ + if uppercase_first_letter: + return re.sub(r"(?:^|_)(.)", lambda m: m.group(1).upper(), string) + else: + return string[0].lower() + camelize(string)[1:] + + +def dasherize(word: str) -> str: + """Replace underscores with dashes in the string. + + Example:: + + >>> dasherize("puni_puni") + 'puni-puni' + + """ + return word.replace('_', '-') + + +def humanize(word: str) -> str: + """ + Capitalize the first word and turn underscores into spaces and strip a + trailing ``"_id"``, if any. Like :func:`titleize`, this is meant for + creating pretty output. + + Examples:: + + >>> humanize("employee_salary") + 'Employee salary' + >>> humanize("author_id") + 'Author' + + """ + word = re.sub(r"_id$", "", word) + word = word.replace('_', ' ') + word = re.sub(r"(?i)([a-z\d]*)", lambda m: m.group(1).lower(), word) + word = re.sub(r"^\w", lambda m: m.group(0).upper(), word) + return word + + +def ordinal(number: int) -> str: + """ + Return the suffix that should be added to a number to denote the position + in an ordered sequence such as 1st, 2nd, 3rd, 4th. + + Examples:: + + >>> ordinal(1) + 'st' + >>> ordinal(2) + 'nd' + >>> ordinal(1002) + 'nd' + >>> ordinal(1003) + 'rd' + >>> ordinal(-11) + 'th' + >>> ordinal(-1021) + 'st' + + """ + number = abs(int(number)) + if number % 100 in (11, 12, 13): + return "th" + else: + return { + 1: "st", + 2: "nd", + 3: "rd", + }.get(number % 10, "th") + + +def ordinalize(number: int) -> str: + """ + Turn a number into an ordinal string used to denote the position in an + ordered sequence such as 1st, 2nd, 3rd, 4th. + + Examples:: + + >>> ordinalize(1) + '1st' + >>> ordinalize(2) + '2nd' + >>> ordinalize(1002) + '1002nd' + >>> ordinalize(1003) + '1003rd' + >>> ordinalize(-11) + '-11th' + >>> ordinalize(-1021) + '-1021st' + + """ + return "{}{}".format(number, ordinal(number)) + + +def parameterize(string: str, separator: str = '-') -> str: + """ + Replace special characters in a string so that it may be used as part of a + 'pretty' URL. + + Example:: + + >>> parameterize(u"Donald E. Knuth") + 'donald-e-knuth' + + """ + string = transliterate(string) + # Turn unwanted chars into the separator + string = re.sub(r"(?i)[^a-z0-9\-_]+", separator, string) + if separator: + re_sep = re.escape(separator) + # No more than one of the separator in a row. + string = re.sub(r'%s{2,}' % re_sep, separator, string) + # Remove leading/trailing separator. + string = re.sub(r"(?i)^{sep}|{sep}$".format(sep=re_sep), '', string) + + return string.lower() + + +def pluralize(word: str) -> str: + """ + Return the plural form of a word. + + Examples:: + + >>> pluralize("posts") + 'posts' + >>> pluralize("octopus") + 'octopi' + >>> pluralize("sheep") + 'sheep' + >>> pluralize("CamelOctopus") + 'CamelOctopi' + + """ + if not word or word.lower() in UNCOUNTABLES: + return word + else: + for rule, replacement in PLURALS: + if re.search(rule, word): + return re.sub(rule, replacement, word) + return word + + +def singularize(word: str) -> str: + """ + Return the singular form of a word, the reverse of :func:`pluralize`. + + Examples:: + + >>> singularize("posts") + 'post' + >>> singularize("octopi") + 'octopus' + >>> singularize("sheep") + 'sheep' + >>> singularize("word") + 'word' + >>> singularize("CamelOctopi") + 'CamelOctopus' + + """ + for inflection in UNCOUNTABLES: + if re.search(r'(?i)\b(%s)\Z' % inflection, word): + return word + + for rule, replacement in SINGULARS: + if re.search(rule, word): + return re.sub(rule, replacement, word) + return word + + +def tableize(word: str) -> str: + """ + Create the name of a table like Rails does for models to table names. This + method uses the :func:`pluralize` method on the last word in the string. + + Examples:: + + >>> tableize('RawScaledScorer') + 'raw_scaled_scorers' + >>> tableize('egg_and_ham') + 'egg_and_hams' + >>> tableize('fancyCategory') + 'fancy_categories' + """ + return pluralize(underscore(word)) + + +def titleize(word: str) -> str: + """ + Capitalize all the words and replace some characters in the string to + create a nicer looking title. :func:`titleize` is meant for creating pretty + output. + + Examples:: + + >>> titleize("man from the boondocks") + 'Man From The Boondocks' + >>> titleize("x-men: the last stand") + 'X Men: The Last Stand' + >>> titleize("TheManWithoutAPast") + 'The Man Without A Past' + >>> titleize("raiders_of_the_lost_ark") + 'Raiders Of The Lost Ark' + + """ + return re.sub( + r"\b('?\w)", + lambda match: match.group(1).capitalize(), + humanize(underscore(word)).title() + ) + + +def transliterate(string: str) -> str: + """ + Replace non-ASCII characters with an ASCII approximation. If no + approximation exists, the non-ASCII character is ignored. The string must + be ``unicode``. + + Examples:: + + >>> transliterate('älämölö') + 'alamolo' + >>> transliterate('Ærøskøbing') + 'rskbing' + + """ + normalized = unicodedata.normalize('NFKD', string) + return normalized.encode('ascii', 'ignore').decode('ascii') + + +def underscore(word: str) -> str: + """ + Make an underscored, lowercase form from the expression in the string. + + Example:: + + >>> underscore("DeviceType") + 'device_type' + + As a rule of thumb you can think of :func:`underscore` as the inverse of + :func:`camelize`, though there are cases where that does not hold:: + + >>> camelize(underscore("IOError")) + 'IoError' + + """ + word = re.sub(r"([A-Z]+)([A-Z][a-z])", r'\1_\2', word) + word = re.sub(r"([a-z\d])([A-Z])", r'\1_\2', word) + word = word.replace("-", "_") + return word.lower() + + +_irregular('person', 'people') +_irregular('man', 'men') +_irregular('human', 'humans') +_irregular('child', 'children') +_irregular('sex', 'sexes') +_irregular('move', 'moves') +_irregular('cow', 'kine') +_irregular('zombie', 'zombies') diff --git a/vllm/lib/python3.10/site-packages/inflection/__pycache__/__init__.cpython-310.pyc b/vllm/lib/python3.10/site-packages/inflection/__pycache__/__init__.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..1a73d9c8d3f5f06f92a3864a4f7c9d4b53699990 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/inflection/__pycache__/__init__.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/inflection/py.typed b/vllm/lib/python3.10/site-packages/inflection/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/vllm/lib/python3.10/site-packages/multidict/__init__.py b/vllm/lib/python3.10/site-packages/multidict/__init__.py new file mode 100644 index 0000000000000000000000000000000000000000..25ddca41e9b86260c2a5113b15d7d5f2435fa3d1 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/__init__.py @@ -0,0 +1,48 @@ +"""Multidict implementation. + +HTTP Headers and URL query string require specific data structure: +multidict. It behaves mostly like a dict but it can have +several values for the same key. +""" + +from ._abc import MultiMapping, MutableMultiMapping +from ._compat import USE_EXTENSIONS + +__all__ = ( + "MultiMapping", + "MutableMultiMapping", + "MultiDictProxy", + "CIMultiDictProxy", + "MultiDict", + "CIMultiDict", + "upstr", + "istr", + "getversion", +) + +__version__ = "6.1.0" + + +try: + if not USE_EXTENSIONS: + raise ImportError + from ._multidict import ( + CIMultiDict, + CIMultiDictProxy, + MultiDict, + MultiDictProxy, + getversion, + istr, + ) +except ImportError: # pragma: no cover + from ._multidict_py import ( + CIMultiDict, + CIMultiDictProxy, + MultiDict, + MultiDictProxy, + getversion, + istr, + ) + + +upstr = istr diff --git a/vllm/lib/python3.10/site-packages/multidict/__init__.pyi b/vllm/lib/python3.10/site-packages/multidict/__init__.pyi new file mode 100644 index 0000000000000000000000000000000000000000..0940340f81e602cf74e74e9384f15d7d12d1389b --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/__init__.pyi @@ -0,0 +1,152 @@ +import abc +from typing import ( + Generic, + Iterable, + Iterator, + Mapping, + MutableMapping, + TypeVar, + overload, +) + +class istr(str): ... + +upstr = istr + +_S = str | istr + +_T = TypeVar("_T") + +_T_co = TypeVar("_T_co", covariant=True) + +_D = TypeVar("_D") + +class MultiMapping(Mapping[_S, _T_co]): + @overload + @abc.abstractmethod + def getall(self, key: _S) -> list[_T_co]: ... + @overload + @abc.abstractmethod + def getall(self, key: _S, default: _D) -> list[_T_co] | _D: ... + @overload + @abc.abstractmethod + def getone(self, key: _S) -> _T_co: ... + @overload + @abc.abstractmethod + def getone(self, key: _S, default: _D) -> _T_co | _D: ... + +_Arg = ( + Mapping[str, _T] + | Mapping[istr, _T] + | dict[str, _T] + | dict[istr, _T] + | MultiMapping[_T] + | Iterable[tuple[str, _T]] + | Iterable[tuple[istr, _T]] +) + +class MutableMultiMapping(MultiMapping[_T], MutableMapping[_S, _T], Generic[_T]): + @abc.abstractmethod + def add(self, key: _S, value: _T) -> None: ... + @abc.abstractmethod + def extend(self, arg: _Arg[_T] = ..., **kwargs: _T) -> None: ... + @overload + @abc.abstractmethod + def popone(self, key: _S) -> _T: ... + @overload + @abc.abstractmethod + def popone(self, key: _S, default: _D) -> _T | _D: ... + @overload + @abc.abstractmethod + def popall(self, key: _S) -> list[_T]: ... + @overload + @abc.abstractmethod + def popall(self, key: _S, default: _D) -> list[_T] | _D: ... + +class MultiDict(MutableMultiMapping[_T], Generic[_T]): + def __init__(self, arg: _Arg[_T] = ..., **kwargs: _T) -> None: ... + def copy(self) -> MultiDict[_T]: ... + def __getitem__(self, k: _S) -> _T: ... + def __setitem__(self, k: _S, v: _T) -> None: ... + def __delitem__(self, v: _S) -> None: ... + def __iter__(self) -> Iterator[_S]: ... + def __len__(self) -> int: ... + @overload + def getall(self, key: _S) -> list[_T]: ... + @overload + def getall(self, key: _S, default: _D) -> list[_T] | _D: ... + @overload + def getone(self, key: _S) -> _T: ... + @overload + def getone(self, key: _S, default: _D) -> _T | _D: ... + def add(self, key: _S, value: _T) -> None: ... + def extend(self, arg: _Arg[_T] = ..., **kwargs: _T) -> None: ... + @overload + def popone(self, key: _S) -> _T: ... + @overload + def popone(self, key: _S, default: _D) -> _T | _D: ... + @overload + def popall(self, key: _S) -> list[_T]: ... + @overload + def popall(self, key: _S, default: _D) -> list[_T] | _D: ... + +class CIMultiDict(MutableMultiMapping[_T], Generic[_T]): + def __init__(self, arg: _Arg[_T] = ..., **kwargs: _T) -> None: ... + def copy(self) -> CIMultiDict[_T]: ... + def __getitem__(self, k: _S) -> _T: ... + def __setitem__(self, k: _S, v: _T) -> None: ... + def __delitem__(self, v: _S) -> None: ... + def __iter__(self) -> Iterator[_S]: ... + def __len__(self) -> int: ... + @overload + def getall(self, key: _S) -> list[_T]: ... + @overload + def getall(self, key: _S, default: _D) -> list[_T] | _D: ... + @overload + def getone(self, key: _S) -> _T: ... + @overload + def getone(self, key: _S, default: _D) -> _T | _D: ... + def add(self, key: _S, value: _T) -> None: ... + def extend(self, arg: _Arg[_T] = ..., **kwargs: _T) -> None: ... + @overload + def popone(self, key: _S) -> _T: ... + @overload + def popone(self, key: _S, default: _D) -> _T | _D: ... + @overload + def popall(self, key: _S) -> list[_T]: ... + @overload + def popall(self, key: _S, default: _D) -> list[_T] | _D: ... + +class MultiDictProxy(MultiMapping[_T], Generic[_T]): + def __init__(self, arg: MultiMapping[_T] | MutableMultiMapping[_T]) -> None: ... + def copy(self) -> MultiDict[_T]: ... + def __getitem__(self, k: _S) -> _T: ... + def __iter__(self) -> Iterator[_S]: ... + def __len__(self) -> int: ... + @overload + def getall(self, key: _S) -> list[_T]: ... + @overload + def getall(self, key: _S, default: _D) -> list[_T] | _D: ... + @overload + def getone(self, key: _S) -> _T: ... + @overload + def getone(self, key: _S, default: _D) -> _T | _D: ... + +class CIMultiDictProxy(MultiMapping[_T], Generic[_T]): + def __init__(self, arg: MultiMapping[_T] | MutableMultiMapping[_T]) -> None: ... + def __getitem__(self, k: _S) -> _T: ... + def __iter__(self) -> Iterator[_S]: ... + def __len__(self) -> int: ... + @overload + def getall(self, key: _S) -> list[_T]: ... + @overload + def getall(self, key: _S, default: _D) -> list[_T] | _D: ... + @overload + def getone(self, key: _S) -> _T: ... + @overload + def getone(self, key: _S, default: _D) -> _T | _D: ... + def copy(self) -> CIMultiDict[_T]: ... + +def getversion( + md: MultiDict[_T] | CIMultiDict[_T] | MultiDictProxy[_T] | CIMultiDictProxy[_T], +) -> int: ... diff --git a/vllm/lib/python3.10/site-packages/multidict/__pycache__/__init__.cpython-310.pyc b/vllm/lib/python3.10/site-packages/multidict/__pycache__/__init__.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..ce4b4764191c37cf7b99e8c41e7307396cb6326c Binary files /dev/null and b/vllm/lib/python3.10/site-packages/multidict/__pycache__/__init__.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/multidict/__pycache__/_abc.cpython-310.pyc b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_abc.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..31125d675bf4f75cfaf75eda2b9c7dbe7401e25f Binary files /dev/null and b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_abc.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/multidict/__pycache__/_compat.cpython-310.pyc b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_compat.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..dae8e684b3a9764f0cf52d98c61cecea1c01419d Binary files /dev/null and b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_compat.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/multidict/__pycache__/_multidict_base.cpython-310.pyc b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_multidict_base.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..77660b29f0359c3a4e99147c5c1289307a3b211e Binary files /dev/null and b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_multidict_base.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/multidict/__pycache__/_multidict_py.cpython-310.pyc b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_multidict_py.cpython-310.pyc new file mode 100644 index 0000000000000000000000000000000000000000..a751f38ec6dca2f9bd222047714ba1c3af298607 Binary files /dev/null and b/vllm/lib/python3.10/site-packages/multidict/__pycache__/_multidict_py.cpython-310.pyc differ diff --git a/vllm/lib/python3.10/site-packages/multidict/_abc.py b/vllm/lib/python3.10/site-packages/multidict/_abc.py new file mode 100644 index 0000000000000000000000000000000000000000..0603cdd2447eb8a55584802a7b7c475b12bfc9c5 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/_abc.py @@ -0,0 +1,48 @@ +import abc +import sys +import types +from collections.abc import Mapping, MutableMapping + + +class _TypingMeta(abc.ABCMeta): + # A fake metaclass to satisfy typing deps in runtime + # basically MultiMapping[str] and other generic-like type instantiations + # are emulated. + # Note: real type hints are provided by __init__.pyi stub file + if sys.version_info >= (3, 9): + + def __getitem__(self, key): + return types.GenericAlias(self, key) + + else: + + def __getitem__(self, key): + return self + + +class MultiMapping(Mapping, metaclass=_TypingMeta): + @abc.abstractmethod + def getall(self, key, default=None): + raise KeyError + + @abc.abstractmethod + def getone(self, key, default=None): + raise KeyError + + +class MutableMultiMapping(MultiMapping, MutableMapping): + @abc.abstractmethod + def add(self, key, value): + raise NotImplementedError + + @abc.abstractmethod + def extend(self, *args, **kwargs): + raise NotImplementedError + + @abc.abstractmethod + def popone(self, key, default=None): + raise KeyError + + @abc.abstractmethod + def popall(self, key, default=None): + raise KeyError diff --git a/vllm/lib/python3.10/site-packages/multidict/_compat.py b/vllm/lib/python3.10/site-packages/multidict/_compat.py new file mode 100644 index 0000000000000000000000000000000000000000..4713da2ceac64f45d05d9155e6e95d81a0f47893 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/_compat.py @@ -0,0 +1,14 @@ +import os +import platform + +NO_EXTENSIONS = bool(os.environ.get("MULTIDICT_NO_EXTENSIONS")) + +PYPY = platform.python_implementation() == "PyPy" + +USE_EXTENSIONS = not NO_EXTENSIONS and not PYPY + +if USE_EXTENSIONS: + try: + from . import _multidict # type: ignore[attr-defined] # noqa: F401 + except ImportError: + USE_EXTENSIONS = False diff --git a/vllm/lib/python3.10/site-packages/multidict/_multidict_base.py b/vllm/lib/python3.10/site-packages/multidict/_multidict_base.py new file mode 100644 index 0000000000000000000000000000000000000000..de2f762a5c0e1830de8896fa50b08bcf10f1942b --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/_multidict_base.py @@ -0,0 +1,152 @@ +import sys +from collections.abc import ItemsView, Iterable, KeysView, Set, ValuesView + +if sys.version_info >= (3, 11): + from typing import assert_never +else: + from typing_extensions import assert_never + + +def _abc_itemsview_register(view_cls): + ItemsView.register(view_cls) + + +def _abc_keysview_register(view_cls): + KeysView.register(view_cls) + + +def _abc_valuesview_register(view_cls): + ValuesView.register(view_cls) + + +def _viewbaseset_richcmp(view, other, op): + if op == 0: # < + if not isinstance(other, Set): + return NotImplemented + return len(view) < len(other) and view <= other + elif op == 1: # <= + if not isinstance(other, Set): + return NotImplemented + if len(view) > len(other): + return False + for elem in view: + if elem not in other: + return False + return True + elif op == 2: # == + if not isinstance(other, Set): + return NotImplemented + return len(view) == len(other) and view <= other + elif op == 3: # != + return not view == other + elif op == 4: # > + if not isinstance(other, Set): + return NotImplemented + return len(view) > len(other) and view >= other + elif op == 5: # >= + if not isinstance(other, Set): + return NotImplemented + if len(view) < len(other): + return False + for elem in other: + if elem not in view: + return False + return True + else: # pragma: no cover + assert_never(op) + + +def _viewbaseset_and(view, other): + if not isinstance(other, Iterable): + return NotImplemented + if isinstance(view, Set): + view = set(iter(view)) + if isinstance(other, Set): + other = set(iter(other)) + if not isinstance(other, Set): + other = set(iter(other)) + return view & other + + +def _viewbaseset_or(view, other): + if not isinstance(other, Iterable): + return NotImplemented + if isinstance(view, Set): + view = set(iter(view)) + if isinstance(other, Set): + other = set(iter(other)) + if not isinstance(other, Set): + other = set(iter(other)) + return view | other + + +def _viewbaseset_sub(view, other): + if not isinstance(other, Iterable): + return NotImplemented + if isinstance(view, Set): + view = set(iter(view)) + if isinstance(other, Set): + other = set(iter(other)) + if not isinstance(other, Set): + other = set(iter(other)) + return view - other + + +def _viewbaseset_xor(view, other): + if not isinstance(other, Iterable): + return NotImplemented + if isinstance(view, Set): + view = set(iter(view)) + if isinstance(other, Set): + other = set(iter(other)) + if not isinstance(other, Set): + other = set(iter(other)) + return view ^ other + + +def _itemsview_isdisjoint(view, other): + "Return True if two sets have a null intersection." + for v in other: + if v in view: + return False + return True + + +def _itemsview_repr(view): + lst = [] + for k, v in view: + lst.append("{!r}: {!r}".format(k, v)) + body = ", ".join(lst) + return "{}({})".format(view.__class__.__name__, body) + + +def _keysview_isdisjoint(view, other): + "Return True if two sets have a null intersection." + for k in other: + if k in view: + return False + return True + + +def _keysview_repr(view): + lst = [] + for k in view: + lst.append("{!r}".format(k)) + body = ", ".join(lst) + return "{}({})".format(view.__class__.__name__, body) + + +def _valuesview_repr(view): + lst = [] + for v in view: + lst.append("{!r}".format(v)) + body = ", ".join(lst) + return "{}({})".format(view.__class__.__name__, body) + + +def _mdrepr(md): + lst = [] + for k, v in md.items(): + lst.append("'{}': {!r}".format(k, v)) + body = ", ".join(lst) + return "<{}({})>".format(md.__class__.__name__, body) diff --git a/vllm/lib/python3.10/site-packages/multidict/_multidict_py.py b/vllm/lib/python3.10/site-packages/multidict/_multidict_py.py new file mode 100644 index 0000000000000000000000000000000000000000..79c45aa19c52080c1a15d783accd5bbfdd416489 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/_multidict_py.py @@ -0,0 +1,527 @@ +import sys +import types +from array import array +from collections import abc + +from ._abc import MultiMapping, MutableMultiMapping + +_marker = object() + +if sys.version_info >= (3, 9): + GenericAlias = types.GenericAlias +else: + + def GenericAlias(cls): + return cls + + +class istr(str): + + """Case insensitive str.""" + + __is_istr__ = True + + +upstr = istr # for relaxing backward compatibility problems + + +def getversion(md): + if not isinstance(md, _Base): + raise TypeError("Parameter should be multidict or proxy") + return md._impl._version + + +_version = array("Q", [0]) + + +class _Impl: + __slots__ = ("_items", "_version") + + def __init__(self): + self._items = [] + self.incr_version() + + def incr_version(self): + global _version + v = _version + v[0] += 1 + self._version = v[0] + + if sys.implementation.name != "pypy": + + def __sizeof__(self): + return object.__sizeof__(self) + sys.getsizeof(self._items) + + +class _Base: + def _title(self, key): + return key + + def getall(self, key, default=_marker): + """Return a list of all values matching the key.""" + identity = self._title(key) + res = [v for i, k, v in self._impl._items if i == identity] + if res: + return res + if not res and default is not _marker: + return default + raise KeyError("Key not found: %r" % key) + + def getone(self, key, default=_marker): + """Get first value matching the key. + + Raises KeyError if the key is not found and no default is provided. + """ + identity = self._title(key) + for i, k, v in self._impl._items: + if i == identity: + return v + if default is not _marker: + return default + raise KeyError("Key not found: %r" % key) + + # Mapping interface # + + def __getitem__(self, key): + return self.getone(key) + + def get(self, key, default=None): + """Get first value matching the key. + + If the key is not found, returns the default (or None if no default is provided) + """ + return self.getone(key, default) + + def __iter__(self): + return iter(self.keys()) + + def __len__(self): + return len(self._impl._items) + + def keys(self): + """Return a new view of the dictionary's keys.""" + return _KeysView(self._impl) + + def items(self): + """Return a new view of the dictionary's items *(key, value) pairs).""" + return _ItemsView(self._impl) + + def values(self): + """Return a new view of the dictionary's values.""" + return _ValuesView(self._impl) + + def __eq__(self, other): + if not isinstance(other, abc.Mapping): + return NotImplemented + if isinstance(other, _Base): + lft = self._impl._items + rht = other._impl._items + if len(lft) != len(rht): + return False + for (i1, k2, v1), (i2, k2, v2) in zip(lft, rht): + if i1 != i2 or v1 != v2: + return False + return True + if len(self._impl._items) != len(other): + return False + for k, v in self.items(): + nv = other.get(k, _marker) + if v != nv: + return False + return True + + def __contains__(self, key): + identity = self._title(key) + for i, k, v in self._impl._items: + if i == identity: + return True + return False + + def __repr__(self): + body = ", ".join("'{}': {!r}".format(k, v) for k, v in self.items()) + return "<{}({})>".format(self.__class__.__name__, body) + + __class_getitem__ = classmethod(GenericAlias) + + +class MultiDictProxy(_Base, MultiMapping): + """Read-only proxy for MultiDict instance.""" + + def __init__(self, arg): + if not isinstance(arg, (MultiDict, MultiDictProxy)): + raise TypeError( + "ctor requires MultiDict or MultiDictProxy instance" + ", not {}".format(type(arg)) + ) + + self._impl = arg._impl + + def __reduce__(self): + raise TypeError("can't pickle {} objects".format(self.__class__.__name__)) + + def copy(self): + """Return a copy of itself.""" + return MultiDict(self.items()) + + +class CIMultiDictProxy(MultiDictProxy): + """Read-only proxy for CIMultiDict instance.""" + + def __init__(self, arg): + if not isinstance(arg, (CIMultiDict, CIMultiDictProxy)): + raise TypeError( + "ctor requires CIMultiDict or CIMultiDictProxy instance" + ", not {}".format(type(arg)) + ) + + self._impl = arg._impl + + def _title(self, key): + return key.title() + + def copy(self): + """Return a copy of itself.""" + return CIMultiDict(self.items()) + + +class MultiDict(_Base, MutableMultiMapping): + """Dictionary with the support for duplicate keys.""" + + def __init__(self, *args, **kwargs): + self._impl = _Impl() + + self._extend(args, kwargs, self.__class__.__name__, self._extend_items) + + if sys.implementation.name != "pypy": + + def __sizeof__(self): + return object.__sizeof__(self) + sys.getsizeof(self._impl) + + def __reduce__(self): + return (self.__class__, (list(self.items()),)) + + def _title(self, key): + return key + + def _key(self, key): + if isinstance(key, str): + return key + else: + raise TypeError( + "MultiDict keys should be either str " "or subclasses of str" + ) + + def add(self, key, value): + identity = self._title(key) + self._impl._items.append((identity, self._key(key), value)) + self._impl.incr_version() + + def copy(self): + """Return a copy of itself.""" + cls = self.__class__ + return cls(self.items()) + + __copy__ = copy + + def extend(self, *args, **kwargs): + """Extend current MultiDict with more values. + + This method must be used instead of update. + """ + self._extend(args, kwargs, "extend", self._extend_items) + + def _extend(self, args, kwargs, name, method): + if len(args) > 1: + raise TypeError( + "{} takes at most 1 positional argument" + " ({} given)".format(name, len(args)) + ) + if args: + arg = args[0] + if isinstance(args[0], (MultiDict, MultiDictProxy)) and not kwargs: + items = arg._impl._items + else: + if hasattr(arg, "items"): + arg = arg.items() + if kwargs: + arg = list(arg) + arg.extend(list(kwargs.items())) + items = [] + for item in arg: + if not len(item) == 2: + raise TypeError( + "{} takes either dict or list of (key, value) " + "tuples".format(name) + ) + items.append((self._title(item[0]), self._key(item[0]), item[1])) + + method(items) + else: + method( + [ + (self._title(key), self._key(key), value) + for key, value in kwargs.items() + ] + ) + + def _extend_items(self, items): + for identity, key, value in items: + self.add(key, value) + + def clear(self): + """Remove all items from MultiDict.""" + self._impl._items.clear() + self._impl.incr_version() + + # Mapping interface # + + def __setitem__(self, key, value): + self._replace(key, value) + + def __delitem__(self, key): + identity = self._title(key) + items = self._impl._items + found = False + for i in range(len(items) - 1, -1, -1): + if items[i][0] == identity: + del items[i] + found = True + if not found: + raise KeyError(key) + else: + self._impl.incr_version() + + def setdefault(self, key, default=None): + """Return value for key, set value to default if key is not present.""" + identity = self._title(key) + for i, k, v in self._impl._items: + if i == identity: + return v + self.add(key, default) + return default + + def popone(self, key, default=_marker): + """Remove specified key and return the corresponding value. + + If key is not found, d is returned if given, otherwise + KeyError is raised. + + """ + identity = self._title(key) + for i in range(len(self._impl._items)): + if self._impl._items[i][0] == identity: + value = self._impl._items[i][2] + del self._impl._items[i] + self._impl.incr_version() + return value + if default is _marker: + raise KeyError(key) + else: + return default + + pop = popone # type: ignore + + def popall(self, key, default=_marker): + """Remove all occurrences of key and return the list of corresponding + values. + + If key is not found, default is returned if given, otherwise + KeyError is raised. + + """ + found = False + identity = self._title(key) + ret = [] + for i in range(len(self._impl._items) - 1, -1, -1): + item = self._impl._items[i] + if item[0] == identity: + ret.append(item[2]) + del self._impl._items[i] + self._impl.incr_version() + found = True + if not found: + if default is _marker: + raise KeyError(key) + else: + return default + else: + ret.reverse() + return ret + + def popitem(self): + """Remove and return an arbitrary (key, value) pair.""" + if self._impl._items: + i = self._impl._items.pop(0) + self._impl.incr_version() + return i[1], i[2] + else: + raise KeyError("empty multidict") + + def update(self, *args, **kwargs): + """Update the dictionary from *other*, overwriting existing keys.""" + self._extend(args, kwargs, "update", self._update_items) + + def _update_items(self, items): + if not items: + return + used_keys = {} + for identity, key, value in items: + start = used_keys.get(identity, 0) + for i in range(start, len(self._impl._items)): + item = self._impl._items[i] + if item[0] == identity: + used_keys[identity] = i + 1 + self._impl._items[i] = (identity, key, value) + break + else: + self._impl._items.append((identity, key, value)) + used_keys[identity] = len(self._impl._items) + + # drop tails + i = 0 + while i < len(self._impl._items): + item = self._impl._items[i] + identity = item[0] + pos = used_keys.get(identity) + if pos is None: + i += 1 + continue + if i >= pos: + del self._impl._items[i] + else: + i += 1 + + self._impl.incr_version() + + def _replace(self, key, value): + key = self._key(key) + identity = self._title(key) + items = self._impl._items + + for i in range(len(items)): + item = items[i] + if item[0] == identity: + items[i] = (identity, key, value) + # i points to last found item + rgt = i + self._impl.incr_version() + break + else: + self._impl._items.append((identity, key, value)) + self._impl.incr_version() + return + + # remove all tail items + i = rgt + 1 + while i < len(items): + item = items[i] + if item[0] == identity: + del items[i] + else: + i += 1 + + +class CIMultiDict(MultiDict): + """Dictionary with the support for duplicate case-insensitive keys.""" + + def _title(self, key): + return key.title() + + +class _Iter: + __slots__ = ("_size", "_iter") + + def __init__(self, size, iterator): + self._size = size + self._iter = iterator + + def __iter__(self): + return self + + def __next__(self): + return next(self._iter) + + def __length_hint__(self): + return self._size + + +class _ViewBase: + def __init__(self, impl): + self._impl = impl + + def __len__(self): + return len(self._impl._items) + + +class _ItemsView(_ViewBase, abc.ItemsView): + def __contains__(self, item): + assert isinstance(item, tuple) or isinstance(item, list) + assert len(item) == 2 + for i, k, v in self._impl._items: + if item[0] == k and item[1] == v: + return True + return False + + def __iter__(self): + return _Iter(len(self), self._iter(self._impl._version)) + + def _iter(self, version): + for i, k, v in self._impl._items: + if version != self._impl._version: + raise RuntimeError("Dictionary changed during iteration") + yield k, v + + def __repr__(self): + lst = [] + for item in self._impl._items: + lst.append("{!r}: {!r}".format(item[1], item[2])) + body = ", ".join(lst) + return "{}({})".format(self.__class__.__name__, body) + + +class _ValuesView(_ViewBase, abc.ValuesView): + def __contains__(self, value): + for item in self._impl._items: + if item[2] == value: + return True + return False + + def __iter__(self): + return _Iter(len(self), self._iter(self._impl._version)) + + def _iter(self, version): + for item in self._impl._items: + if version != self._impl._version: + raise RuntimeError("Dictionary changed during iteration") + yield item[2] + + def __repr__(self): + lst = [] + for item in self._impl._items: + lst.append("{!r}".format(item[2])) + body = ", ".join(lst) + return "{}({})".format(self.__class__.__name__, body) + + +class _KeysView(_ViewBase, abc.KeysView): + def __contains__(self, key): + for item in self._impl._items: + if item[1] == key: + return True + return False + + def __iter__(self): + return _Iter(len(self), self._iter(self._impl._version)) + + def _iter(self, version): + for item in self._impl._items: + if version != self._impl._version: + raise RuntimeError("Dictionary changed during iteration") + yield item[1] + + def __repr__(self): + lst = [] + for item in self._impl._items: + lst.append("{!r}".format(item[1])) + body = ", ".join(lst) + return "{}({})".format(self.__class__.__name__, body) diff --git a/vllm/lib/python3.10/site-packages/multidict/py.typed b/vllm/lib/python3.10/site-packages/multidict/py.typed new file mode 100644 index 0000000000000000000000000000000000000000..dfe8cc048e7100a97025b954fffa31e4ff859a7d --- /dev/null +++ b/vllm/lib/python3.10/site-packages/multidict/py.typed @@ -0,0 +1 @@ +PEP-561 marker. \ No newline at end of file diff --git a/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/LICENSE b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..cff5eb74e1badd1c5237ed2654b349530179ad1d --- /dev/null +++ b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/LICENSE @@ -0,0 +1,29 @@ +BSD 3-Clause License + +Copyright (c) 2009, Jay Loden, Dave Daeschler, Giampaolo Rodola +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, +are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. + + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + + * Neither the name of the psutil authors nor the names of its contributors + may be used to endorse or promote products derived from this software without + specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/REQUESTED b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/WHEEL b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..cd914569da29261e4b9b92baa594300a56d49711 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/WHEEL @@ -0,0 +1,8 @@ +Wheel-Version: 1.0 +Generator: bdist_wheel (0.37.1) +Root-Is-Purelib: false +Tag: cp36-abi3-manylinux_2_12_x86_64 +Tag: cp36-abi3-manylinux2010_x86_64 +Tag: cp36-abi3-manylinux_2_17_x86_64 +Tag: cp36-abi3-manylinux2014_x86_64 + diff --git a/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/top_level.txt b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/top_level.txt new file mode 100644 index 0000000000000000000000000000000000000000..a4d92cc08db6a0d8bfedbbbd620d1fb11f84677b --- /dev/null +++ b/vllm/lib/python3.10/site-packages/psutil-6.1.0.dist-info/top_level.txt @@ -0,0 +1 @@ +psutil diff --git a/vllm/lib/python3.10/site-packages/qwen_vl_utils-0.0.10.dist-info/INSTALLER b/vllm/lib/python3.10/site-packages/qwen_vl_utils-0.0.10.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a1b589e38a32041e49332e5e81c2d363dc418d68 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/qwen_vl_utils-0.0.10.dist-info/INSTALLER @@ -0,0 +1 @@ +pip diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/INSTALLER b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/INSTALLER new file mode 100644 index 0000000000000000000000000000000000000000..a1b589e38a32041e49332e5e81c2d363dc418d68 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/INSTALLER @@ -0,0 +1 @@ +pip diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/METADATA b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/METADATA new file mode 100644 index 0000000000000000000000000000000000000000..4586b04a63f863a6e97c456a875c425c60666764 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/METADATA @@ -0,0 +1,82 @@ +Metadata-Version: 2.4 +Name: virtualenv +Version: 20.29.1 +Summary: Virtual Python Environment builder +Project-URL: Documentation, https://virtualenv.pypa.io +Project-URL: Homepage, https://github.com/pypa/virtualenv +Project-URL: Source, https://github.com/pypa/virtualenv +Project-URL: Tracker, https://github.com/pypa/virtualenv/issues +Maintainer-email: Bernat Gabor +License-Expression: MIT +License-File: LICENSE +Keywords: environments,isolated,virtual +Classifier: Development Status :: 5 - Production/Stable +Classifier: Intended Audience :: Developers +Classifier: License :: OSI Approved :: MIT License +Classifier: Operating System :: MacOS :: MacOS X +Classifier: Operating System :: Microsoft :: Windows +Classifier: Operating System :: POSIX +Classifier: Programming Language :: Python :: 3 :: Only +Classifier: Programming Language :: Python :: 3.8 +Classifier: Programming Language :: Python :: 3.9 +Classifier: Programming Language :: Python :: 3.10 +Classifier: Programming Language :: Python :: 3.11 +Classifier: Programming Language :: Python :: 3.12 +Classifier: Programming Language :: Python :: 3.13 +Classifier: Programming Language :: Python :: Implementation :: CPython +Classifier: Programming Language :: Python :: Implementation :: PyPy +Classifier: Topic :: Software Development :: Libraries +Classifier: Topic :: Software Development :: Testing +Classifier: Topic :: Utilities +Requires-Python: >=3.8 +Requires-Dist: distlib<1,>=0.3.7 +Requires-Dist: filelock<4,>=3.12.2 +Requires-Dist: importlib-metadata>=6.6; python_version < '3.8' +Requires-Dist: platformdirs<5,>=3.9.1 +Provides-Extra: docs +Requires-Dist: furo>=2023.7.26; extra == 'docs' +Requires-Dist: proselint>=0.13; extra == 'docs' +Requires-Dist: sphinx!=7.3,>=7.1.2; extra == 'docs' +Requires-Dist: sphinx-argparse>=0.4; extra == 'docs' +Requires-Dist: sphinxcontrib-towncrier>=0.2.1a0; extra == 'docs' +Requires-Dist: towncrier>=23.6; extra == 'docs' +Provides-Extra: test +Requires-Dist: covdefaults>=2.3; extra == 'test' +Requires-Dist: coverage-enable-subprocess>=1; extra == 'test' +Requires-Dist: coverage>=7.2.7; extra == 'test' +Requires-Dist: flaky>=3.7; extra == 'test' +Requires-Dist: packaging>=23.1; extra == 'test' +Requires-Dist: pytest-env>=0.8.2; extra == 'test' +Requires-Dist: pytest-freezer>=0.4.8; (platform_python_implementation == 'PyPy' or (platform_python_implementation == 'CPython' and sys_platform == 'win32' and python_version >= '3.13')) and extra == 'test' +Requires-Dist: pytest-mock>=3.11.1; extra == 'test' +Requires-Dist: pytest-randomly>=3.12; extra == 'test' +Requires-Dist: pytest-timeout>=2.1; extra == 'test' +Requires-Dist: pytest>=7.4; extra == 'test' +Requires-Dist: setuptools>=68; extra == 'test' +Requires-Dist: time-machine>=2.10; (platform_python_implementation == 'CPython') and extra == 'test' +Description-Content-Type: text/markdown + +# virtualenv + +[![PyPI](https://img.shields.io/pypi/v/virtualenv?style=flat-square)](https://pypi.org/project/virtualenv) +[![PyPI - Implementation](https://img.shields.io/pypi/implementation/virtualenv?style=flat-square)](https://pypi.org/project/virtualenv) +[![PyPI - Python Version](https://img.shields.io/pypi/pyversions/virtualenv?style=flat-square)](https://pypi.org/project/virtualenv) +[![Documentation](https://readthedocs.org/projects/virtualenv/badge/?version=latest&style=flat-square)](http://virtualenv.pypa.io) +[![Discord](https://img.shields.io/discord/803025117553754132)](https://discord.gg/pypa) +[![Downloads](https://static.pepy.tech/badge/virtualenv/month)](https://pepy.tech/project/virtualenv) +[![PyPI - License](https://img.shields.io/pypi/l/virtualenv?style=flat-square)](https://opensource.org/licenses/MIT) +[![check](https://github.com/pypa/virtualenv/actions/workflows/check.yaml/badge.svg)](https://github.com/pypa/virtualenv/actions/workflows/check.yaml) + +A tool for creating isolated `virtual` python environments. + +- [Installation](https://virtualenv.pypa.io/en/latest/installation.html) +- [Documentation](https://virtualenv.pypa.io) +- [Changelog](https://virtualenv.pypa.io/en/latest/changelog.html) +- [Issues](https://github.com/pypa/virtualenv/issues) +- [PyPI](https://pypi.org/project/virtualenv) +- [Github](https://github.com/pypa/virtualenv) + +## Code of Conduct + +Everyone interacting in the virtualenv project's codebases, issue trackers, chat rooms, and mailing lists is expected to +follow the [PSF Code of Conduct](https://github.com/pypa/.github/blob/main/CODE_OF_CONDUCT.md). diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/RECORD b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/RECORD new file mode 100644 index 0000000000000000000000000000000000000000..2211db7e9c36c387fa264e60ebdccd4708ab5f6b --- /dev/null +++ b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/RECORD @@ -0,0 +1,202 @@ +../../../bin/virtualenv,sha256=bhPcXjbBDsOjvrr17wgoxUbdurGY-QAw--jKtS-zHWM,248 +virtualenv-20.29.1.dist-info/INSTALLER,sha256=zuuue4knoyJ-UwPPXg8fezS7VCrXJQrAP7zeNuwvFQg,4 +virtualenv-20.29.1.dist-info/METADATA,sha256=3FwonyD9bwcR4IOFFl4ToEm9PSzddcDRR9cBRmtsEuU,4466 +virtualenv-20.29.1.dist-info/RECORD,, +virtualenv-20.29.1.dist-info/REQUESTED,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv-20.29.1.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87 +virtualenv-20.29.1.dist-info/entry_points.txt,sha256=AZly5CLXNaFe4Ib7lhw_NffJc6059sN8WYsVXOkdj34,1278 +virtualenv-20.29.1.dist-info/licenses/LICENSE,sha256=XBWRk3jFsqqrexnOpw2M3HX3aHnjJFTkwDmfi3HRcek,1074 +virtualenv/__init__.py,sha256=Xgxz-UdfWM8x8Waxcn9Lb50VamQJ6VtQi6CYwnSO-nM,183 +virtualenv/__main__.py,sha256=cj9pmSCuFGCq2BDSG0W451IxJiZOMxh3jDVyT7wP2X4,2743 +virtualenv/__pycache__/__init__.cpython-310.pyc,, +virtualenv/__pycache__/__main__.cpython-310.pyc,, +virtualenv/__pycache__/info.cpython-310.pyc,, +virtualenv/__pycache__/report.cpython-310.pyc,, +virtualenv/__pycache__/version.cpython-310.pyc,, +virtualenv/activation/__init__.py,sha256=usYC7WoMVgHu2ybcPhz6F2OPkBNS4IiuHW77Gv_s4SM,464 +virtualenv/activation/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/__pycache__/activator.cpython-310.pyc,, +virtualenv/activation/__pycache__/via_template.cpython-310.pyc,, +virtualenv/activation/activator.py,sha256=l_KpaUpE-sG82axgF9vz4ng3QtoJox3rkzOn1vynPTM,1419 +virtualenv/activation/bash/__init__.py,sha256=-gJPcAs3VEY2EP5URBsUaXTHrlQGamSyNO6E4ohe8pw,334 +virtualenv/activation/bash/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/bash/activate.sh,sha256=YfUoH9KSXNKKIk1FLHxO4fD6VpD3munV81Z164AsY_c,2270 +virtualenv/activation/batch/__init__.py,sha256=p9VSdsxBxWOZCExupbd5y6XMNynUCgH4JE02U3Tcq1c,756 +virtualenv/activation/batch/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/batch/activate.bat,sha256=c1FAMDQlAzjb8lpFXS7Oaq1N4iReyG8riAHmq4X9N2M,1457 +virtualenv/activation/batch/deactivate.bat,sha256=07F0HsJ5cs1VpOxPyR8LFqBgNRD2TPhK4NNxF6NIRas,537 +virtualenv/activation/batch/pydoc.bat,sha256=pVuxn8mn9P_Rd0349fiBEiwIuMvfJQSfgJ2dljUT2fA,24 +virtualenv/activation/cshell/__init__.py,sha256=ZUCemt69joL0KoBSqHQILHTbVeCXjSMpOL9IIofrw6Y,336 +virtualenv/activation/cshell/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/cshell/activate.csh,sha256=Ayh2k6bO1T-gLhqSqewMa-TVjIAhxmv6VN5Mk9dInRA,1527 +virtualenv/activation/fish/__init__.py,sha256=gi0Q2mhmsHLtN_vm2Ck6m_tg6ixmJ5BGQ9SZJDjOHVE,241 +virtualenv/activation/fish/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/fish/activate.fish,sha256=JB1wsAeB_3fIwDWchEpT-BB9iNemjgl-kJhnmfV_DUs,3089 +virtualenv/activation/nushell/__init__.py,sha256=suMVpehUTmxv3MpITh7W2fa6MweRjVFs1SY-WzNHVDc,1205 +virtualenv/activation/nushell/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/nushell/activate.nu,sha256=WAL7OB7ywDM9ZtrgUUrZFlwvhr0V_24Y8ue5gqyijOc,2772 +virtualenv/activation/powershell/__init__.py,sha256=A3H7keFmOngsn821tnt1Y4Ms3lsxM62jdWVxVb6_OZ0,823 +virtualenv/activation/powershell/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/powershell/activate.ps1,sha256=PdtKOwW9w4kFwVqNyrCvCLQ1Vtz1-JVcO66WHK-dtWY,1708 +virtualenv/activation/python/__init__.py,sha256=mLxIDdV7rTjC6pfxzeCbAfsGRryoqIGFQri4hcqWzE4,830 +virtualenv/activation/python/__pycache__/__init__.cpython-310.pyc,, +virtualenv/activation/python/__pycache__/activate_this.cpython-310.pyc,, +virtualenv/activation/python/activate_this.py,sha256=CHY9wIkzvFIVzSZZPeDGN5VeHgBRdfYf-9xge_h6epw,1305 +virtualenv/activation/via_template.py,sha256=RLqcAsBa79oQxyYNVbHRSkN64HXx7ItKvSv57_Ee6C4,3043 +virtualenv/app_data/__init__.py,sha256=FafIXaRtdKwiZ56jmOJmmbmzFrDFQnizrXEaVC-KWUc,1467 +virtualenv/app_data/__pycache__/__init__.cpython-310.pyc,, +virtualenv/app_data/__pycache__/base.cpython-310.pyc,, +virtualenv/app_data/__pycache__/na.cpython-310.pyc,, +virtualenv/app_data/__pycache__/read_only.cpython-310.pyc,, +virtualenv/app_data/__pycache__/via_disk_folder.cpython-310.pyc,, +virtualenv/app_data/__pycache__/via_tempdir.cpython-310.pyc,, +virtualenv/app_data/base.py,sha256=NTlg2lAEHXV3nehGihy1KLyqTorDcmPvpR9caWepFnw,2083 +virtualenv/app_data/na.py,sha256=9ye51rBg5Ywz2i58s6b6XxdBeHvuIIgGmXO65P5eLFo,1500 +virtualenv/app_data/read_only.py,sha256=C4jfyONJLVPAKUKE7QMHBAk_adfhmWK31xX_7TLxCc4,1113 +virtualenv/app_data/via_disk_folder.py,sha256=F17_a_jl4Ky0ZAJ7bCQs-8WJ6afcMUfgIlCRgkIltp8,5535 +virtualenv/app_data/via_tempdir.py,sha256=bnW_PRpl7ddNX6V5F5u9y_n1XIoyrw_nlyRqF5uFsEU,811 +virtualenv/config/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/config/__pycache__/__init__.cpython-310.pyc,, +virtualenv/config/__pycache__/convert.cpython-310.pyc,, +virtualenv/config/__pycache__/env_var.cpython-310.pyc,, +virtualenv/config/__pycache__/ini.cpython-310.pyc,, +virtualenv/config/cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/config/cli/__pycache__/__init__.cpython-310.pyc,, +virtualenv/config/cli/__pycache__/parser.cpython-310.pyc,, +virtualenv/config/cli/parser.py,sha256=p3f0_8vhCX0P9mGUB6XlgKZD3rRAWevM8n9FLw4pfHE,4638 +virtualenv/config/convert.py,sha256=JS3yuKrztQe6R9TYrJt8QR2P1d-2cyeJ18fXpwJ5xpQ,2792 +virtualenv/config/env_var.py,sha256=sEC6c3u63bEZ6AC218QgzgLlxMZggBoTAq9s5xnYm9U,748 +virtualenv/config/ini.py,sha256=CgIXQo5JWM5wjB0nxPk_hmuj6BjjCN7qVkHdDOOarao,2706 +virtualenv/create/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/create/__pycache__/__init__.cpython-310.pyc,, +virtualenv/create/__pycache__/creator.cpython-310.pyc,, +virtualenv/create/__pycache__/debug.cpython-310.pyc,, +virtualenv/create/__pycache__/describe.cpython-310.pyc,, +virtualenv/create/__pycache__/pyenv_cfg.cpython-310.pyc,, +virtualenv/create/creator.py,sha256=W1K6xBrXbj_9YStkEVe-lnM0TRzw21Q0HQZRsSuEbXU,9205 +virtualenv/create/debug.py,sha256=tjQToAjvU0MUQZEUOugoB3l7UPIKNJRPRBnaLKQDVcI,3149 +virtualenv/create/describe.py,sha256=OgGhSQJwM4NV_ECX-U9MgeKWl8qIn3Pj-ModMnumQWY,3154 +virtualenv/create/pyenv_cfg.py,sha256=sRTbgcsPbxjark2xOXMc0vAQDUAf2RGqN9dKgtA-oOw,1825 +virtualenv/create/via_global_ref/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/create/via_global_ref/__pycache__/__init__.cpython-310.pyc,, +virtualenv/create/via_global_ref/__pycache__/_virtualenv.cpython-310.pyc,, +virtualenv/create/via_global_ref/__pycache__/api.cpython-310.pyc,, +virtualenv/create/via_global_ref/__pycache__/store.cpython-310.pyc,, +virtualenv/create/via_global_ref/__pycache__/venv.cpython-310.pyc,, +virtualenv/create/via_global_ref/_virtualenv.py,sha256=DyA1HqfpADnEbT-r3vmR8oseP_M-sT7m8NXNIeoOixQ,4443 +virtualenv/create/via_global_ref/api.py,sha256=AbWJVLwzKxQ2QOFEV5XtwVmCNqZ8958vfYGoRBTNXDk,4288 +virtualenv/create/via_global_ref/builtin/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/create/via_global_ref/builtin/__pycache__/__init__.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/__pycache__/builtin_way.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/__pycache__/ref.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/__pycache__/via_global_self_do.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/builtin_way.py,sha256=gcw1jAjMKLfCVRKbZKRGoqixsmGXt8YuiH2NYPKI-Lg,520 +virtualenv/create/via_global_ref/builtin/cpython/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/create/via_global_ref/builtin/cpython/__pycache__/__init__.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/cpython/__pycache__/common.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/cpython/__pycache__/cpython3.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/cpython/__pycache__/mac_os.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/cpython/common.py,sha256=FKWPp0UAq7lFX_vcBCJAZQS6qzN6uo73d0ST8DI-EkM,2513 +virtualenv/create/via_global_ref/builtin/cpython/cpython3.py,sha256=HBt9OKqjvAXRWvz6rvyVA9WB-n6gKk_agakVzqGMd6c,4789 +virtualenv/create/via_global_ref/builtin/cpython/mac_os.py,sha256=e0LWrkbqROtz0UkRROwjDE6p91tmSMRhC3K-GuGZUJg,11669 +virtualenv/create/via_global_ref/builtin/pypy/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/create/via_global_ref/builtin/pypy/__pycache__/__init__.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/pypy/__pycache__/common.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/pypy/__pycache__/pypy3.cpython-310.pyc,, +virtualenv/create/via_global_ref/builtin/pypy/common.py,sha256=WwjoRRzPqQKiRdgkLfPKiYOPWMyx4KkG2XyRDCTTZ3I,1716 +virtualenv/create/via_global_ref/builtin/pypy/pypy3.py,sha256=srpqZzZWb7bdGSZk5YNPOPEJZ5cb7Wf8eISEcvlX7FU,2494 +virtualenv/create/via_global_ref/builtin/ref.py,sha256=96T97fbI3BECmwSHNeV8Sty469GJKYPIiZeSEWNatwc,5433 +virtualenv/create/via_global_ref/builtin/via_global_self_do.py,sha256=zTjsxnASAwMFgI8tvB3YK0FSfPM08B3O6QM7DGQgF0M,4430 +virtualenv/create/via_global_ref/store.py,sha256=OVRyaMUBT7Kh_sEy02m5VsHvh0tpxynpKxLjXDDXb1c,667 +virtualenv/create/via_global_ref/venv.py,sha256=TxKXeyA2va0TWsK3sll47b_4rvlUHhSFEosgczUdOmk,3702 +virtualenv/discovery/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/discovery/__pycache__/__init__.cpython-310.pyc,, +virtualenv/discovery/__pycache__/builtin.cpython-310.pyc,, +virtualenv/discovery/__pycache__/cached_py_info.cpython-310.pyc,, +virtualenv/discovery/__pycache__/discover.cpython-310.pyc,, +virtualenv/discovery/__pycache__/py_info.cpython-310.pyc,, +virtualenv/discovery/__pycache__/py_spec.cpython-310.pyc,, +virtualenv/discovery/builtin.py,sha256=s4n7OVyIvQlsmEx04jbddPQYMjYM6hI-pibagZw0yIc,8193 +virtualenv/discovery/cached_py_info.py,sha256=eU9UKU7rDWKD9Y-44zJTAsGCo8EBd-AsASUVx6AvsTs,6612 +virtualenv/discovery/discover.py,sha256=St6Kh8w5PudqlB1IuAWaNpzfLfB9NrIlqpNU2h6C-lA,1173 +virtualenv/discovery/py_info.py,sha256=tq5Nkqp5flV9FbZR33JrZrLNexyPSOdngIh6wSuxvDc,25966 +virtualenv/discovery/py_spec.py,sha256=oEYEdBmK8oev9EhGVBeifSVfwWM-KyPvwy2A96xnM14,5034 +virtualenv/discovery/windows/__init__.py,sha256=tsPXcRdmIO20rb_bVDFVwXxANbniHW28FSOJ6I0_zw4,1889 +virtualenv/discovery/windows/__pycache__/__init__.cpython-310.pyc,, +virtualenv/discovery/windows/__pycache__/pep514.cpython-310.pyc,, +virtualenv/discovery/windows/pep514.py,sha256=LXpkQf9NLmXyEvf2k7NSmS0aVqjN18PoytwtPUV18uI,5644 +virtualenv/info.py,sha256=cq7uiuQgSTfBM12RLSm5ZTgAVcQb01peWEQkXVGOGl0,2017 +virtualenv/report.py,sha256=YFUjwNWNQXPB1cAeH5OAl0pl7BVZzxsAYD-2aidzuJA,1354 +virtualenv/run/__init__.py,sha256=4GXLmPoWqg7krVttq3c70twJycZSes8oeKTl0MonRqY,6244 +virtualenv/run/__pycache__/__init__.cpython-310.pyc,, +virtualenv/run/__pycache__/session.cpython-310.pyc,, +virtualenv/run/plugin/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/run/plugin/__pycache__/__init__.cpython-310.pyc,, +virtualenv/run/plugin/__pycache__/activators.cpython-310.pyc,, +virtualenv/run/plugin/__pycache__/base.cpython-310.pyc,, +virtualenv/run/plugin/__pycache__/creators.cpython-310.pyc,, +virtualenv/run/plugin/__pycache__/discovery.cpython-310.pyc,, +virtualenv/run/plugin/__pycache__/seeders.cpython-310.pyc,, +virtualenv/run/plugin/activators.py,sha256=rNo8gEM7Tqk0NFV8RWX8RlrZcmHc13-8R7WF8pO2bLU,2235 +virtualenv/run/plugin/base.py,sha256=B9saI-0WZHjsQeu_yx7iIFhNoVfgoMknlKlPDVdA4j0,2096 +virtualenv/run/plugin/creators.py,sha256=hMQQX51lp-t1HdV7zvJaAIqIg_tXYVF_DYtXh2XXjZo,3626 +virtualenv/run/plugin/discovery.py,sha256=va7Xj6Bn3QD1oZJ6WqrisH6sB9xHZoK81rHmsFnWhdw,1180 +virtualenv/run/plugin/seeders.py,sha256=up_Ai5SsBzqSGfWonlQMgiIKs8NJon6WtxI8CINx1vk,1050 +virtualenv/run/session.py,sha256=IjJVBp2mpuyI2Ksh10Z24sZ3Cpq1l-iXG1xmvxxE2TQ,2487 +virtualenv/seed/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/seed/__pycache__/__init__.cpython-310.pyc,, +virtualenv/seed/__pycache__/seeder.cpython-310.pyc,, +virtualenv/seed/embed/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/seed/embed/__pycache__/__init__.cpython-310.pyc,, +virtualenv/seed/embed/__pycache__/base_embed.cpython-310.pyc,, +virtualenv/seed/embed/__pycache__/pip_invoke.cpython-310.pyc,, +virtualenv/seed/embed/base_embed.py,sha256=nVZwY7RnZBA1wGttLC4tvOIUsYBaQUZQh6UFF7gq17s,4219 +virtualenv/seed/embed/pip_invoke.py,sha256=O9TVzu6LG2WoFqVxhrNeUY9GqsZc-w6T82OfGO59SUk,2237 +virtualenv/seed/embed/via_app_data/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/seed/embed/via_app_data/__pycache__/__init__.cpython-310.pyc,, +virtualenv/seed/embed/via_app_data/__pycache__/via_app_data.cpython-310.pyc,, +virtualenv/seed/embed/via_app_data/pip_install/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/seed/embed/via_app_data/pip_install/__pycache__/__init__.cpython-310.pyc,, +virtualenv/seed/embed/via_app_data/pip_install/__pycache__/base.cpython-310.pyc,, +virtualenv/seed/embed/via_app_data/pip_install/__pycache__/copy.cpython-310.pyc,, +virtualenv/seed/embed/via_app_data/pip_install/__pycache__/symlink.cpython-310.pyc,, +virtualenv/seed/embed/via_app_data/pip_install/base.py,sha256=CKRktWcK1WAuFafQZW9fkgap4QkLRgbHx04uMnYaYS0,8336 +virtualenv/seed/embed/via_app_data/pip_install/copy.py,sha256=g-vzGeo0RuWiV_e5OaMvPL1Oz_oHzSzGfkhAirNFcPE,1240 +virtualenv/seed/embed/via_app_data/pip_install/symlink.py,sha256=sBSLyrsp244DYIpC2AIWdR-UoqospLEKUTsG3jQAU5g,2015 +virtualenv/seed/embed/via_app_data/via_app_data.py,sha256=_vfxj5-4HsiIOHxVTJlNvVn_53M5e3IRfuaefKMbHJM,5910 +virtualenv/seed/seeder.py,sha256=Ao-b5mtuQJWfpJigJ8WYHTRdQzYC0btQ1rkHn1fkcig,1155 +virtualenv/seed/wheels/__init__.py,sha256=rN6_NcnOOrsaIgPv18aYNwoTfeP10c0J5GjF8u6WMtc,204 +virtualenv/seed/wheels/__pycache__/__init__.cpython-310.pyc,, +virtualenv/seed/wheels/__pycache__/acquire.cpython-310.pyc,, +virtualenv/seed/wheels/__pycache__/bundle.cpython-310.pyc,, +virtualenv/seed/wheels/__pycache__/periodic_update.cpython-310.pyc,, +virtualenv/seed/wheels/__pycache__/util.cpython-310.pyc,, +virtualenv/seed/wheels/acquire.py,sha256=9VnXwSTALn8kumvWPwIxBn1V484PdpD7eUozntP-cXA,4588 +virtualenv/seed/wheels/bundle.py,sha256=Ub8PxmsuovpuB1ns-74BuAGcuxjUEL_gfWoOoMW1Q28,1863 +virtualenv/seed/wheels/embed/__init__.py,sha256=RVhQzqbJwB4cldA9vaHcLKsW-VExqCoyR_qw-fPAjbA,1716 +virtualenv/seed/wheels/embed/__pycache__/__init__.cpython-310.pyc,, +virtualenv/seed/wheels/embed/pip-24.3.1-py3-none-any.whl,sha256=N5BiR4AII2X0dUnQMvN3DusrHovR97LgLazhr6NhtO0,1822182 +virtualenv/seed/wheels/embed/setuptools-75.3.0-py3-none-any.whl,sha256=8lBJZoYTVqo4YWdgwPZlaOU1ViN0mVNntOaccUPPa80,1251070 +virtualenv/seed/wheels/embed/setuptools-75.8.0-py3-none-any.whl,sha256=45gvREYXI5Il1nUhXVH2ugX4RdTuwxPaRBj9u1b7J-M,1228782 +virtualenv/seed/wheels/embed/wheel-0.45.1-py3-none-any.whl,sha256=cI50gcyAF5rw5Va78MwAuERMcyHicAuNhYAjHRMBckg,72494 +virtualenv/seed/wheels/periodic_update.py,sha256=lH35tZH91nY1m4BI55bu8lVJduwz8RvY_fNxe-7KF8I,15586 +virtualenv/seed/wheels/util.py,sha256=cNZBMglOXir5LKC8M1-s2GZHyCt65vJKegyL7kg6Zg0,3962 +virtualenv/util/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0 +virtualenv/util/__pycache__/__init__.cpython-310.pyc,, +virtualenv/util/__pycache__/error.cpython-310.pyc,, +virtualenv/util/__pycache__/lock.cpython-310.pyc,, +virtualenv/util/__pycache__/zipapp.cpython-310.pyc,, +virtualenv/util/error.py,sha256=qglTAnbZCj5qKaK9iNka44gfOA0vc2S0FRhLTL4gijo,323 +virtualenv/util/lock.py,sha256=t5LA8FDFVMofnvcqezwbIuAXHf1SR46ggIY_iPYgSTI,4786 +virtualenv/util/path/__init__.py,sha256=Ujv6toeiy-5uw4yPfnG7ZFvoxYs8J4JMQOiT3IWoimg,340 +virtualenv/util/path/__pycache__/__init__.cpython-310.pyc,, +virtualenv/util/path/__pycache__/_permission.cpython-310.pyc,, +virtualenv/util/path/__pycache__/_sync.cpython-310.pyc,, +virtualenv/util/path/__pycache__/_win.cpython-310.pyc,, +virtualenv/util/path/_permission.py,sha256=cJntuU9FT_VjaO_AvKArDud4-ZmgdUEY9bBGWd83-cs,665 +virtualenv/util/path/_sync.py,sha256=6ua3XQxsINrkc8C6xwHl2S9iH_TeH-pm-FkWRcH_4UU,2121 +virtualenv/util/path/_win.py,sha256=ymVUtPCmAc3wCYMY4syCACFcaeFPrTJluze8UG8IpLU,803 +virtualenv/util/subprocess/__init__.py,sha256=BUsxWu7PUugQGXTl9dq0eem3tjkug7_1H0yWgCV2VVM,735 +virtualenv/util/subprocess/__pycache__/__init__.cpython-310.pyc,, +virtualenv/util/zipapp.py,sha256=zUZcc5MVmeJkXeEu5RtNiqK8fVe8F84MjeTR-uXWP4I,1246 +virtualenv/version.py,sha256=K17C6mdjbDne8by-6Tw0rT0LatFj5OYlOetKm70EDw4,415 diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/REQUESTED b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/REQUESTED new file mode 100644 index 0000000000000000000000000000000000000000..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/WHEEL b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/WHEEL new file mode 100644 index 0000000000000000000000000000000000000000..12228d414b6cfed7c39d3781c85c63256a1d7fb5 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/WHEEL @@ -0,0 +1,4 @@ +Wheel-Version: 1.0 +Generator: hatchling 1.27.0 +Root-Is-Purelib: true +Tag: py3-none-any diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/entry_points.txt b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/entry_points.txt new file mode 100644 index 0000000000000000000000000000000000000000..a284e0a8283d25cae3eb47abbf9a0a1ce3a1dfc5 --- /dev/null +++ b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/entry_points.txt @@ -0,0 +1,27 @@ +[console_scripts] +virtualenv = virtualenv.__main__:run_with_catch + +[virtualenv.activate] +bash = virtualenv.activation.bash:BashActivator +batch = virtualenv.activation.batch:BatchActivator +cshell = virtualenv.activation.cshell:CShellActivator +fish = virtualenv.activation.fish:FishActivator +nushell = virtualenv.activation.nushell:NushellActivator +powershell = virtualenv.activation.powershell:PowerShellActivator +python = virtualenv.activation.python:PythonActivator + +[virtualenv.create] +cpython3-mac-brew = virtualenv.create.via_global_ref.builtin.cpython.mac_os:CPython3macOsBrew +cpython3-mac-framework = virtualenv.create.via_global_ref.builtin.cpython.mac_os:CPython3macOsFramework +cpython3-posix = virtualenv.create.via_global_ref.builtin.cpython.cpython3:CPython3Posix +cpython3-win = virtualenv.create.via_global_ref.builtin.cpython.cpython3:CPython3Windows +pypy3-posix = virtualenv.create.via_global_ref.builtin.pypy.pypy3:PyPy3Posix +pypy3-win = virtualenv.create.via_global_ref.builtin.pypy.pypy3:Pypy3Windows +venv = virtualenv.create.via_global_ref.venv:Venv + +[virtualenv.discovery] +builtin = virtualenv.discovery.builtin:Builtin + +[virtualenv.seed] +app-data = virtualenv.seed.embed.via_app_data.via_app_data:FromAppData +pip = virtualenv.seed.embed.pip_invoke:PipInvoke diff --git a/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/licenses/LICENSE b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/licenses/LICENSE new file mode 100644 index 0000000000000000000000000000000000000000..be9700d61a3a0e9f5c6a74f93d187f1805c7acbf --- /dev/null +++ b/vllm/lib/python3.10/site-packages/virtualenv-20.29.1.dist-info/licenses/LICENSE @@ -0,0 +1,20 @@ +Copyright (c) 2020-202x The virtualenv developers + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.