xtrack 0.69.1__tar.gz → 0.69.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (252) hide show
  1. {xtrack-0.69.1/xtrack.egg-info → xtrack-0.69.2}/PKG-INFO +5 -1
  2. {xtrack-0.69.1 → xtrack-0.69.2}/setup.py +2 -1
  3. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_environment.py +20 -0
  4. xtrack-0.69.2/xtrack/_version.py +1 -0
  5. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/line.py +48 -3
  6. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/survey.py +9 -1
  7. {xtrack-0.69.1 → xtrack-0.69.2/xtrack.egg-info}/PKG-INFO +5 -1
  8. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack.egg-info/requires.txt +5 -0
  9. xtrack-0.69.1/xtrack/_version.py +0 -1
  10. {xtrack-0.69.1 → xtrack-0.69.2}/LICENSE +0 -0
  11. {xtrack-0.69.1 → xtrack-0.69.2}/MANIFEST.in +0 -0
  12. {xtrack-0.69.1 → xtrack-0.69.2}/README.md +0 -0
  13. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/__init__.py +0 -0
  14. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/base_classes.py +0 -0
  15. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/BB6D.py +0 -0
  16. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/BB6Ddata.py +0 -0
  17. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/__init__.py +0 -0
  18. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/beambeam.py +0 -0
  19. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/boost.py +0 -0
  20. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/gaussian_fields.py +0 -0
  21. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/propagate_sigma_matrix.py +0 -0
  22. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/qgauss.py +0 -0
  23. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/slicing.py +0 -0
  24. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/be_beamfields/spacecharge.py +0 -0
  25. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/elements.py +0 -0
  26. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/line.py +0 -0
  27. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/mathlibs.py +0 -0
  28. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/particles.py +0 -0
  29. {xtrack-0.69.1 → xtrack-0.69.2}/ducktrack/temp_pyparticles.py +0 -0
  30. {xtrack-0.69.1 → xtrack-0.69.2}/pyproject.toml +0 -0
  31. {xtrack-0.69.1 → xtrack-0.69.2}/setup.cfg +0 -0
  32. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_acceleration.py +0 -0
  33. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_amplitude_detuning.py +0 -0
  34. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_aperture_turn_ele_and_monitor.py +0 -0
  35. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_apertures.py +0 -0
  36. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_attr_replicas_and_slices.py +0 -0
  37. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_cavity_absolute_time.py +0 -0
  38. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_chromatic_functions_vs_madx.py +0 -0
  39. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_coasting.py +0 -0
  40. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_collective_tracker.py +0 -0
  41. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_collimation.py +0 -0
  42. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_element_characterization_functions.py +0 -0
  43. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_element_internal_record.py +0 -0
  44. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_elements.py +0 -0
  45. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_elements_classflags.py +0 -0
  46. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_elements_thick.py +0 -0
  47. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_fcc_ee_solenoid_correction.py +0 -0
  48. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_fcc_ee_solenoid_correction_new_optimize_api.py +0 -0
  49. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_footprint.py +0 -0
  50. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_freeze_longitudinal.py +0 -0
  51. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_full_rings.py +0 -0
  52. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_hvkick.py +0 -0
  53. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_ions.py +0 -0
  54. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_lhc_match_phase_15.py +0 -0
  55. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_line.py +0 -0
  56. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_lumi.py +0 -0
  57. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_mad_writer.py +0 -0
  58. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_madloader.py +0 -0
  59. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_and_track_from_element.py +0 -0
  60. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_coupling_knob.py +0 -0
  61. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_nested.py +0 -0
  62. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_optics_and_ip_knob.py +0 -0
  63. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_optics_and_ip_knob_new_optimize_api.py +0 -0
  64. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_orbit_bump.py +0 -0
  65. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_match_tune_chroma_cminus.py +0 -0
  66. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_monitor.py +0 -0
  67. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_multiline.py +0 -0
  68. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_multisetter.py +0 -0
  69. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_multispecies.py +0 -0
  70. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_particles_api.py +0 -0
  71. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_periodic_symmetric_twiss_and_match.py +0 -0
  72. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_pipeline.py +0 -0
  73. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_prebuild_kernels.py +0 -0
  74. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_ps_against_ptc.py +0 -0
  75. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_ps_multiturn_twiss.py +0 -0
  76. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_psb_chicane.py +0 -0
  77. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_pyht_interface.py +0 -0
  78. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_radial_steering.py +0 -0
  79. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_radiation.py +0 -0
  80. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_radiation_equilibrium_emittances.py +0 -0
  81. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_random_gen.py +0 -0
  82. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_random_gen_exp.py +0 -0
  83. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_random_gen_gauss.py +0 -0
  84. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_random_gen_ruth.py +0 -0
  85. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_rf_track.py +0 -0
  86. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_rotation_signs.py +0 -0
  87. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_second_order_taylor_map.py +0 -0
  88. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_seeds.py +0 -0
  89. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_slice_and_insert_with_replicas.py +0 -0
  90. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_slice_elements.py +0 -0
  91. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_slicing.py +0 -0
  92. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_solenoid_bz_map_vs_boris.py +0 -0
  93. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_spacecharge_in_ring.py +0 -0
  94. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_sps_thick.py +0 -0
  95. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_survey.py +0 -0
  96. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_tapering.py +0 -0
  97. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_thick_lhc.py +0 -0
  98. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_tilt_shifts.py +0 -0
  99. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_tracker.py +0 -0
  100. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_trajectory_correcton.py +0 -0
  101. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_twiss.py +0 -0
  102. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_twiss_vs_madx_psb.py +0 -0
  103. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_vs_madx.py +0 -0
  104. {xtrack-0.69.1 → xtrack-0.69.2}/tests/test_xmask_orbit_correction.py +0 -0
  105. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/__init__.py +0 -0
  106. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/__init__.py +0 -0
  107. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/boris_and_solenoid_map/__init__.py +0 -0
  108. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/boris_and_solenoid_map/boris.h +0 -0
  109. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/boris_and_solenoid_map/solenoid_field.py +0 -0
  110. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/lhc_match/__init__.py +0 -0
  111. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/lhc_match/gen_madx_optics_file.py +0 -0
  112. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/lhc_match/lhc_match.py +0 -0
  113. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/_temp/lhc_match/var_limits.py +0 -0
  114. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/base_element.py +0 -0
  115. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/__init__.py +0 -0
  116. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures.py +0 -0
  117. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures_src/limitellipse.h +0 -0
  118. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures_src/limitpolygon.h +0 -0
  119. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures_src/limitracetrack.h +0 -0
  120. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures_src/limitrect.h +0 -0
  121. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures_src/limitrectellipse.h +0 -0
  122. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/apertures_src/longitudinallimitrect.h +0 -0
  123. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/beam_interaction.py +0 -0
  124. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements.py +0 -0
  125. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/bend.h +0 -0
  126. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/cavity.h +0 -0
  127. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/dipole_fringe.h +0 -0
  128. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/dipoleedge.h +0 -0
  129. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift.h +0 -0
  130. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift_elem.h +0 -0
  131. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift_slice.h +0 -0
  132. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift_slice_bend.h +0 -0
  133. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift_slice_octupole.h +0 -0
  134. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift_slice_quadrupole.h +0 -0
  135. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/drift_slice_sextupole.h +0 -0
  136. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/elens.h +0 -0
  137. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/exciter.h +0 -0
  138. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/firstordertaylormap.h +0 -0
  139. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/linesegmentmap.h +0 -0
  140. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/multipole.h +0 -0
  141. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/nonlinearlens.h +0 -0
  142. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/octupole.h +0 -0
  143. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/quadrupole.h +0 -0
  144. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/referenceenergyincrease.h +0 -0
  145. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/rfmultipole.h +0 -0
  146. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/second_order_taylor_map.h +0 -0
  147. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/sextupole.h +0 -0
  148. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/simplethinbend.h +0 -0
  149. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/simplethinquadrupole.h +0 -0
  150. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/solenoid.h +0 -0
  151. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/srotation.h +0 -0
  152. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thick_slice_bend.h +0 -0
  153. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thick_slice_drift.h +0 -0
  154. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thick_slice_octupole.h +0 -0
  155. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thick_slice_quadrupole.h +0 -0
  156. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thick_slice_sextupole.h +0 -0
  157. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thick_slice_solenoid.h +0 -0
  158. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thin_slice_bend.h +0 -0
  159. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thin_slice_bend_entry.h +0 -0
  160. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thin_slice_bend_exit.h +0 -0
  161. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thin_slice_octupole.h +0 -0
  162. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thin_slice_quadrupole.h +0 -0
  163. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/thin_slice_sextupole.h +0 -0
  164. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_bend.h +0 -0
  165. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_dipole_edge_linear.h +0 -0
  166. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_dipole_edge_nonlinear.h +0 -0
  167. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_dipole_fringe.h +0 -0
  168. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_mult_fringe.h +0 -0
  169. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_multipolar_components.h +0 -0
  170. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_multipole.h +0 -0
  171. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_quadrupole.h +0 -0
  172. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_solenoid.h +0 -0
  173. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_srotation.h +0 -0
  174. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_thick_bend.h +0 -0
  175. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_thick_cfd.h +0 -0
  176. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_wedge.h +0 -0
  177. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_xrotation.h +0 -0
  178. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/track_yrotation.h +0 -0
  179. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/wedge.h +0 -0
  180. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/wire.h +0 -0
  181. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/xrotation.h +0 -0
  182. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/xyshift.h +0 -0
  183. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/yrotation.h +0 -0
  184. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/elements_src/zetashift.h +0 -0
  185. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/exciter.py +0 -0
  186. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/rft_element.py +0 -0
  187. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/slice_elements.py +0 -0
  188. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/beam_elements/slice_elements_thick.py +0 -0
  189. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/environment.py +0 -0
  190. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/footprint.py +0 -0
  191. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/general.py +0 -0
  192. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/headers/atomicadd.h +0 -0
  193. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/headers/checks.h +0 -0
  194. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/headers/constants.h +0 -0
  195. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/headers/particle_states.h +0 -0
  196. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/headers/synrad_spectrum.h +0 -0
  197. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/internal_record.py +0 -0
  198. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/json_utils.py +0 -0
  199. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/linear_normal_form.py +0 -0
  200. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/loss_location_refinement/__init__.py +0 -0
  201. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/loss_location_refinement/loss_location_refinement.py +0 -0
  202. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/lumi.py +0 -0
  203. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/mad_loader.py +0 -0
  204. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/mad_writer.py +0 -0
  205. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/match.py +0 -0
  206. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/__init__.py +0 -0
  207. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/beam_position_monitor.h +0 -0
  208. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/beam_position_monitor.py +0 -0
  209. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/beam_profile_monitor.h +0 -0
  210. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/beam_profile_monitor.py +0 -0
  211. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/beam_size_monitor.h +0 -0
  212. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/beam_size_monitor.py +0 -0
  213. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/last_turns_monitor.h +0 -0
  214. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/last_turns_monitor.py +0 -0
  215. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/particles_monitor.h +0 -0
  216. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/monitors/particles_monitor.py +0 -0
  217. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/multiline/__init__.py +0 -0
  218. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/multiline/multiline.py +0 -0
  219. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/multiline/shared_knobs.py +0 -0
  220. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/multisetter/__init__.py +0 -0
  221. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/multisetter/multisetter.py +0 -0
  222. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/particles/__init__.py +0 -0
  223. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/particles/constants.py +0 -0
  224. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/particles/particles.py +0 -0
  225. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/particles/rng_src/base_rng.h +0 -0
  226. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/particles/rng_src/particles_rng.h +0 -0
  227. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/pipeline/__init__.py +0 -0
  228. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/pipeline/core.py +0 -0
  229. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/pipeline/manager.py +0 -0
  230. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/pipeline/multitracker.py +0 -0
  231. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/progress_indicator.py +0 -0
  232. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/__init__.py +0 -0
  233. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_generators.py +0 -0
  234. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_src/exponential.h +0 -0
  235. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_src/exponential_integral_Ei.h +0 -0
  236. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_src/normal.h +0 -0
  237. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_src/rutherford.h +0 -0
  238. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_src/uniform.h +0 -0
  239. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/random/random_src/uniform_accurate.h +0 -0
  240. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/slicing.py +0 -0
  241. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/synctime.py +0 -0
  242. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/tapering.py +0 -0
  243. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/targets.py +0 -0
  244. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/tracker.py +0 -0
  245. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/tracker_data.py +0 -0
  246. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/tracker_src/tracker.h +0 -0
  247. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/trajectory_correction.py +0 -0
  248. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/twiss.py +0 -0
  249. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack/twissplot.py +0 -0
  250. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack.egg-info/SOURCES.txt +0 -0
  251. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack.egg-info/dependency_links.txt +0 -0
  252. {xtrack-0.69.1 → xtrack-0.69.2}/xtrack.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: xtrack
3
- Version: 0.69.1
3
+ Version: 0.69.2
4
4
  Summary: Tracking library for particle accelerators
5
5
  Home-page: https://xsuite.readthedocs.io/
6
6
  Download-URL: https://pypi.python.org/pypi/xtrack
@@ -22,5 +22,9 @@ Requires-Dist: nafflib; extra == "tests"
22
22
  Requires-Dist: PyHEADTAIL; extra == "tests"
23
23
  Requires-Dist: pytest; extra == "tests"
24
24
  Requires-Dist: pytest-mock; extra == "tests"
25
+ Provides-Extra: notebooks
26
+ Requires-Dist: jupyter; extra == "notebooks"
27
+ Requires-Dist: ipympl; extra == "notebooks"
28
+ Requires-Dist: xplt; extra == "notebooks"
25
29
 
26
30
  Tracking library for particle accelerators
@@ -49,5 +49,6 @@ setup(
49
49
  ],
50
50
  extras_require={
51
51
  'tests': ['cpymad', 'nafflib', 'PyHEADTAIL', 'pytest', 'pytest-mock'],
52
- },
52
+ 'notebooks': ['jupyter', 'ipympl', 'xplt'],
53
+ },
53
54
  )
@@ -1377,6 +1377,26 @@ def test_assemble_ring_repeated_elements():
1377
1377
  tw_one_cell_stripped = tw_one_cell.rows[:-1] # remove _end_point
1378
1378
  xo.assert_allclose(tw_one_cell_stripped.betx, tw_one_cell_ref.betx, atol=0, rtol=5e-4)
1379
1379
 
1380
+ cell_selected = arc.select(start='mid::2', end='mid::3')
1381
+ tw_cell_selected = cell_selected.twiss4d()
1382
+ tw_cell_selected_stripped = tw_cell_selected.rows[:-1] # remove _end_point
1383
+ xo.assert_allclose(tw_cell_selected_stripped.betx, tw_one_cell_ref.betx, atol=0, rtol=5e-4)
1384
+
1385
+ tt_ring2 = ring2.get_table(attr=True)
1386
+ assert tt_ring2['name', 39] == 'mq.f::1'
1387
+ assert tt_ring2['name', 48] == 'mq.f::2'
1388
+ assert ring2.element_names[39] == 'mq.f'
1389
+ assert ring2.element_names[48] == 'mq.f'
1390
+
1391
+ ring2.replace_all_repeated_elements()
1392
+ tt_ring2_after = ring2.get_table(attr=True)
1393
+ assert tt_ring2_after['name', 39] == 'mq.f.1'
1394
+ assert tt_ring2_after['name', 48] == 'mq.f.2'
1395
+ assert ring2.element_names[39] == 'mq.f.1'
1396
+ assert ring2.element_names[48] == 'mq.f.2'
1397
+ assert str(ring2.ref['mq.f.1'].k1._expr) == "vars['kqf']"
1398
+ assert str(ring2.ref['mq.f.2'].k1._expr) == "vars['kqf']"
1399
+ assert ring2.get('mq.f.1') is not ring2.get('mq.f.2')
1380
1400
 
1381
1401
  # import matplotlib.pyplot as plt
1382
1402
  # plt.close('all')
@@ -0,0 +1 @@
1
+ __version__ = '0.69.2'
@@ -3458,6 +3458,25 @@ class Line:
3458
3458
  if isinstance(self.element_dict[nn], xt.Replica):
3459
3459
  self.replace_replica(nn)
3460
3460
 
3461
+ def replace_all_repeated_elements(self, separator='.', mode='clone'):
3462
+
3463
+ self._env_if_needed()
3464
+ env = self.env
3465
+
3466
+ self.discard_tracker()
3467
+ unique_names = list(set(self.element_names))
3468
+ aux_dict = {nn: [] for nn in unique_names}
3469
+ for ii, nn in enumerate(self.element_names):
3470
+ aux_dict[nn].append(ii)
3471
+
3472
+ for nn in unique_names:
3473
+ if len(aux_dict[nn]) > 1:
3474
+ i_rep = 0
3475
+ for ii in aux_dict[nn]:
3476
+ while (new_name := nn + separator + str(i_rep)) in self.element_dict:
3477
+ i_rep += 1
3478
+ env.new(new_name, nn, mode=mode)
3479
+ self.element_names[ii] = new_name
3461
3480
 
3462
3481
  def select(self, start=None, end=None, name=None):
3463
3482
 
@@ -3473,7 +3492,7 @@ class Line:
3473
3492
 
3474
3493
  self._env_if_needed()
3475
3494
 
3476
- out = self.env.new_line(components=list(tt.name), name=name)
3495
+ out = self.env.new_line(components=list(tt.env_name), name=name)
3477
3496
 
3478
3497
  if hasattr(self, '_in_multiline') and self._in_multiline is not None:
3479
3498
  out.env._var_management = None
@@ -4653,6 +4672,10 @@ class LineVars:
4653
4672
  out = list(self.line._xdeps_vref._owner.keys()).copy()
4654
4673
  return out
4655
4674
 
4675
+ def __iter__(self):
4676
+ raise NotImplementedError('Use keys() method') # Untested
4677
+ return self.line._xdeps_vref._owner.__iter__()
4678
+
4656
4679
  def update(self, other):
4657
4680
  if self.line._xdeps_vref is None:
4658
4681
  raise RuntimeError(
@@ -4671,10 +4694,32 @@ class LineVars:
4671
4694
  if self.line._xdeps_vref is None:
4672
4695
  raise RuntimeError(
4673
4696
  f'Cannot access variables as the line has no xdeps manager')
4674
- name = np.array([kk for kk in list(self.keys()) if kk != '__vary_default'])
4697
+ name = np.array([kk for kk in list(self.keys()) if kk != '__vary_default'], dtype=object)
4675
4698
  value = np.array([self.line._xdeps_vref[kk]._value for kk in name])
4699
+ expr = np.array([str(self.line._xdeps_vref[str(kk)]._expr) for kk in name])
4700
+
4701
+ return xd.Table({'name': name, 'value': value, 'expr': expr})
4676
4702
 
4677
- return xd.Table({'name': name, 'value': value})
4703
+ def expr(self, var):
4704
+ raise NotImplementedError # Untested
4705
+ if isinstance(var,str):
4706
+ ref=self.line._xdeps_vref[var]
4707
+ elif is_expr(var):
4708
+ ref=var
4709
+ else:
4710
+ raise ValueError(f"`{var}` not valid, must be str or expr")
4711
+ expr=ref._expr
4712
+ if expr is None:
4713
+ raise NameError(f"`{var}` does not have any expression")
4714
+ return expr
4715
+
4716
+ def eval(self, expr):
4717
+ raise NotImplementedError # Untested
4718
+ return self.line._xdeps_eval.eval(expr)
4719
+
4720
+ def value(self, expr):
4721
+ raise NotImplementedError # Untested
4722
+ return eval(self)._get_value()
4678
4723
 
4679
4724
  def __contains__(self, key):
4680
4725
  if self.line._xdeps_vref is None:
@@ -168,13 +168,21 @@ class SurveyTable(Table):
168
168
  return out
169
169
 
170
170
  def plot(self, element_width=None, legend=True, **kwargs):
171
+ # Shallow copy of self
172
+ out_sv_table = SurveyTable.__new__(SurveyTable)
173
+ out_sv_table.__dict__.update(self.__dict__)
174
+ out_sv_table._data = self._data.copy()
175
+
176
+ # Removing the count for repeated elements
177
+ out_sv_table.name = np.array([nn.split('::')[0] for nn in out_sv_table.name])
178
+
171
179
  if element_width is None:
172
180
  x_range = max(self.X) - min(self.X)
173
181
  y_range = max(self.Y) - min(self.Y)
174
182
  z_range = max(self.Z) - min(self.Z)
175
183
  element_width = max([x_range, y_range, z_range]) * 0.03
176
184
  import xplt
177
- xplt.FloorPlot(self, self.line, element_width=element_width, **kwargs)
185
+ xplt.FloorPlot(out_sv_table, self.line, element_width=element_width, **kwargs)
178
186
  if legend:
179
187
  import matplotlib.pyplot as plt
180
188
  plt.legend()
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: xtrack
3
- Version: 0.69.1
3
+ Version: 0.69.2
4
4
  Summary: Tracking library for particle accelerators
5
5
  Home-page: https://xsuite.readthedocs.io/
6
6
  Download-URL: https://pypi.python.org/pypi/xtrack
@@ -22,5 +22,9 @@ Requires-Dist: nafflib; extra == "tests"
22
22
  Requires-Dist: PyHEADTAIL; extra == "tests"
23
23
  Requires-Dist: pytest; extra == "tests"
24
24
  Requires-Dist: pytest-mock; extra == "tests"
25
+ Provides-Extra: notebooks
26
+ Requires-Dist: jupyter; extra == "notebooks"
27
+ Requires-Dist: ipympl; extra == "notebooks"
28
+ Requires-Dist: xplt; extra == "notebooks"
25
29
 
26
30
  Tracking library for particle accelerators
@@ -5,6 +5,11 @@ tqdm
5
5
  xobjects
6
6
  xdeps
7
7
 
8
+ [notebooks]
9
+ jupyter
10
+ ipympl
11
+ xplt
12
+
8
13
  [tests]
9
14
  cpymad
10
15
  nafflib
@@ -1 +0,0 @@
1
- __version__ = '0.69.1'
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes