Changeset 1141 for sans/Dev/trunk
- Timestamp:
- Apr 5, 2019 3:11:26 PM (4 years ago)
- Location:
- sans/Dev/trunk
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/VC_DetectorBinning_Slit.ipf
r1109 r1141 265 265 // TODO : do I use 1/2 of dQ due to the symmetry of my smearing calculation? 266 266 267 // TODO: use only dQy for the portion of the detector that was not masked! 268 269 ii = trunc(ntube/4) //random tube number 270 271 Make/O/D/N=(nYpix) tmpTube,tmpMaskTube 272 tmpTube = qy[ii][p] 273 tmpMaskTube = mask[ii][p] 274 275 // along the tube, keep the value, or set to NaN if masked 276 tmpTube = tmpMaskTube == 0 ? tmpTube : NaN 277 WaveStats/Q tmpTube 267 // ii = trunc(ntube/4) //random tube number 268 // 269 // Make/O/D/N=(nYpix) tmpTube,tmpMaskTube 270 // tmpTube = qy[ii][p] 271 // tmpMaskTube = mask[ii][p] 272 // 273 // // along the tube, keep the value, or set to NaN if masked 274 // tmpTube = tmpMaskTube == 0 ? tmpTube : NaN 275 // WaveStats/Q tmpTube 278 276 // Print V_max 279 // Print V_min 280 281 delQy = abs(V_max - V_min) 282 //print delQy 283 284 // not quite correct - this uses the whole detector height, but there is some masked out 285 // delQy = abs(qy[0][nYpix-1] - qy[0][0]) 286 287 // iBin_qxqy *= delQy 288 // eBin_qxqy *= delQy 277 // Print V_min 278 // delQy = abs(V_max - V_min) 279 280 // DONE: use only dQy for the portion of the detector that was not masked! 281 282 // get delQy from the portion of the detector that is not masked out 283 delQy = V_setDeltaQy_Slit(folderStr,detStr) 289 284 290 285 … … 413 408 AppendText "\\s(iBin_qxqy_FR_pin) iBin_qxqy_FR_pin\r\\s(iBin_qxqy_FT) iBin_qxqy_FT\r\\s(iBin_qxqy_FT_pin) iBin_qxqy_FT_pin" 414 409 EndMacro 410 411 412 // finds the delta Qy for the slit height from the data that is not masked 413 // 414 Function V_setDeltaQy_Slit(folderStr,detStr) 415 String folderStr,detStr 416 417 Variable delQy,min_qy,max_qy 418 419 String folderPath = "root:Packages:NIST:VSANS:"+folderStr 420 String instPath = ":entry:instrument:detector_" 421 422 WAVE qy = $(folderPath+instPath+detStr+":qy_"+detStr) 423 WAVE mask = $("root:Packages:NIST:VSANS:MSK:entry:instrument:detector_"+detStr+":data") 424 425 Duplicate/O qy tmp_qy 426 // for the minimum 427 tmp_qy = (mask == 0) ? qY : 1e6 428 min_qy = WaveMin(tmp_qy) 429 430 // for the maximum 431 tmp_qy = (mask == 0) ? qY : -1e6 432 max_qy = WaveMax(tmp_qy) 433 434 KillWaves/Z tmp_qy 435 436 delQy = max_qy-min_qy 437 438 return(delQy) 439 end -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_BeamCenter.ipf
r1131 r1141 873 873 // 874 874 875 Proc V_DeriveBeamCenters _VelSel()875 Proc V_DeriveBeamCenters() 876 876 877 877 Make/O/T panelWave = {"FL","FR","FT","FB","ML","MR","MT","MB","B"} … … 881 881 882 882 DoAlert 0, "enter the measured beam center reference for Front and Middle panels" 883 V_fDeriveBeamCenters _VelSel()883 V_fDeriveBeamCenters() 884 884 885 885 End … … 920 920 // ** updated these values with fitted arcs of AgBeh (Dec 2018 data, multiple runs) 921 921 // 922 Proc V_fDeriveBeamCenters _VelSel(x_FrontReference,y_FrontReference,x_MiddleReference,y_MiddleReference)922 Proc V_fDeriveBeamCenters(x_FrontReference,y_FrontReference,x_MiddleReference,y_MiddleReference) 923 923 Variable x_FrontReference,y_FrontReference,x_MiddleReference,y_MiddleReference 924 924 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_DataPlotting.ipf
r1129 r1141 87 87 // SetVariable expc,limits={-10,10,0},value= root:Packages:NIST:VSANS:Globals:Plot_1d:gExpC 88 88 89 Button AllQ,pos={320, 28},size={70,20},proc=V_AllQ_Plot_1D_ButtonProc,title="All Q"89 Button AllQ,pos={320,15},size={70,20},proc=V_AllQ_Plot_1D_ButtonProc,title="All Q" 90 90 Button AllQ,help={"Show the full q-range of the dataset"} 91 91 92 Button Offset,pos={320,38},size={70,20},proc=V_RemoveOffset_ButtonProc,title="No Offset" 93 Button Offset,help={"Remove the offset"} 94 92 95 Legend/C/N=text0/J/X=72.00/Y=60.00 93 96 endif … … 385 388 386 389 390 //function to remove the trace offset 391 Function V_RemoveOffset_ButtonProc(ctrlName) : ButtonControl 392 String ctrlName 393 394 ModifyGraph muloffset={0,0} 395 return(0) 396 End 397 398 387 399 //function to restore the graph axes to full scale, undoing any zooming 388 400 Function V_AllQ_Plot_1D_ButtonProc(ctrlName) : ButtonControl … … 390 402 391 403 SetAxis/A 404 return(0) 392 405 End 393 406 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Initialize.ipf
r1138 r1141 85 85 // 86 86 // 200 appears to be a better value - (empirical, based on teflon/converging pinhole data) 87 Constant kReadNoiseLevel_bin4 = 200 88 //Constant kReadNoiseLevel_bin4 = 208 89 Constant kReadNoiseLevel_Err_bin4 = 14 90 87 //Constant kReadNoiseLevel_bin4 = 200 88 //Constant kReadNoiseLevel_Err_bin4 = 14 89 // after binning/processing changes from March 2019: 90 Constant kReadNoiseLevel_bin4 = 3160 // from bkg area of sans30201 (a transmission measurement) 91 Constant kReadNoiseLevel_Err_bin4 = 50 //estimated 91 92 92 93 // TODOHIGHRES: these values are complete fiction 93 94 Constant kReadNoiseLevel_bin1 = 20 94 95 Constant kReadNoiseLevel_Err_bin1 = 1 95 96 97 96 98 97 // Pixel shifts for the back detector to bring the three CCDs into registry … … 112 111 Constant kShift_BottomX_bin1 = 20 113 112 Constant kShift_BottomY_bin1 = 130 114 115 113 116 114 … … 249 247 Execute "Initialize_VSANSPreferences()" 250 248 249 Execute "V_TubeZeroPointTables()" // correction to the beam center 251 250 252 251 // set the lookup waves for log/lin display of the detector images -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Marquee_Operations.ipf
r1131 r1141 347 347 // xctr+=1 348 348 // yctr+=1 349 350 // correct for the zero position (y-position) on the L/R panels not being exactly equal 351 // the lateral scan data from Dec 2018 is used to correct this. The span of zero points 352 // is relatively small (+- 0.5 pixel) but is significant for data using graphite monochromator 353 // 354 // check that the correction waves exist, if not, generate them V_TubeZeroPointTables() 355 Wave/Z tube_num = $("root:Packages:NIST:VSANS:Globals:tube_" + detStr) 356 Wave/Z yCtr_tube = $("root:Packages:NIST:VSANS:Globals:yCtr_" + detStr) 357 if(!WaveExists(tube_num)) 358 Execute "V_TubeZeroPointTables()" 359 Wave/Z tube_num = $("root:Packages:NIST:VSANS:Globals:tube_" + detStr) 360 Wave/Z yCtr_tube = $("root:Packages:NIST:VSANS:Globals:yCtr_" + detStr) 361 endif 362 363 Variable yCorrection = interp(xCtr,tube_num,yCtr_tube) 364 Variable yPixSize = V_getDet_y_pixel_size(gCurDispType,detStr) 365 yPixSize /= 10 // convert mm to cm 366 // offsets were determined in Dec 2018 using: 367 // FR tube # 7 = 61.70 pix 368 // MR tube # 10 = 61.94 pix 349 369 350 370 Print "X-center (in array coordinates 0->n-1 ) = ",xctr … … 353 373 Print "X-center (cm) = ",x_mm/10 354 374 Print "Y-center (cm) = ",y_mm/10 355 375 356 376 if(cmpstr(detStr,"FR") == 0) 377 Print "Reference Y-Center is corrected for tube #7 zero position" 378 379 yCorrection = 61.70 - yCorrection 380 Print "yCorrection (pix) = ",yCorrection 381 Print "yCorrection (cm) = ",yCorrection*yPixSize 357 382 Print "FRONT Reference X-center (cm) = ",x_mm/10 358 Print "FRONT Reference Y-center (cm) = ",y_mm/10 383 Print "FRONT Reference Y-center (cm) = ",y_mm/10 + yCorrection*yPixSize 359 384 endif 360 385 361 386 if(cmpstr(detStr,"MR") == 0) 387 Print "Reference Y-Center is corrected for tube #10 zero position" 388 389 yCorrection = 61.94 - yCorrection 390 Print "yCorrection (pix) = ",yCorrection 391 Print "yCorrection (cm) = ",yCorrection*yPixSize 362 392 Print "MIDDLE Reference X-center (cm) = ",x_mm/10 363 Print "MIDDLE Reference Y-center (cm) = ",y_mm/10 393 Print "MIDDLE Reference Y-center (cm) = ",y_mm/10 + yCorrection*yPixSize 364 394 endif 365 395 … … 367 397 // these corrections are exactly the opposite (subtract, not add) of what is done in V_fDeriveBeamCenters(xFR,yFR,xMR,yMR) 368 398 if(cmpstr(detStr,"FL") == 0) 369 Print "FRONT Reference X-center (cm) (Velocity Selector)= ",x_mm/10 - kBCtrOffset_FL_x // NEW Dec 2018 values370 Print "FRONT Reference Y-center (cm) (Velocity Selector)= ",y_mm/10 - kBCtrOffset_FL_y399 Print "FRONT Reference X-center (cm) = ",x_mm/10 - kBCtrOffset_FL_x // NEW Dec 2018 values 400 Print "FRONT Reference Y-center (cm) = ",y_mm/10 - kBCtrOffset_FL_y 371 401 endif 372 402 373 403 if(cmpstr(detStr,"ML") == 0) 374 Print "MIDDLE Reference X-center (cm) (Velocity Selector)= ",x_mm/10 - kBCtrOffset_ML_x375 Print "MIDDLE Reference Y-center (cm) (Velocity Selector)= ",y_mm/10 - kBCtrOffset_ML_y404 Print "MIDDLE Reference X-center (cm) = ",x_mm/10 - kBCtrOffset_ML_x 405 Print "MIDDLE Reference Y-center (cm) = ",y_mm/10 - kBCtrOffset_ML_y 376 406 endif 377 407 endif -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Menu.ipf
r1131 r1141 29 29 "Trim I(q) points",V_CombineDataGraph() 30 30 "-" 31 "Derive Beam Centers From Reference",V_DeriveBeamCenters _VelSel()31 "Derive Beam Centers From Reference",V_DeriveBeamCenters() 32 32 "-" 33 33 "Back Detector Saturation",Vm_NumberSaturated() … … 50 50 "-" 51 51 "Patch Back Detector Values",V_Patch_Back_Detector() 52 "Patch NumberOfGuides_SSD_Aperture ",V_Patch_Guide_SSD_Aperture() 53 "Patch Beam Stop",V_Patch_BeamStop() 52 54 End 53 55 SubMenu "File Tests" -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_PatchFiles.ipf
r1118 r1141 447 447 fname = S_path + fname 448 448 449 Variable nRows = 1 1449 Variable nRows = 13 450 450 Redimension/N=(nRows,3) ListWave 451 451 Redimension/N=(nRows,3) selWave … … 472 472 listWave[4][2] = num2str(V_getWavelength_spread(fname)) 473 473 474 listWave[5][1] = "distance (source aperture ) (cm)"474 listWave[5][1] = "distance (source aperture to GV) (cm)" 475 475 listWave[5][2] = num2str(V_getSourceAp_distance(fname)) 476 476 … … 481 481 listWave[7][2] = V_getSampleAp_size(fname) 482 482 483 listWave[8][1] = "sample aperture diam (external) (cm)"483 listWave[8][1] = "sample aperture(2) diam (external) (cm)" 484 484 listWave[8][2] = num2str(V_getSampleAp2_size(fname)) 485 485 486 486 listWave[9][1] = "beam stop diameter (Middle) (mm)" 487 listWave[9][2] = num2str(V_getBeamStopC2_size(fname)) 487 // listWave[9][2] = num2str(V_getBeamStopC2_size(fname)) 488 listWave[9][2] = num2str(V_DeduceBeamstopDiameter(fname,"MR")) 488 489 489 490 listWave[10][1] = "beam stop diameter (Back) (mm)" 490 listWave[10][2] = num2str(V_getBeamStopC3_size(fname)) 491 491 // listWave[10][2] = num2str(V_getBeamStopC3_size(fname)) 492 listWave[10][2] = num2str(V_DeduceBeamstopDiameter(fname,"B")) 493 494 listWave[11][1] = "sample aperture(2) to gate valve (cm)" 495 listWave[11][2] = num2str(V_getSampleAp2_distance(fname)) 496 497 listWave[12][1] = "sample to gate valve (cm)" 498 listWave[12][2] = num2str(V_getSampleTableOffset(fname)) 492 499 493 500 … … 1277 1284 val = str2num(listWave[10][2]) 1278 1285 err = V_writeBeamStopC3_size(fname,val) 1286 endif 1287 1288 if ((selWave[11][0] & 2^4) != 0) //"sample aperture to gate valve (cm)" 1289 val = str2num(listWave[11][2]) 1290 err = V_writeSampleAp_distance(fname,val) 1291 endif 1292 1293 if ((selWave[12][0] & 2^4) != 0) //"sample to gate valve (cm)" 1294 val = str2num(listWave[12][2]) 1295 err = V_writeSampleTableOffset(fname,val) 1279 1296 endif 1280 1297 … … 2916 2933 End 2917 2934 2935 2936 Proc V_Patch_Guide_SSD_Aperture(lo,hi,numGuides,sourceDiam_mm) 2937 Variable lo,hi,numGuides=0,sourceDiam_mm=30 2938 2939 V_fPatch_Guide_SSD_Aperture(lo,hi,numGuides,sourceDiam_mm) 2940 End 2941 2942 // simple utility to patch all three at once, since they are all linked and typically 2943 /// are all incorrectly entered by NICE if the number of guides can't be determined 2944 // 2945 // Number of guides 2946 // source aperture to gate valve distance [cm] 2947 // source aperture diameter [mm] 2948 // 2949 // the source aperture is assumed to be circular and the diameter in mm 2950 // 2951 // the value for the A1_to_GV is from tabulated values. (see VC_calcSSD) 2952 // This is the Source aperture to Gate Valve distance 2953 // 2954 // 2955 // lo is the first file number 2956 // hi is the last file number (inclusive) 2957 // 2958 Function V_fPatch_Guide_SSD_Aperture(lo,hi,numGuides,sourceDiam_mm) 2959 Variable lo,hi,numGuides,sourceDiam_mm 2960 2961 2962 Variable ii,jj,A1_to_GV 2963 String fname,detStr 2964 2965 switch(numGuides) 2966 case 0: 2967 A1_to_GV = 2441 2968 break 2969 case 1: 2970 A1_to_GV = 2157 2971 break 2972 case 2: 2973 A1_to_GV = 1976 2974 break 2975 case 3: 2976 A1_to_GV = 1782 2977 break 2978 case 4: 2979 A1_to_GV = 1582 2980 break 2981 case 5: 2982 A1_to_GV = 1381 2983 break 2984 case 6: 2985 A1_to_GV = 1181 2986 break 2987 case 7: 2988 A1_to_GV = 980 2989 break 2990 case 8: 2991 A1_to_GV = 780 2992 break 2993 case 9: 2994 A1_to_GV = 579 2995 break 2996 default: 2997 Print "Error - using default A1_to_GV value" 2998 A1_to_GV = 2441 2999 endswitch 3000 3001 3002 //loop over all files 3003 for(jj=lo;jj<=hi;jj+=1) 3004 fname = V_FindFileFromRunNumber(jj) 3005 if(strlen(fname) != 0) 3006 3007 // write values 3008 V_writeNumberOfGuides(fname,num2str(numGuides)) 3009 3010 V_writeSourceAp_distance(fname,A1_to_GV) 3011 3012 V_writeSourceAp_shape(fname,"CIRCLE") 3013 V_writeSourceAp_size(fname,num2str(sourceDiam_mm)) 3014 3015 else 3016 printf "run number %d not found\r",jj 3017 endif 3018 endfor 3019 3020 return(0) 3021 End 3022 3023 3024 // 3025 // pick the carriage, beamstop number, beamstop shape, and beamstop diameter 3026 // or height and width 3027 Proc V_Patch_BeamStop(lo,hi,carriageStr,bs_num,bsShapeStr,bs_diam,bs_width,bs_height) 3028 Variable lo,hi 3029 String carriageStr="B" 3030 Variable bs_num=2 3031 String bsShapeStr="CIRCLE" 3032 Variable bs_diam=12,bs_width=12,bs_height=300 3033 3034 V_fPatch_BeamStop(lo,hi,carriageStr,bs_num,bsShapeStr,bs_diam,bs_width,bs_height) 3035 End 3036 3037 3038 // 3039 // lo is the first file number 3040 // hi is the last file number (inclusive) 3041 // 3042 Function V_fPatch_BeamStop(lo,hi,carriageStr,bs_num,bsShapeStr,bs_diam,bs_width,bs_height) 3043 Variable lo,hi 3044 String carriageStr 3045 Variable bs_num 3046 String bsShapeStr 3047 Variable bs_diam,bs_width,bs_height 3048 3049 3050 Variable ii,jj,A1_to_GV 3051 String fname,detStr 3052 3053 3054 //loop over all files 3055 for(jj=lo;jj<=hi;jj+=1) 3056 fname = V_FindFileFromRunNumber(jj) 3057 if(strlen(fname) != 0) 3058 3059 if(cmpstr("F",carriageStr) == 0) 3060 Print "front carriage has no beamstops" 3061 endif 3062 3063 if(cmpstr("M",carriageStr) == 0) 3064 // middle carriage (2) 3065 V_writeBeamStopC2num_stop(fname,bs_num) 3066 V_writeBeamStopC2_shape(fname,bsShapeStr) 3067 if(cmpstr("CIRCLE",bsShapeStr)==0) 3068 V_writeBeamStopC2_size(fname,bs_diam) 3069 else 3070 V_writeBeamStopC2_height(fname,bs_height) 3071 V_writeBeamStopC2_width(fname,bs_width) 3072 endif 3073 endif 3074 3075 if(cmpstr("B",carriageStr) == 0) 3076 // back carriage (3) 3077 V_writeBeamStopC3num_stop(fname,bs_num) 3078 V_writeBeamStopC3_shape(fname,bsShapeStr) 3079 if(cmpstr("CIRCLE",bsShapeStr)==0) 3080 V_writeBeamStopC3_size(fname,bs_diam) 3081 else 3082 V_writeBeamStopC3_height(fname,bs_height) 3083 V_writeBeamStopC3_width(fname,bs_width) 3084 endif 3085 endif 3086 3087 else 3088 printf "run number %d not found\r",jj 3089 endif 3090 endfor 3091 3092 3093 return(0) 3094 End 3095 3096 3097 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Protocol_Reduction.ipf
r1122 r1141 2543 2543 tmpReadNoiseLevel_Err = kReadNoiseLevel_Err_bin1 // a constant value 2544 2544 2545 MatrixFilter /N=11 /P=1 median w // /P=n flag sets the number of passes (default is 1 pass) 2546 2547 Print "*** median noise filter 11x11 applied to the back detector (1 pass)***"2545 // MatrixFilter /N=11 /P=1 median w // /P=n flag sets the number of passes (default is 1 pass) 2546 // Print "*** median noise filter 11x11 applied to the back detector (1 pass) ***" 2547 Print "*** 1x1 binning, NO FIlTER ***" 2548 2548 break 2549 2549 case 4: … … 2551 2551 tmpReadNoiseLevel_Err = kReadNoiseLevel_Err_bin4 // a constant value 2552 2552 2553 MatrixFilter /N=3 /P=3 median w // /P=n flag sets the number of passes (default is 1 pass)2553 // MatrixFilter /N=3 /P=3 median w // /P=n flag sets the number of passes (default is 1 pass) 2554 2554 2555 Print "*** median noise filter 3x3 applied to the back detector (3 passes) ***" 2555 // Print "*** median noise filter 3x3 applied to the back detector (3 passes) ***" 2556 Print "*** 4x4 binning, NO FIlTER ***" 2557 2556 2558 break 2557 2559 default: -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_TubeAdjustments.ipf
r1079 r1141 10 10 // 11 11 12 13 14 // these are measured values of the yCenter based on the numbered tube found from a lateral 15 // scan of the detector panel. Tube ranges are limited due to the limited range of travel of each panel. 16 // T/B panels cannot be scanned in this manner. 17 // 18 // Dec 2018 JGB data 19 // 20 Proc V_TubeZeroPointTables() 21 SetDataFolder root:Packages:NIST:VSANS:Globals 22 23 Make/O/D/N=22 tube_MR,yCtr_MR 24 tube_MR[0]= {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21} 25 yCtr_MR[0]= {61.49,62.12,61.95,62.29,61.95,62.25,61.94,61.78,61.83,61.75,61.94,61.84,61.79,61.71,62.03,61.98,61.87,61.65,61.7,61.8,61.52,61.63} 26 27 Make/O/D/N=20 tube_ML,yCtr_ML 28 tube_ML[0]= {27,28,29,29.99,30.95,31.89,32.77,33,34,35,36,37,38,39,40,41,42,43,44,45} 29 yCtr_ML[0]= {61.7,61.83,61.9,61.67,61.73,61.5,61.75,61.97,61.77,61.91,61.7,61.95,61.66,62.1,61.21,61.79,61.94,61.82,61.86,61.74} 30 31 Make/O/D/N=21 tube_FR, yCtr_FR 32 tube_FR[0]= {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20} 33 yCtr_FR[0]= {61.88,61.96,62.15,61.98,62.15,61.94,62.12,61.7,61.82,61.9,61.56,61.7,61.61,62.02,62.07,62.11,62.18,62.35,61.53,61.15,61.86} 34 35 Make/O/D/N=21 tube_FL, yCtr_FL 36 tube_FL[0]= {27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,41.98,42.99,43.98,44.98,45.98,46.98} 37 yCtr_FL[0]= {62.68,62.08,62.73,62.16,62.25,62.53,62,62.42,62.3,62.07,62.26,62.4,62.14,62.34,62.45,62.35,62.15,62.41,62.37,62.24,62.63} 38 39 SetDataFolder root: 40 End 12 41 13 42 // -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Utilities_General.ipf
r1108 r1141 1526 1526 ////// utilities for the back detector to diagnose saturation issues 1527 1527 // 1528 // 1529 // as of March 2019, the detector data is processed differently, with more 1530 // processing done before passing the data to the file. The data is collected 1531 // in 1x1 mode, then filtered (11x11) and rebinned. This increases the 1532 // pixel saturation value to 16399*16 = 262384 1533 // and the read background to Å 200*16 1534 // 1535 // 1536 // 1537 // old values were (pre-March 2019) = saturation value of 16384 and read baackground of 200 1538 // (before the 1x1 collection) 1539 // 1540 1528 1541 1529 1542 Proc Vm_NumberSaturated(folderStr) … … 1538 1551 Duplicate/O $("root:Packages:NIST:VSANS:"+folderStr+":entry:instrument:detector_B:data") tmpData 1539 1552 1540 saturationValue = 163 831541 1542 tmpData = (tmpData == saturationValue) ? NaN : tmpData1553 saturationValue = 16399*16 1554 1555 tmpData = (tmpData > saturationValue-1) ? NaN : tmpData 1543 1556 WaveStats/Q tmpData 1544 1557 num = V_numNaNs … … 1553 1566 // turns the saturated values to lime green 1554 1567 Function V_ColorizeSaturated() 1555 ModifyImage data ctab= {0,163 82,ColdWarm,0},minRGB=0,maxRGB=(32792,65535,1)1568 ModifyImage data ctab= {0,16399*16-1,ColdWarm,0},minRGB=0,maxRGB=(32792,65535,1) 1556 1569 End 1557 1570 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_WorkFolderUtils.ipf
r1119 r1141 518 518 w -= kReadNoiseLevel_bin1 // a constant value 519 519 520 MatrixFilter /N=11 /P=1 median w // /P=n flag sets the number of passes (default is 1 pass) 521 522 Print "*** median noise filter 11x11 applied to the back detector (1 pass)***"520 // MatrixFilter /N=11 /P=1 median w // /P=n flag sets the number of passes (default is 1 pass) 521 // Print "*** median noise filter 11x11 applied to the back detector (1 pass) ***" 522 Print "*** 1x1 binning - subtracted ReadNoise - No Filter ***" 523 523 break 524 524 case 4: 525 525 w -= kReadNoiseLevel_bin4 // a constant value 526 526 527 MatrixFilter /N=3 /P=3 median w // /P=n flag sets the number of passes (default is 1 pass) 528 529 Print "*** median noise filter 3x3 applied to the back detector (3 passes)***"527 // MatrixFilter /N=3 /P=3 median w // /P=n flag sets the number of passes (default is 1 pass) 528 // Print "*** median noise filter 3x3 applied to the back detector (3 passes) ***" 529 Print "*** 4x4 binning - subtracted ReadNoise - No Filter ***" 530 530 break 531 531 default:
Note: See TracChangeset
for help on using the changeset viewer.