pylhc / omc3

Python 3 codes for beam optics measurements and corrections in circular particle accelerators

Home Page:https://pylhc.github.io/omc3/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Change name of best-knowledge madx file.

JoschD opened this issue · comments

job.create_model.madx is overwritten by best-knowledge model creator (the two creators are called by the GUI in a row).
Maybe should be job.create_bestknowledge_model.madx (see other model creators in python code on how to easily overwrite)

Related: is the best knowledge model even used in omc3?

  • yes! (please check)

yes, beta_from_phase for example uses the best knowledge model for its model phase advances:

def _try_best_model(meas_input):
if meas_input.accelerator.model_best_knowledge is None:
LOGGER.debug("No best knowledge model - using the normal one.")
return meas_input.accelerator.model
return meas_input.accelerator.model_best_knowledge

which is ultimately used in lines 84 und 85 of

def n_bpm_method(meas_input, phase, plane, meas_and_mdl_tunes):

In general it should be used by every model-dependent algorithm like beta_from_phase and both AC-dipole compensation methods (especially Ryoichi's)