Author Topic: SpinStatus  (Read 4633 times)

Offline NKV

  • PTeam Member
  • PixInsight Guru
  • ****
  • Posts: 677
SpinStatus
« on: 2012 April 10 01:00:33 »
Hi,
I want use MorphologicalTransformation StructuringElement (13x13)
So I want update information in console during long calculation.

Please show me example for SpinStatus or other status monitoring solution.

Best regards,
Nikolay.

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: SpinStatus
« Reply #1 on: 2012 April 10 11:16:59 »
The MorphologicalTransformation PCL class already takes care of status monitoring. This is an easy example:

Image img;
// ...
StandardStatus status;
img.SetStatusCallback( &status );
// ...
ErosionFilter E;
CircularStructure C( 15 );
MorphologicalTransformation M( E, C );
M >> img; // increments img.Status() by the number of selected pixel samples in img


SpinStatus should only be used when the total complexity of a process cannot be determined in advance. For example, this happens with algorithms that run until convergence after an undetermined number of iterations. In the case of MT, StandardStatus is better because the number of processed items can be predicted as a fixed value: it is the number of selected samples in the target image.

Let me know if this help you.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline NKV

  • PTeam Member
  • PixInsight Guru
  • ****
  • Posts: 677
Re: SpinStatus
« Reply #2 on: 2012 April 10 19:48:58 »
Sorry Juan, it's don't help me.

I cleared console, I run module, after some seconds waiting(MT processing time), I got first message in console "Morphological transformation, Median: 100%"

I seen only final result.
I never seen progress 1%, 20%, 50%, 99%

How to see the progress of MorphologicalTransformation ?

Offline Juan Conejero

  • PTeam Member
  • PixInsight Jedi Grand Master
  • ********
  • Posts: 7111
    • http://pixinsight.com/
Re: SpinStatus
« Reply #3 on: 2012 April 11 04:17:13 »
Quote
How to see the progress of MorphologicalTransformation ?

With the current PCL version you cannot. This happens because the MT process updates the image's status monitor only at the beginning and end of the task, but not in between. For now, please ignore this little problem and wait until I release a new version of PCL, where this will be fixed. If necessary, I'll send you a modified PCL library with this problem solved. Sorry for the trouble.
Juan Conejero
PixInsight Development Team
http://pixinsight.com/

Offline NKV

  • PTeam Member
  • PixInsight Guru
  • ****
  • Posts: 677
Re: SpinStatus
« Reply #4 on: 2012 April 13 01:43:21 »
If necessary, I'll send you a modified PCL library with this problem solved.
Yes, I want try it.