Masked stretch complains about gc()...

RBA

Well-known member
See output:

Processing script file: C:/Program Files/PixInsight64/src/scripts/masked-stretch.js

RGBWorkingSpace: Processing view: AN_DBE_Preview01
0.0140 s
Calculating the MTF value:
MTF=0.70000 median=0.00028
MTF=0.61942 median=0.00499
MTF=0.57304 median=0.02293
MTF=0.54925 median=0.04838
MTF=0.53885 median=0.06638
MTF=0.53483 median=0.07485
MTF=0.53338 median=0.07815
MTF=0.53287 median=0.07935
MTF=0.53269 median=0.07977
MTF=0.53262 median=0.07992
*** Error [022]: C:/Program Files/PixInsight64/src/scripts/masked-stretch.js, line 408: TypeError: gc is not a function

Isn't gc() that garbage collector thingy?
Something missing here?
Thanks!


PS: BTW I've never used this script before so I can't tell whether it was working before or not.

 
Hi,
I use Masked stretch V0.9 in a PC Vista 64, and it work just fine every time here.
Cheers

Antoine
 
I don't see that error, but I always have to restart my PixInsight after using MaskedStretch - my app becomes very slow.  I wonder if there is some sort of memory issue occurring?
 
can't answer RBA's question, i've not seen that error and i use it all the time. however, David's issue is very likely that the swap files that PI creates are be filling up your "temp" directory. one is created at every step of the masked stretch. so, after doing a masked stretch i usually clone the view and close the original - this will delete all the swap files created during the masked stretch. i don't know if these files are just sitting on the disk, or if because of the nature of how PI uses them, they are mapped into PI's address space. that might cause your VM system to slow down. so you might try this instead of quitting PI and see what happens.

RBA, is it possible your disk filled up while running masked stretch?

 
Thanks for the feedback everyone.

pfile said:
RBA, is it possible your disk filled up while running masked stretch?

"gc is not a function" doesn't seem like an error that might result from running out of swap space, but just to be sure I added a second entry to the list of swap directories, and the error still happens.

Other scripts that use gc() don't have this problem.

 
I get this error on *all* the scripts with gc() function call.

I had to comment out the call(s) to get them to run.

Is this a garbage collection call that is specific to the PixInsight JavaScript Runtime? 

Eval license Version 1.06.09.0652 Mac OSX x86_64

Woody
 
that's really strange, i'm not seeing any problems with gc() on my mac (x86-64) i am nowhere near up to date on OSX though. i think i'm at 10.6.3.
 
I just installed the commercial license version of PixInsight this evening and the gc(); problem is completely gone.

Woody
 
the same story, win x64 version

Code:
run --execute-mode=auto "C:/Program Files/PixInsight/src/scripts/masked-stretch.js"

Processing script file: C:/Program Files/PixInsight/src/scripts/masked-stretch.js

RGBWorkingSpace: Processing view: M101_Lx10_PI
0.0130 s
Calculating the MTF value:
MTF=0.20000 median=1.00000
MTF=0.47071 median=0.99695
MTF=0.49713 median=0.00822
MTF=0.49468 median=0.02163
MTF=0.49275 median=0.04559
MTF=0.49149 median=0.07331
MTF=0.49089 median=0.09140
MTF=0.49070 median=0.09797
MTF=0.49065 median=0.09958
MTF=0.49065 median=0.09992
*** Error [022]: C:/Program Files/PixInsight/src/scripts/masked-stretch.js, line 408: TypeError: gc is not a function
 
The message "gc is not a function" means that PI's JavaScript engine is completely out of order. The gc function is part of PJSR and invokes JavaScript's garbage collection routine.

I've never seen a message like this, and the MaskedStretch script works on my machines without problems, so this is indeed strange. Does this behavior reproduce consistently, or is it a sporadic problem?

You can try restarting the JavaScript engine. From the console, enter this command:

Code:
run --reset

Let's see if this makes any change.
 
Juan Conejero said:
The message "gc is not a function" means that PI's JavaScript engine is completely out of order. The gc function is part of PJSR and invokes JavaScript's garbage collection routine.

I've never seen a message like this, and the MaskedStretch script works on my machines without problems, so this is indeed strange. Does this behavior reproduce consistently, or is it a sporadic problem?

You can try restarting the JavaScript engine. From the console, enter this command:

Code:
run --reset

Let's see if this makes any change.


I can't either, now. I don't remember what was the image that was causing it.
I have since closed and reopened the PixInsight application though.

If I run into this again, I'll try the reset trick and report.

 
Maybe related: if I execute a script from Script Editor (without first running any script from the menu, see below) I get the error:

ReferenceError: HorizontalSizer is not defined

Of course, makes no sense because it is something that is commonly used. This started happening from a crash of a script I was working (you know, infinite loops...stuff like that :-[ ). But if I run the script from the menu works without errors. Or also if I first run any script from the menu, then works also the script from the Script Editor, now without errors.

Greetings,

Enzo.
 
Back
Top