Skip to content

Conversation

@rmjarvis
Copy link
Owner

@rmjarvis rmjarvis commented Jul 23, 2025

Currently BasisPolynomial has a single number for max_order, which is the same for all cross pairings of two parameters. So if you want to include uv^2 and u^2v, that's max_order=3. The problem is when you also have e.g. color or dz - you are stuck with the same max_order for terms like color * v^2. This is usually not desired.

This PR makes it possible to more carefully specify the max_order you want for different pairs. max_order is allowed to be a dict whose keys are tuples of parameter names and whose values are the max_order you want for that pairing.

So to have e.g. u,v use 2nd order with cross terms, and also dz use 2nd order with no cross terms with u or v, you would specify: max_order = { (u,v): 2 }. (The missing (u,dz) and (v,dz) pairs are implicitly zero.)

Additionally, we had wanted to try forcing SumPSF to do extra iterations rather than stopping after only 1 or 2. That wasn't possible. So I added the parameter min_iter to all PSF types, analogous to max_iter.

@rmjarvis rmjarvis force-pushed the polynomial_order branch 2 times, most recently from 0542fe4 to 90c435a Compare July 24, 2025 02:19
@rmjarvis rmjarvis requested review from PFLeget and TallJimbo and removed request for TallJimbo July 24, 2025 02:36
@PFLeget
Copy link
Collaborator

PFLeget commented Jul 24, 2025

I am going to try this branch before approving it, if it sounds ok. I think I can look on DP1 how it impact color correction and on LSSTCam how it change PSF residuals by adding the sensor height on ITL sensor.

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.

3 participants