Skip to content

Conversation

mgoin
Copy link
Member

@mgoin mgoin commented Apr 12, 2025

The only reason why scipy is a common dependency of vLLM is because phi4mm requires it for resample_poly (see discussion in the PR #14119 (comment)). Since it isn't that complex of a function, we can implement it in a couple dozen lines of numpy and remove scipy.

Needs more testing to validate

Copy link

👋 Hi! Thank you for contributing to the vLLM project.

💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in #pr-reviews, coordinate on features in #feat- channels, or join special interest groups in #sig- channels.

Just a reminder: PRs would not trigger full CI run by default. Instead, it would only run fastcheck CI which starts running only a small and essential subset of CI tests to quickly catch errors. You can run other CI tests on top of those by going to your fastcheck build on Buildkite UI (linked in the PR checks section) and unblock them. If you do not have permission to unblock, ping simon-mo or khluu to add you in our Buildkite org.

Once the PR is approved and ready to go, your PR reviewer(s) can run CI to test the changes comprehensively before merging.

To run CI, PR reviewers can either: Add ready label to the PR or enable auto-merge.

🚀

@mergify mergify bot added the ci/build label Apr 12, 2025
@DarkLight1337 DarkLight1337 requested a review from Isotr0py April 14, 2025 02:37
Copy link
Member

@Isotr0py Isotr0py left a comment

Choose a reason for hiding this comment

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

I'm afraid that if we finally refactor Phi-4-MM to use merged processor in #15477, scipy will still be a necessary dep to make hf_processor work, because it's at the import level in processing_phi4mm.py.
(https://huggingface.co/microsoft/Phi-4-multimodal-instruct/blob/main/processing_phi4mm.py#L24)

@Isotr0py
Copy link
Member

@mgoin FYI, HF plans to convert Phi4-mm model repo to HF format, which includes fast image processor and feature extractor implemented with torch, so that we no longer need scipy in requirements after that. (https://huggingface.co/microsoft/Phi-4-multimodal-instruct/discussions/70)

I'm starting to implement HF format Phi-4-MM here: #17121, so let's leave scipy to be removed after this migration!

@mgoin mgoin closed this Jul 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants