goldpan.legacy

The flat module names of the first versions (pulse_quantities, pulse_cuts, …), as aliases of the package.

Before the package existed, the library was eight flat modules, and the notebooks, notes and guides import them (import pulse_cuts as pc). They are kept as thin files in python/ that call flat_namespace below, so that they are the same code as the package with two differences, both for the sake of those notebooks, which all analyse the Run 76 readout:

  • a function that takes a config gets the Run 76 readout as the default;

  • pulse_config.PulseConfig has the Run 76 values as defaults (and warns when 1.6e-6 s is given, the value those notebooks used wrongly until 2026-10-22), and DEFAULT_CONFIG = PulseConfig().

These defaults are frozen at the values the notebooks and notes were run with, including the 1000-sample pretrigger window: the Run 76 pulses start at about sample 500, so goldpan.config.DCRC_RUN76 has 500 since 2026-10-28 (issue 154), but changing the flat defaults would change the results of every notebook that is run again. Pass a config (or n_samples=500) to get the window before the pulse.

New code should import goldpan.* and name its readout. The flat names will be removed in a later release.

Functions

alias_function(func)

func under the flat name: DEFAULT_CONFIG is the default of its config argument (if it has one).

flat_namespace(source, name)

The names of the package module source, for the flat module called name (see the module docstring).

Classes

PulseConfig([pretrigger_samples, ...])

goldpan.config.PulseConfig with the Run 76 readout as defaults (the flat pulse_config.PulseConfig).

class goldpan.legacy.PulseConfig(pretrigger_samples=1000, glitch_samples=10, sample_period_s=8e-07)[source]

Bases: PulseConfig

goldpan.config.PulseConfig with the Run 76 readout as defaults (the flat pulse_config.PulseConfig).

Parameters:
  • pretrigger_samples (int)

  • glitch_samples (int)

  • sample_period_s (float | None)

pretrigger_samples: int = 1000

Number of leading samples that make up the pretrigger (baseline) window.

glitch_samples: int = 10

Leading samples within the pretrigger window to skip before computing baseline mean/std, to avoid a brief electronic-glitch step artifact seen at the very start of some traces (see 07221203_2025_dump1_noise.ipynb).

sample_period_s: float | None = 8e-07

the functions that need it (for example frequencies_hz) then raise rather than silently assume a value.

Type:

Seconds per sample. Pass None if it is unknown for a dataset

goldpan.legacy.alias_function(func)[source]

func under the flat name: DEFAULT_CONFIG is the default of its config argument (if it has one).

The wrapper keeps the signature, docstring and @status tag; flat_namespace sets its __module__ to the flat module, so that list_statuses and the documentation tools see it as that module’s function.

goldpan.legacy.flat_namespace(source, name)[source]

The names of the package module source, for the flat module called name (see the module docstring).