ocelot.adaptors¶
Submodules¶
ocelot.adaptors.astra2ocelotocelot.adaptors.astra_lattice_converterocelot.adaptors.csrtrack2ocelotocelot.adaptors.elegant2ocelotocelot.adaptors.elegant_lattice_converterocelot.adaptors.genesisocelot.adaptors.genesis4ocelot.adaptors.longlist2ocelotocelot.adaptors.mad8ocelot.adaptors.madxocelot.adaptors.madx_oldocelot.adaptors.srwutilocelot.adaptors.wake_t
Package Contents¶
Functions¶
|
|
|
|
|
function convert Astra beam distribution to Ocelot format - ParticleArray. |
|
function convert Ocelot’s ParticleArray to Astra beam distribution and save to “filename”. |
-
ocelot.adaptors.read_twi_file(namefile)¶
-
ocelot.adaptors.read_lattice_elegant(file_flo, file_par)¶
-
ocelot.adaptors.astraBeam2particleArray(filename, print_params=True)¶ function convert Astra beam distribution to Ocelot format - ParticleArray. Note that downloading ParticleArray from the astra file and saving it back does not give the same distribution. The difference arises because the array of particles does not have a reference particle, and in this case the first particle is used as a reference.
- Parameters
print_params –
- Returns
ParticleArray
-
ocelot.adaptors.particleArray2astraBeam(p_array, filename='tytest.ast')¶ function convert Ocelot’s ParticleArray to Astra beam distribution and save to “filename”.
Note that downloading ParticleArray from the astra file and saving it back does not give the same distribution. The difference arises because the array of particles does not have a reference particle, and in this case the first particle is used as a reference.
- Parameters
p_array –
filename –
- Returns