Skip to content

Qualify shared beam parameters with probe name for probeset and polarized - #388

Merged
pkienzle merged 2 commits into
masterfrom
fix-shared-beam-parnames
Aug 14, 2026
Merged

Qualify shared beam parameters with probe name for probeset and polarized#388
pkienzle merged 2 commits into
masterfrom
fix-shared-beam-parnames

Conversation

@pkienzle

@pkienzle pkienzle commented Aug 5, 2026

Copy link
Copy Markdown
Member

Automatically tags the parameter name with the probe name for shared beam parameters.

For non-shared polarized probes, the beam parameters are not being tagged with cross section. This PR does not address this.

We now share the beam parameters from the first probe rather than creating new parameters. This will only apply to parameters not explicitly listed in the shared_beam call.

Any initial guesses such as background=1e-6 or theta_offset=0.01 that were given when the first probe was loaded will propagate to all the other probes. For the polref loader (#382), that means theta_offset etc. specified in the load_probe_polref call will be respected in the shared beam, without needing a separate probe.shared_beam(theta_offset=...) after loading.

The parameters will still be qualified with the name from the first probe. That's a little ugly if the probes have unique names (cross section or sequence number for example). If that's a problem we can copy it and give it a new name.


Things to consider:

  • We can use parameter.equals(shared) rather than parameter=shared to constrain them. That way we can unlink them to stop sharing. If they are shared by assignment, we would need to make a copy of the parameter to stop sharing. The two parameters will share the same name, which will be confusing.

@pkienzle pkienzle mentioned this pull request Aug 6, 2026
2 tasks
@pkienzle
pkienzle merged commit 45fc541 into master Aug 14, 2026
15 checks passed
@pkienzle
pkienzle deleted the fix-shared-beam-parnames branch August 14, 2026 15:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants