radioviz.tools.naming_utils

Helpers for consistent derived image naming.

This module provides utility functions to build user-friendly derived labels, ensuring tool suffixes appear before file extensions when present.

Functions

append_suffix_before_extension(label, suffix)

Append a suffix to a label, inserting it before a file extension when present.

radioviz.tools.naming_utils.append_suffix_before_extension(label: str, suffix: str) str[source]

Append a suffix to a label, inserting it before a file extension when present.

Parameters:
  • label (str) – Base label to extend.

  • suffix (str) – Suffix to insert (including any leading separator).

Returns:

The label with the suffix appended before the extension if any.

Return type:

str