Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remove owned_session #1097

Merged
merged 4 commits into from
Feb 4, 2024
Merged

remove owned_session #1097

merged 4 commits into from
Feb 4, 2024

Conversation

grimoire
Copy link
Collaborator

@grimoire grimoire commented Feb 1, 2024

session is no longer bind to EngineInstance.

Tested on chat and profile_pytorch_benchmark with llama-7b

Copy link
Collaborator

@AllentDan AllentDan left a comment

Choose a reason for hiding this comment

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

I've tested OK for both pytorch and turbomind concurrency. But there is a VRAM increase during benchmarking restful API for pytorch backend.

@AllentDan
Copy link
Collaborator

Besides, the performance gap between benchmark/profile_torch_throughput.py and benchmark/profile_restful_api.py is far larger than turbomind backend.

@AllentDan
Copy link
Collaborator

I found for api_server, if I make requests on 64 concurrency, the actual concurrency for the pytorch backend is only 10+. Do you have any clue about it?

@grimoire
Copy link
Collaborator Author

grimoire commented Feb 2, 2024

queue get will block cpu on coroutine. I have update an version with async recv. in 6b6dcae

But since all tokenizer are processed on the same cpu with the engine, it still can not reach the performance of profile throughput.

Copy link
Collaborator

@AllentDan AllentDan left a comment

Choose a reason for hiding this comment

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

LGTM

Conflicts:
	lmdeploy/serve/async_engine.py
	lmdeploy/tokenizer.py
@lvhan028 lvhan028 merged commit c80a1ed into InternLM:main Feb 4, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants