Xtrack version 0.39.0
Changes
- New capabilities related to element compounds:
- Insertion of elements within compounds.
- Slicing of thick elements within compounds with propagation to all slices of the aperture and related tilts and shifts.
- New feature in matching with generation of an optimizer object to inspect and drive the matching process (the object can be obtained with
optimizer = line.match(solve=False)
). The optimizer object allows the following actions:- Perform an assigned number of optimization steps calling
optimizer.step(...)
. - Iterate until solution is found or termination condition is met through
optimized.solve(...)
. - Disable/enable targets and vary objects through their
active
flag. - Inspect vary's and targets of the optimizer using the method
optimizer.show()
. - Assign a tag to groups of vary's and targets and disable/enable groups by calling
optimizer.disable_targets(tag=...)
,optimizer.disable_vary(tag=...)
,optimizer.enable_targets(tag=...)
,optimizer.enable_vary(tag=...)
. - Inspect the optimizer iteration history through
optimizer.log()
. History can be deleted byoptimizer.clear_log()
- Reload the state from a given iteration by calling
optimizer.reload(...)
. - Provide defaults for vary steps and limits through
Line.vars.vary_default
. - Provide defaults for target tolerances through
match(default_tol={...}
. - Expose all features above in the matching of knobs.
- Perform an assigned number of optimization steps calling
- Introduced
Line.vars.load_madx_optics_file
method. - Introduce
Line.varval
to easily access variable values (line.varval['a']
equivalent toline.vars['a']._value
) - Introduce backtracking for thick elements
Quadrupole
andBend
(the latter only in expanded mode). - Introduce
Multiline.copy()
method. - Introduce method
TwissTable.concatenate
to concatenate twiss tables. - Introduced
TargetRelPhaseAdvance
to match relative phase advance between two points. - Fix handling of custom twiss_init when
twiss_default['reverse']
isTrue
.
Full Changelog: v0.38.3...v0.39.0