PSFImage - Script by Hartmut Bornemann to automate the creation of a PSF profile

Herbert_W

Well-known member
Feb 3, 2011
221
1
Austria
www.skypixels.at
Hi,

I've waited a long time for this and now it's come true  :)
A script to automatically create a PSF profile of an image for further use in the Deconvolution module.
Thank you to Hartmut Bornemann for this new script. I have tested it on several images and it works very well!

Short explantion:
PSFImage can replace DynamicPSF and automate the creation of a PSF profile.
The script is applied to a view or preview and generates a profile image for use in deconvolution.
The criteria are the Moffat functions, the limitation of the amplitude and a setting for the sensitivity of the StarDetector.
All settings are saved. The result is displayed in the TextBox and commented on in the FITS header.


Download: https://www.skypixels.at/pixinsight_scripts.html

Please send questions to Hartmut - he is represented in this forum: hvb356

Best regards!
Herbert, Austria

 

pfile

PTeam Member
Nov 23, 2009
5,824
134
generally speaking star PSFs are destroyed (in the sense that the nonlinear stretch messes up the profile and can saturate the center of the star) and so all PSF extractions should always be done on linear data.

rob
 

GJL

Well-known member
May 17, 2012
105
1
Germany
The PSF tool is normally used for deconvolution in linear image processing. Deconvolution can also be used for refinement in the non-linear range. You can also use PSF, but I personally use nonlinear the Parametric PSF.

Gerhard
 

GJL

Well-known member
May 17, 2012
105
1
Germany
Rob, you give me the reason why I avoid PSF in the nonlinear area more intuitively.  Thanks

Gerhard
 

Booter

Member
Jan 18, 2017
6
0
Thank you very much Hartmut!

This is now part of my "must-do" workflow in PixInsight.

I am very grateful!!!

Have a great New Year!!!

Jeff in Canada
 

hvb356

Well-known member
Mar 15, 2011
101
6
E10 N52
Hi Jeff,

it's a pleasure for me.

A successful and happy New Year to you and the PixInsight community

Hartmut
 

Ghsmith45

Well-known member
Mar 3, 2012
922
5
Sydney, Australia
GJL said:
Rob, you give me the reason why I avoid PSF in the nonlinear area more intuitively.  Thanks

Gerhard
Well, the practical way to see the difference is to use dynamic PSF on a linear image and then stretch the image and repeat. You?ll find the PSFs of different stars are very similar in the linear case and all over the place in the nonlinear case.

The reason we measure a PSF is almost always as a prelude to deconvolution.  The image we have from the camera is a result of the source being convolved with atmospheric distortions and instrumental defects.  Deconvolution tries to reverse this process, so it needs a consistent PSF measurement throughout the image. Stretching removes this consistency.
 

johncdavis200

New member
Aug 20, 2015
3
0
I am having a problem with PSFImage - it has worked fine for me in the past - even earlier this year, but I have applied some updates to PixInsight and I am wondering if there is a problem or if I need to re-install.

I bring up the script and click on the evaluate - it runs fine and shows me the PSF image that it has calculated.  Then I click on the create button, and I see the PSF image flash on the workspace - but it immediately disappears.  When I OK out of the script - there is no PSF image like there normally is after the script runs. 

My PI version is:  1.08.06.1457

Help would be greatly appreciated!
 

pfile

PTeam Member
Nov 23, 2009
5,824
134
anything relevant in the console log? any errors?

is it possible the PSF image ended up on another workspace somehow?

rob
 

johncdavis200

New member
Aug 20, 2015
3
0
Hi - thanks for the response!  I don't see anything in the log that looks like an error.  There is this warning:

** Warning [290]: C:/Program Files/PixInsight/src/scripts/PSFImage.js, line 217: mistyped ; after conditional?
if (progressValue > 0);
.....................^

I've attached the full log to this post.  I also checked all the other workspaces and minimized all the objects - can't find it anywhere.  Usually the psf image is sitting on the workspace - it may be behind another image or process icon, but it is usually there.
 

Attachments

johncdavis200

New member
Aug 20, 2015
3
0
I have a laptop which has PI 1.08.05.1353 on it - and the PSFImage script runs fine on it...  So I was able to copy my image over to that machine and create the psf image file... but I would still like to get the desktop fixed - hopefully without reverting to the 05 release.

John
 

hvb356

Well-known member
Mar 15, 2011
101
6
E10 N52
Thanks Rob for pointing me to line 217. The corrected script is ready for download from https://www.skypixels.at/pixinsight_scripts.html and from my repository.

Regards

Hartmut
 

amacfarlane

Member
Mar 26, 2018
10
0
i have the same issue but as a PI newbie I didn't realise it was an issue - just thought I was doing something wrong.  Like others here, I hunted across all the workspaces looking for the little guy - but it was nowhere that I could find.  So I just pressed the create button again a couple more times and then hey presto - all the images appeared in a little stack in the middle of the workspace.  Perhaps you might like to try this and see if it works for you too.  I think I have the latest version of the script as I have just installed PI on a new PC but will run an update to be sure.