1

Ajouter la heatmap log des catégories et le collage des pièces imprimées

This commit is contained in:
2025-12-03 17:49:46 +01:00
parent cebe3046db
commit 107bc5b533
4 changed files with 43 additions and 0 deletions

View File

@@ -5,6 +5,7 @@ from pathlib import Path
from lib.plots.part_categories import (
plot_part_categories_heatmap,
plot_part_categories_heatmap_log,
plot_structural_share_timeline,
plot_top_part_categories_area,
)
@@ -31,15 +32,19 @@ def test_plot_part_categories_outputs_images(tmp_path: Path) -> None:
)
area_dest = tmp_path / "figures" / "step29" / "top_part_categories_area.png"
heatmap_dest = tmp_path / "figures" / "step29" / "part_categories_heatmap.png"
heatmap_log_dest = tmp_path / "figures" / "step29" / "part_categories_heatmap_log.png"
structural_dest = tmp_path / "figures" / "step29" / "structural_share_timeline.png"
plot_top_part_categories_area(by_year, by_global, area_dest, top_n=2)
plot_part_categories_heatmap(by_year, heatmap_dest)
plot_part_categories_heatmap_log(by_year, heatmap_log_dest)
plot_structural_share_timeline(by_year, structural_dest)
assert area_dest.exists()
assert heatmap_dest.exists()
assert heatmap_log_dest.exists()
assert structural_dest.exists()
assert area_dest.stat().st_size > 0
assert heatmap_dest.stat().st_size > 0
assert heatmap_log_dest.stat().st_size > 0
assert structural_dest.stat().st_size > 0