mirror of
https://github.com/elder-plinius/OBLITERATUS.git
synced 2026-08-29 22:20:36 +02:00
test: cover Mistral shared-expert memory estimate
This commit is contained in:
@@ -5,6 +5,7 @@ from __future__ import annotations
|
||||
from types import SimpleNamespace
|
||||
|
||||
import pytest
|
||||
import torch
|
||||
import torch.nn as nn
|
||||
|
||||
from obliteratus.architecture_profiles import ArchitectureClass, detect_architecture
|
||||
@@ -144,6 +145,14 @@ def test_composite_profile_uses_text_backbone_without_misclassifying_mistral3():
|
||||
assert moe.total_params_b >= 100
|
||||
|
||||
|
||||
def test_composite_memory_estimate_counts_routed_and_shared_experts():
|
||||
config = _mistral3_config(_mistral4_text_config())
|
||||
|
||||
estimate_gb = loader._estimate_model_memory_gb(config, torch.bfloat16)
|
||||
|
||||
assert 200 < estimate_gb < 300
|
||||
|
||||
|
||||
def test_mistral_small_4_name_fallback_is_large_moe():
|
||||
profile = detect_architecture("mistralai/Mistral-Small-4-119B-2603")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user