Skip to content

Add unit tests and simplify condition - #225

Merged
apsonawane merged 10 commits into
mainfrom
asonawane/gemma
Apr 28, 2026
Merged

apsonawane merged 10 commits into
mainfrom
asonawane/gemma

Conversation

@apsonawane

Copy link
Copy Markdown
Contributor

follow up from this PR: #223

@github-actions

github-actions Bot commented Apr 28, 2026 •

Copy link
Copy Markdown

🏗️ Architecture Diff

Comparing 612abc3 → f1e51fc

Model Sub-model Changes Status

No architecture changes detected. ✅


Legend: ⚪ No change · 🔵 Minor (attrs/inits) · 🟡 Moderate (nodes added/removed) · 🔴 Major (interface changed)

@github-actions

github-actions Bot commented Apr 28, 2026 •

Copy link
Copy Markdown

Performance Comparison

Comparing 612abc3 → f1e51fc

Model Metric Baseline Current Delta
bert (feature-extraction) model_size_bytes 359 KB 359 KB +0.0% ⚪
bert (feature-extraction) num_nodes 60 60 +0.0% ⚪
falcon model_size_bytes 364 KB 364 KB +0.0% ⚪
falcon num_nodes 66 66 +0.0% ⚪
gemma2 model_size_bytes 428 KB 428 KB +0.0% ⚪
gemma2 num_nodes 107 107 +0.0% ⚪
gpt2 model_size_bytes 388 KB 388 KB +0.0% ⚪
gpt2 num_nodes 53 53 +0.0% ⚪
llama model_size_bytes 425 KB 425 KB +0.0% ⚪
llama num_nodes 61 61 +0.0% ⚪
llama (static-cache) model_size_bytes 425 KB 425 KB +0.0% ⚪
llama (static-cache) num_nodes 58 58 +0.0% ⚪
mamba (ssm-text-generation) model_size_bytes 296 KB 296 KB +0.0% ⚪
mamba (ssm-text-generation) num_nodes 98 98 +0.0% ⚪
phi3 model_size_bytes 421 KB 421 KB +0.0% ⚪
phi3 num_nodes 59 59 +0.0% ⚪
phi3 (static-cache) model_size_bytes 421 KB 421 KB +0.0% ⚪
phi3 (static-cache) num_nodes 56 56 +0.0% ⚪
qwen2 model_size_bytes 425 KB 425 KB +0.0% ⚪
qwen2 num_nodes 61 61 +0.0% ⚪
qwen2 (static-cache) model_size_bytes 425 KB 425 KB +0.0% ⚪
qwen2 (static-cache) num_nodes 58 58 +0.0% ⚪
qwen3_5_moe (hybrid-text-generation) model_size_bytes 506 KB 506 KB +0.0% ⚪
qwen3_5_moe (hybrid-text-generation) num_nodes 275 275 +0.0% ⚪
qwen3_5_text (hybrid-text-generation) model_size_bytes 458 KB 458 KB +0.0% ⚪
qwen3_5_text (hybrid-text-generation) num_nodes 129 129 +0.0% ⚪
qwen3_5_vl (hybrid-qwen-vl) model_size_bytes 977 KB 977 KB +0.0% ⚪
qwen3_5_vl (hybrid-qwen-vl) num_nodes 408 408 +0.0% ⚪
t5 (seq2seq) model_size_bytes 836 KB 836 KB +0.0% ⚪
t5 (seq2seq) num_nodes 166 166 +0.0% ⚪
whisper (speech-to-text) model_size_bytes 1008 KB 1008 KB +0.0% ⚪
whisper (speech-to-text) num_nodes 128 128 +0.0% ⚪

No performance regressions.

@codecov

codecov Bot commented Apr 28, 2026

Copy link
Copy Markdown

The author of this PR, apsonawane, is not an activated member of this organization on Codecov.
Please activate this user on Codecov to display this PR comment.
Coverage data is still being uploaded to Codecov.io for purposes of overall coverage calculations.
Please don't hesitate to email us at [email protected] with any questions.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

Follow-up to #223 to add unit coverage for Gemma4 audio processor config generation and to simplify the vision-config branching in genai_config.json generation.

Changes:

  • Added unit tests for _write_audio_processor_config() (no-audio, non-Gemma4, Gemma4 JSON schema/content).
  • Added end-to-end tests validating write_ort_genai_config() writes audio_feature_extraction.json and the Gemma4 speech section in genai_config.json.
  • Simplified the condition that determines when to attach vision config_filename / spatial_merge_size kwargs during genai_config.json generation.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/mobius/integrations/ort_genai/auto_export_test.py Adds targeted unit + end-to-end tests for Gemma4 audio processor config and genai_config.json speech section.
src/mobius/integrations/ort_genai/auto_export.py Refactors the Gemma4/has-speech branching for vision kwargs in _write_genai_config() without changing behavior.

@apsonawane
apsonawane enabled auto-merge (squash) April 28, 2026 23:30
@apsonawane
apsonawane merged commit 9e48088 into main Apr 28, 2026
19 of 21 checks passed
@apsonawane
apsonawane deleted the asonawane/gemma branch April 28, 2026 23:41
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