Hi Fred, Sounds like you have been busy! re: > For my image processing of various products, I have macro which utilize > scratch area files for intermediate products. Previously I had to > define a scratch area set for each routine and for each satellite. In > trying to allow use of the same processing macro by various satellites > without interference I have gone to defining area names using random > numbers within a block of a 1000 possible areas. I use time as the seed > for the random number generator, and I check that there are no existing > areas defined within the block of new areas. I then delete the scratch > area definitions at the end of the processing. Hence I have a lot of > .DSSERVE ADD/DEL and .IMGDEL commands. After I made this change this > spring, I have been having problems with all of the ADDE file > definitions being lost. This happens several times a day on my test > machine. I have a setup macro with all the ADDE definitions, but all of > the processing is lost until I can run the setup macro. I have not been > able to replicate the error in a controlled environment. I have tried a > stub program where I define and then delete thousands of ADDE dsserves, > but it will not fail. I tried two different stub programs creating and > deleting areas running at the same time, but again it will not fail. I > am asking for advice on where I might look or what I might try to find > the cause of the problem. At the end of this e-mail I will attach the > code I have for the random number scratch area definition. This is indeed a puzzler. The only ways I know of that all ADDE dataset definitions could be "lost" are: - there is a REDIRECTion in place that defines where to look for the ADDE dataset definition file, RESOLV.SRV, and it somehow gets changed For instance, suppose that there was a REDIRECTion in place that specified that RESOLV.SRV is in the current directory ("."). Further suppose that the directory which the processing is being run from changes. The REDIRECTion would then point to a directory in which RESOLV.SRV does not exist. - the ADDE dataset definition file, RESOLV.SRV, somehow gets deleted Questions: - from what account are your running your processing? - is there a script running in addition to the macro routine that you sketched out below? re: > Another question. I recently looked at the COMET module on three > channel images using the RGB colors. While manual programs such as > Photoshop will generate three channel images, is there a way to do the 3 > channel image generation automatically through Mcidas processing? > Around 20 years ago, the Mcidas workstation had a two channel > enhancement capability and the ET command that could be used to generate > 2 channel image combinations. Is there any current software that can be > used for these 3 channel images? Yes. You want to use the COMBINE application. The procedure for using COMBINE is to load the image that will drive the red gun in one frame; the image that will drive the blue gun in another frame; and the image that will drive the green gun in a third frame. COMBINE then uses each display to create a pseudo-color composite. For a poor demonstration of the process (poor because the wavelength channels of the following are not appropriate) try the following: DATALOC ADD PUB SATEPSANONE.NESDIS.NOAA.GOV SF 1 ERASE;IMGDISP PUB/MEGLOB05V MAG=-5 SF 2 ERASE;IMGDISP PUB/MEGLOB05WV MAG=-5 SF 3 ERASE;IMGDISP PUB/MEGLOB05I MAG=-5 COMBINE 1 3 2 1 A _much_ better example can be made using the three visible channels of MSG, but one needs access to an ADDE server for the MSG data that has all of the channels. I have attached an example display to illustrate a pseudo-color display created by loading the 0.6 um band in frame 1, the 0.8 um band in frame 2, and the 1.6 um band in frame 3. COMBINE and then FRMSAVE were then run as follows: COMBINE 1 3 2 1 VIEW=no FRMSAVE 1 MSG_20100714_1200 TYPE=COMBINE re: McIDAS macro skeleton: > CHARACTER*12 C1,C2,C3,C4,C5,C3A,C4A,C5A > CHARACTER*12 C9,C9A,C9B,C9C,C9D,C9E,C9F,C9G,C9H,C9I,C9J > > ......... other code > > " > " SET UP SCRATCH AREAS IN C9 USING RANDOM NUMBERS > " > > ISTAT=MCGETDAYTIME(IDAY,ITIME) > ISS=MOD(ITIME,100) > MMM=MOD(ITIME/100,100)*60 > > DO 10 I=1,10 > MSS=MMM+ISS+I > IA=MOD(MSS*314159,1000)+4000 > CPOS=CFU(IA) > LENCP=LEN_TRIM(CPOS) > C9='TV/S'//CPOS(1:LENCP) > .DSSERVE ADD (C9) AREA (IA) (IA+10) DEV=NNN > IDESTCT=MCDSNUM(C9,'AREA') > ISTAT=MCADIR(C9,NSORTS,CSORTS,0) > " IF ISTAT EQUALS ZERO, THEN THERE IS ANOTHER EXISTING AREA IN THE > SCRATCH LOCATION > IF(ISTAT.NE.0) GO TO 12 > > .DSSERVE DEL (C9) DEV=NNN > > 10 CONTINUE > > CALL EDEST('SCRATCH AREA NOT PROPERLY SET UP IN DAYNIT',0) > > .DSSERVE ADD TV/SFOG2 AREA 5801 5810 "SCRATCH FOR MAKFOG2 > > C9='TV/SFOG2' > 12 CONTINUE > > " > " SET UP WORK AREAS > " > > LEN1 = LEN_TRIM(C9) > IPOS = 1 > CPOS = CFU(IPOS) > LEN2 = LEN_TRIM(CPOS) > C9A = C9(1:LEN1)//'.'//CPOS(1:LEN2) > > " > > IPOS = 2 > CPOS = CFU(IPOS) > LEN2 = LEN_TRIM(CPOS) > C9B = C9(1:LEN1)//'.'//CPOS(1:LEN2) > > " > > IPOS = 3 > CPOS = CFU(IPOS) > LEN2 = LEN_TRIM(CPOS) > C9C = C9(1:LEN1)//'.'//CPOS(1:LEN2) > > " > > C9ALL=C9(1:LEN1)//'.ALL' > > ..................... other code until program end > > 1000 > > .IMGDEL (C9ALL) DEV=NNN > .DSSERVE DEL (C9) DEV=NNN I will play around with this code snippit to see if anything pops out at me. Cheers, Tom -- **************************************************************************** Unidata User Support UCAR Unidata Program (303) 497-8642 P.O. Box 3000 address@hidden Boulder, CO 80307 ---------------------------------------------------------------------------- Unidata HomePage http://www.unidata.ucar.edu **************************************************************************** Ticket Details =================== Ticket ID: XOE-622682 Department: Support McIDAS Priority: Normal Status: Closed
Attachment:
MSG_20100714_1200.JPG
Description: JPEG image