debug module

Define various functions.

Todo

Clean this, a lot of old things that may not be used.

Todo

Ellipse plot could be better

compute_error_transfer_matrix(t_m, t_m_ref, output=False)[source]

Compute and output error between transfer matrix and ref.

Parameters:
Return type:

tuple[ndarray, ndarray]

load_phase_space(accelerator)[source]

Load Partran phase-space data.

Phase-space files are obtained with:

Input data & Beam: Partran Phase spaces or beam distributions: Output at element n Then save all particle as ASCII.

Parameters:

accelerator (Accelerator)

Return type:

list[ndarray]

_create_output_fit_dicts()[source]
Return type:

dict[str, dict]

output_fit(fault_scenario, out_detail=False, out_compact=True)[source]

Output relatable parameters of fit.

output_fit_progress(count, obj, l_label, final=False)[source]

Output the evolution of the objectives.