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

Avoid running neuron integration tests twice #3054

Merged
merged 9 commits into from
Feb 26, 2025
Merged

Conversation

dacorvo
Copy link
Collaborator

@dacorvo dacorvo commented Feb 25, 2025

What does this PR do?

This modifies the neuron integration-tests fixture that compiles and exports models before running tests to be able to run it as a script and export all neuron test models at once.

The script is now called during the precompile_neuron_models CI step instead of running the full integration tests.

This also updates the documentation to fix some obsolete links.

@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@dacorvo dacorvo force-pushed the avoid_testing_neuron_twice branch from 7f94375 to 9b213b4 Compare February 25, 2025 11:35
@dacorvo dacorvo marked this pull request as ready for review February 25, 2025 13:08
@dacorvo dacorvo requested review from Narsil and tengomucho February 25, 2025 13:09
Copy link
Contributor

@tengomucho tengomucho left a comment

Choose a reason for hiding this comment

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

LGTM, just two questions

@@ -224,3 +229,7 @@ def neuron_model_config(request):
@pytest.fixture(scope="module")
def neuron_model_path(neuron_model_config):
yield neuron_model_config["neuron_model_path"]


if __name__ == "__main__":
Copy link
Contributor

Choose a reason for hiding this comment

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

why do you need a main here, aren't you going to run it as a test only?

Copy link
Contributor

Choose a reason for hiding this comment

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

OK I got my answer, you run it on the workflow to export models.

@@ -13,3 +13,4 @@ TGI remains consistent across backends, allowing you to switch between them seam
However, it requires a model-specific compilation step for each GPU architecture.
* **[TGI Llamacpp backend](./backends/llamacpp)**: This backend facilitates the deployment of large language models
(LLMs) by integrating [llama.cpp][llama.cpp], an advanced inference engine optimized for both CPU and GPU computation.
* **[TGI Neuron backend](./backends/neuron)**: This backend leverages the [AWS Neuron SDK](https://awsdocs-neuron.readthedocs-hosted.com/en/latest/) to allow the deployment of large language models (LLMs) on [AWS Trainium and Inferentia chips](https://aws.amazon.com/ai/machine-learning/trainium/).
Copy link
Contributor

Choose a reason for hiding this comment

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

do they run also on trainium?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Yes.

@dacorvo dacorvo requested a review from tengomucho February 25, 2025 14:52
@dacorvo dacorvo force-pushed the avoid_testing_neuron_twice branch from 92d2e6f to b370902 Compare February 26, 2025 08:47
@dacorvo dacorvo merged commit 5eec3a8 into main Feb 26, 2025
26 of 27 checks passed
@dacorvo dacorvo deleted the avoid_testing_neuron_twice branch February 26, 2025 11:15
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.

4 participants