Aggregation Modes And Event Vlines
Overview
This skill provides rules and checklists to safely design and validate aggregation_modes (aggregation/overlay/output) and event_vlines (event marker vlines and overlay-group behavior) in config-driven time-series visualization workflows.
Quick Start (작업 절차)
- •Inspect the
aggregation_modes/event_vlinesblocks inconfig.yaml. - •When you need to confirm “what really happens”, search the implementation for the keywords below to find the exact branch (OLD vs NEW):
- •
overlay_within,filename_pattern,_apply_filter_indices,_collect_event_vlines,overlay_group
- •
- •Before changing configs, make
groupby/overlay_within/filename_patternconsistent using the safety rules below. - •Open
references/aggregation-modes-and-event-vlines.en.mdfor the full spec and examples.
핵심 안전 규칙(요약)
- •
aggregation_modes.<mode>.filtermust be a dict and is applied as an AND of all conditions. (If a column is missing, the implementation may warn and skip that condition.) - •With
overlay=true, file splitting depends on whetheroverlay_withinis set:- •If
overlay_withinis missing/empty (OLD behavior): all group keys are overlaid into a single output file. - •If
overlay_withinis provided (NEW behavior):file_fields = groupby - overlay_within; files split byfile_fields, with overlays within each file.
- •If
- •
filename_patternusesstr.format(). Under overlay NEW behavior, using placeholders that are not present infile_fieldscan raiseKeyError. - •
color_bytypically derives its values from the group key; in practice,color_by ⊆ groupbyis the safest rule. - •
event_vlines.overlay_groupis for drawing selected events per overlay group (typically via different linestyles). Events listed inoverlay_group.columnsare usually removed from pooled vlines to avoid duplicates.
자주 나는 문제(증상 → 원인 → 해결)
- •“I expected multiple files, but only one file was produced”
- •Cause:
overlay=truewithoverlay_withinmissing/empty → OLD behavior overlays everything into one file. - •Fix: set
overlay_withinand ensure your intended split criteria remains infile_fields = groupby - overlay_within.
- •Cause:
- •“KeyError while generating png”
- •Cause:
filename_patternincludes a{placeholder}that is not present in the formatting mapping (common under overlay NEW behavior). - •Fix: in overlay NEW, only use placeholders from
file_fields, or simplify to{signal_group}.
- •Cause:
- •“Filters don’t seem to apply”
- •Cause: (1) missing column (condition is skipped), (2) type mismatch (e.g.,
10vs10.0). - •Fix: verify column existence/types in the dataset and match the config value types accordingly.
- •Cause: (1) missing column (condition is skipped), (2) type mismatch (e.g.,
- •“Event vlines don’t show up”
- •Cause: (1) event column missing in input/features, (2) mean event timing falls outside the plotted time window.
- •Fix: check
event_vlines.columns, the event domain source (input parquet vs features file), and theinterpolation.start_ms/end_msrange.
Reference
- •Full spec, schema, and example YAML:
references/aggregation-modes-and-event-vlines.en.md