Skip to content

Conversation

rafvasq
Copy link
Collaborator

@rafvasq rafvasq commented Mar 27, 2025

Adds an online TP case - closes #57.

Copy link

👋 Hi! Thank you for contributing to vLLM support on Spyre.
Just a reminder: Make sure that your code passes all the linting checks, otherwise your PR won't be able to be merged. To do so, first install the linting requirements, then run format.sh and commit the changes:

pip install -r requirements-lint.txt
bash format.sh

Now you are good to go 🚀

Signed-off-by: Rafael Vasquez <[email protected]>
@rafvasq rafvasq changed the title Add online spyre-TP test and server util Add online TP test Mar 27, 2025
@pytest.mark.parametrize("backend", get_spyre_backend_list())
@pytest.mark.parametrize("tensor_parallel_size", [2])
@pytest.mark.parametrize("vllm_version", ["V0", "V1"])
def test_openai_serving(model, warmup_shape, backend, tensor_parallel_size,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

Any thoughts on moving this over to test_spyre_tensor_parallel.py? I kinda think we should try to start organizing these files a bit instead of creating more of them. I can also move my basic online tests over to test_spyre_basic.py

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that's cleaner, I just wonder if in the future you could see a situation where online tests would have to be refactored/separated from offline. Up to you

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, online tests are passing/exiting properly without --forked

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that's cleaner, I just wonder if in the future you could see a situation where online tests would have to be refactored/separated from offline. Up to you

Yeah... that could end up being the case as well 🤷
We can leave test organization until later

seed: Optional[int] = 0,
auto_port: bool = True,
max_wait_seconds: Optional[float] = None,
tensor_parallel_size: Optional[int] = 1) -> None:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this is only used to set args in vllm_serve_args, can we instead call this like

with RemoteOpenAIServer(
            model, ["--tensor-parallel-size", "1"], ...)

?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I updated the util and the test so that it would be called like you said but still through a pytest parameter.

@rafvasq rafvasq changed the title Add online TP test Add tensor parallel tests for online server Mar 27, 2025
Copy link
Collaborator

@joerunde joerunde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🌶️

@joerunde joerunde merged commit 10e8237 into vllm-project:main Mar 27, 2025
9 checks passed
@rafvasq rafvasq deleted the add-online-tp-test branch March 27, 2025 20:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[tests] Add online tensor parallelism test

2 participants