From bcb9f21834eeaad0cb182497c725571338645315 Mon Sep 17 00:00:00 2001 From: Remco de Boer <29308176+redeboer@users.noreply.github.com> Date: Mon, 4 Mar 2024 22:31:38 +0100 Subject: [PATCH] DOC: use `dynamics.assign() in notebooks --- docs/amplitude-analysis.ipynb | 6 +++--- docs/amplitude-analysis/analytic-continuation.ipynb | 6 +++--- docs/usage/faster-lambdify.ipynb | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/docs/amplitude-analysis.ipynb b/docs/amplitude-analysis.ipynb index b54d8ff7..7c68c0a5 100644 --- a/docs/amplitude-analysis.ipynb +++ b/docs/amplitude-analysis.ipynb @@ -242,7 +242,7 @@ "1. The coefficients for the different amplitudes are **complex** valued.\n", "2. By default there is no dynamics in the model, so it still has to be specified.\n", "\n", - "We choose to use {func}`~ampform.dynamics.relativistic_breit_wigner_with_ff` as the lineshape for all resonances and use a Blatt-Weisskopf form factor ({func}`~ampform.dynamics.builder.create_non_dynamic_with_ff`) for the production decay. The {meth}`~ampform.helicity.HelicityAmplitudeBuilder.set_dynamics` is a convenience interface for replacing the dynamics for intermediate states." + "We choose to use {func}`~ampform.dynamics.relativistic_breit_wigner_with_ff` as the lineshape for all resonances and use a Blatt-Weisskopf form factor ({func}`~ampform.dynamics.builder.create_non_dynamic_with_ff`) for the production decay. The {meth}`~ampform.helicity.HelicityAmplitudeBuilder.dynamics.assign` is a convenience interface for replacing the dynamics for intermediate states." ] }, { @@ -258,9 +258,9 @@ " create_relativistic_breit_wigner_with_ff,\n", ")\n", "\n", - "model_builder.set_dynamics(\"J/psi(1S)\", create_non_dynamic_with_ff)\n", + "model_builder.dynamics.assign(\"J/psi(1S)\", create_non_dynamic_with_ff)\n", "for name in reaction.get_intermediate_particles().names:\n", - " model_builder.set_dynamics(name, create_relativistic_breit_wigner_with_ff)\n", + " model_builder.dynamics.assign(name, create_relativistic_breit_wigner_with_ff)\n", "model = model_builder.formulate()" ] }, diff --git a/docs/amplitude-analysis/analytic-continuation.ipynb b/docs/amplitude-analysis/analytic-continuation.ipynb index d7c06870..f72f93be 100644 --- a/docs/amplitude-analysis/analytic-continuation.ipynb +++ b/docs/amplitude-analysis/analytic-continuation.ipynb @@ -188,15 +188,15 @@ " energy_dependent_width=True,\n", " phsp_factor=PhaseSpaceFactorSWave,\n", ")\n", - "model_builder.set_dynamics(\n", + "model_builder.dynamics.assign(\n", " \"D0\",\n", " create_non_dynamic_with_ff,\n", ")\n", - "model_builder.set_dynamics(\n", + "model_builder.dynamics.assign(\n", " \"a(0)(980)0\",\n", " analytic_breit_wigner_builder,\n", ")\n", - "model_builder.set_dynamics(\n", + "model_builder.dynamics.assign(\n", " \"a(2)(1320)0\",\n", " create_relativistic_breit_wigner_with_ff,\n", ")\n", diff --git a/docs/usage/faster-lambdify.ipynb b/docs/usage/faster-lambdify.ipynb index 8f55f4be..42266d3e 100644 --- a/docs/usage/faster-lambdify.ipynb +++ b/docs/usage/faster-lambdify.ipynb @@ -281,7 +281,7 @@ ")\n", "model_builder = ampform.get_builder(reaction)\n", "for name in reaction.get_intermediate_particles().names:\n", - " model_builder.set_dynamics(name, create_relativistic_breit_wigner_with_ff)\n", + " model_builder.dynamics.assign(name, create_relativistic_breit_wigner_with_ff)\n", "model = model_builder.formulate()" ] },