[PIPE2D-630] Deliver algorithms to handle FRD extraction Created: 01/Sep/20 Updated: 13/Jan/23 |
|
| Status: | In Progress |
| Project: | DRP 2-D Pipeline |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Story | Priority: | Normal |
| Reporter: | Brent Belland | Assignee: | Brent Belland |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||
| Story Points: | 30 | ||||||||||||||||||||||||||||||||||||
| Sprint: | 2DDRP-2021 A | ||||||||||||||||||||||||||||||||||||
| Description |
|
The purpose of this ticket is to create a function that takes in as inputs an image to solve for an FRD, a list of images with known FRD, and a list of FRDs corresponding to the images to output an FRD, incorporating the work that I have developed in PIPE2D-637. This function will be well commented regarding inputs, process, and outputs as well as pass errors/warnings if data does not match expected format. This is planned to take 2 weeks, from February 22 -March 8th. This code is to be uploaded to my Github afterward for use in the project.
------ Old description:
Much of my work to this point has been investigatory in nature, focused on measuring variations in PSFs at varying FRDs across the detector at varying parameters. However, what the project needs is code that determines FRD in the current PSFs based on some previously measured FRDs at a base configuration. This will compile work on PIPE2D-627, PIPE2D-628, and A working first version of this code (class/function) is to be delivered by the end of the year. |
| Comments |
| Comment by Brent Belland [ 02/Oct/20 ] |
|
Currently a function is in development that solves for FRD of an arbitrarily centered PSF generated from Neven's code, using the scipy shgo optimizer (https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.shgo.html). The current version of this code solves for FRD with plus/minus 0.2 mrad error with about 30 iterations. I am currently investigating how to reduce iteration time using the insight from my previous FRD analysis |
| Comment by Brent Belland [ 16/Mar/21 ] |
|
The current version of my code is available at https://github.com/bbelland/FRDtesting. This code can run and solve for an FRD, but while comparing this code to my previous work's precision, I found that the uncertainties are larger than expected from my previous FRD analysis. I am working to address this issue to demonstrate FRDs can be solved for properly. |
| Comment by ncaplar [ 30/Mar/21 ] |
|
My initial thoughts after testing code today: 1. (minor issue) in FRDClass_TestNotebook variables are called ``knownFRDlist'', ``imagelist'', even thought the code demands them te be arrays and not lists. 2. The uncertainty that is reported from the algorithm depends on the points that have been provided to the algorithm. I think it would be better to report where the interpolation crosses the limit. I.e., the reported uncertainty should not directly depend on the provided points, but one should estimate at which point the critical chi**2 values is reached. 3. ``uncertaintyrange'' variable returned by the algorithm is a single number, even though the distribution is nonsymmetric and reported uncertainty has different lower and upper bounds. I would assume that the ``uncertaintyrange'' variable would therefore also be consisting of two numbers. 4. (further thoughts, not critical to this code) - at this point the code return basically what image that is provided has the best fit - i.e., the result depends critically on the density of sampling. It might be beneficial to try to extrapolate the trends as one is approaching to the correct solution from the left and the right side to extrapolate what the correct answer might be, or at least provide the user with a hint for the second round of sampling, i.e., in which range to simulate more images. |
| Comment by Brent Belland [ 30/Mar/21 ] |
|
I'm addressing the first three points, and they're almost all done.
I'll be thinking about how to address point 4 but focusing on PIPE2D-623 as discussed in the telecom. |
| Comment by ncaplar [ 31/Mar/21 ] |
|
Some further thoughts: 1. I believe that the reason why you code creating images is quite slow is due to the fact you are creating 50x50 images when creating focused images. As we discussed few times, one can use smaller images which will be faster and also more realistic as in real life we will be using the code on relatively small post-stamp images (probably 10x10 or even less). |