Skip to content

Conversation

gururajkosuru
Copy link

Summary

This PR adds comprehensive unit tests for the Gemma3 model architecture, which was added in #3172, #3178, #3224 but lacked test coverage.

Changes

  • Add tests/python/model/test_gemma3.py with test cases:
    • test_gemma3_model_registered: Verify model is in registry
    • test_gemma3_creation: Test model creation and TVM export (gemma3_2b, gemma3_9b)
    • test_gemma3_config_validation: Validate configuration parameters
  • Follows pattern from test_llama.py

Testing

To run tests locally:

pytest tests/python/model/test_gemma3.py -v

Part of

Adding test coverage for recently added models (Gemma3, Qwen3, Phi-4, Llama4).

This PR adds comprehensive unit tests for the Gemma3 model architecture,
which was added in mlc-ai#3172, mlc-ai#3178, mlc-ai#3224 but lacked test coverage.

Changes:
- Add tests/python/model/test_gemma3.py with the following test cases:
  * test_gemma3_model_registered: Verify model is in registry
  * test_gemma3_creation: Test model creation and TVM export
  * test_gemma3_config_validation: Validate configuration parameters
- Tests cover gemma3_2b and gemma3_9b variants
- Follows pattern from test_llama.py

Testing:
All tests pass locally (instructions in PR description for reproduction)

Part of effort to add test coverage for recently added models.
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.

1 participant