Changeset 1050


Ignore:
Timestamp:
Jun 30, 2017 12:28:55 PM (5 years ago)
Author:
srkline
Message:

cleaning up a lot of the TODO items from the code.

Location:
sans/Dev/trunk/NCNR_User_Procedures/Reduction
Files:
13 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/SANS/EventModeProcessing.ipf

    r1010 r1050  
    15511551                                if(dataval == 0 && RemoveBadEvents == 1) 
    15521552                                        numRemoved += 1 
    1553                                         //Print "zero at ii= ",ii 
     1553//                                      Print "zero at ii= ",ii 
    15541554                                        break           //don't increment ii 
    15551555                                endif 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Combine_1D.ipf

    r1042 r1050  
    184184End 
    185185 
    186 // TODO 
     186//  
    187187// x- verify that the proper waves exist for the binning type 
    188188// 
     
    203203         
    204204         
    205         // TODO: x- need to update this to make sure that the data waves are present before plotting. This 
     205        // x- need to update this to make sure that the data waves are present before plotting. This 
    206206        //    currently looks in the ToTrim folder, but the binning could be wrong in the data folder 
    207207        //    and will be an error... 
     
    535535// take the waves, and convert to strings that can be added to the protocol 
    536536// 
    537 // TODO: 
     537//  
    538538// x- get the variables out of root:, and move it to Protocols 
    539 // -- get the waves out of root:, and move it to Protocols 
     539// x- get the waves out of root:, and move it to Protocols 
    540540// x- be sure that the variables are initialized (done in main initialization 
    541 // -- link this to the panel? 
     541// x- link this to the panel? 
    542542// 
    543543Function V_TrimWaves2String() 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_DataPlotting.ipf

    r1044 r1050  
    109109End 
    110110 
    111 // TODO 
     111//  
    112112// x- winStr is currently hard-wired, but this may not be an issue 
    113113Function V_Update1D_Graph(workType,binType) 
     
    115115        Variable binType 
    116116         
    117         // TODO: 
     117        //  
    118118// x- "B" detector is currently skipped - Q is not yet calculated 
    119119        String str,winStr="V_1D_Data",workPathStr 
     
    444444// V_1D_Data 
    445445// 
    446 // TODO 
     446//  
    447447// x- need to set binType 
    448448// x- currently  hard-wired == 1 
     
    620620// V_1D_Data 
    621621// 
    622 // TODO 
     622//  
    623623// x- need to set binType 
    624624// x- currently  hard-wired == 1 
     
    807807 
    808808 
    809 // TODO 
     809//  
    810810// x- need to set binType 
    811811// x- currently  hard-wired == 1 
     
    981981 
    982982 
    983 // TODO 
     983//  
    984984// x- need to set binType 
    985985// x- currently  hard-wired == 1 
     
    11741174 
    11751175 
    1176 // TODO 
     1176//  
    11771177// x- need to set binType 
    11781178// x- currently  hard-wired == 1 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_EventModeProcessing.ipf

    r1047 r1050  
    4949 
    5050 
    51 // TODO  
    52 // x- these dimensions are hard-wired (OK) 
     51//   
     52// x- these dimensions are hard-wired (OK for now, will need to be additional definitions for Back detector) 
     53// 
     54// XBINS is for an individual panel 
     55// NTUBES is the total number of tubes = (4)(48)=192 
    5356// 
    5457Constant XBINS=48 
     
    6366 
    6467 
     68// Initialization of the VSANS event mode panel 
    6569Proc V_Show_Event_Panel() 
    6670        DoWindow/F VSANS_EventModePanel 
     
    7175End 
    7276 
    73 // TODO: 
     77//  
    7478//  x- need an index table with the tube <-> panel correspondence 
    7579//    NO, per Phil, the tube numbering is sequential: 
     
    127131 
    128132 
    129 // for decimation 
    130         Variable/G root:Packages:NIST:VSANS:Event:gEventFileTooLarge = 150              // 150 MB considered too large 
     133// for decimation (not used for VSANS - may be added back in the future 
     134        Variable/G root:Packages:NIST:VSANS:Event:gEventFileTooLarge = 1500             // 1500 MB considered too large 
    131135        Variable/G root:Packages:NIST:VSANS:Event:gDecimation = 100 
    132136        Variable/G root:Packages:NIST:VSANS:Event:gEvent_t_longest_decimated = 0 
    133137 
    134 // for large file splitting 
     138// for large file splitting (unused) 
    135139        String/G root:Packages:NIST:VSANS:Event:gSplitFileList = ""             // a list of the file names as split 
    136140         
    137 // for editing 
     141// for editing (unused) 
    138142        Variable/G root:Packages:NIST:VSANS:Event:gStepTolerance = 5            // 5 = # of standard deviations from mean. See PutCursorsAtStep() 
    139143         
     
    142146 
    143147 
    144  
     148// 
     149// the main panel for VSANS Event mode 
     150// -- a duplicate of the SANS panel, with the functions I'm not using disabled. 
     151//  could be added back in the future 
     152// 
    145153Proc VSANS_EventModePanel() 
    146154        PauseUpdate; Silent 1           // building window... 
     
    191199        Button button1,pos={389,103},size={120,20},fSize=12,proc=V_ProcessEventLog_Button,title="Bin Event Data" 
    192200 
    193  
     201// NEW FOR VSANS 
    194202        Button button21,pos={580,70},size={120,20},proc=V_SplitToPanels_Button,title="Split to Panels" 
    195203        Button button22,pos={580,90},size={120,20},proc=V_GraphPanels_Button,title="Show Panels" 
     
    240248EndMacro 
    241249 
    242  
     250// 
     251// takes the data that is loaded and binned as a fake 
     252// (192 x 128) panel to the four LRTB panels, each with 48 tubes 
     253// 
    243254Function V_SplitToPanels_Button(ba) : ButtonControl 
    244255        STRUCT WMButtonAction &ba 
     
    257268End 
    258269 
     270 
     271// 
     272// after splitting the data into the 4 panels, draws a simple graph to display the panels 
     273// 
    259274Function V_GraphPanels_Button(ba) : ButtonControl 
    260275        STRUCT WMButtonAction &ba 
     
    272287        return 0 
    273288End 
     289 
    274290 
    275291// mode selector 
     
    477493end 
    478494 
     495// 
    479496// for oscillatory mode 
     497// 
     498// Allocate the space for the data as if it was a single 192 x 128 pixel array. 
     499// The (4) 48-tube panels will be split out later. this means that as defined, 
     500// XBINS is for an individual panel 
     501// NTUBES is the total number of tubes = (4)(48)=192 
    480502// 
    481503Function V_Osc_ProcessEventLog(ctrlName) 
     
    615637// - since I don't know if I've sorted or un-sorted. Osc mode always forces a re-sort and a re-index 
    616638// 
     639// 
     640// Allocate the space for the data as if it was a single 192 x 128 pixel array. 
     641// The (4) 48-tube panels will be split out later. this means that as defined, 
     642// XBINS is for an individual panel 
     643// NTUBES is the total number of tubes = (4)(48)=192 
     644// 
    617645Function V_Stream_ProcessEventLog(ctrlName) 
    618646        String ctrlName 
     
    803831        return(0)        
    804832End 
     833 
    805834 
    806835// TODO 
     
    877906 
    878907 
    879 // TODO: 
    880 // 
     908//  
     909// -- The "file too large" check has currently been set to 1.5 GB 
    881910// 
    882911//       
     
    887916        Variable err=0 
    888917        Variable fileref,totBytes 
    889         NVAR fileTooLarge = root:Packages:NIST:VSANS:Event:gEventFileTooLarge           //limit load to 150MB 
     918        NVAR fileTooLarge = root:Packages:NIST:VSANS:Event:gEventFileTooLarge           //limit load to 1500MB 
    890919 
    891920        SVAR filename = root:Packages:NIST:VSANS:Event:gEvent_logfile 
     
    910939        endif 
    911940 
    912 // TODO - decide if I want (or need) to keep this        
     941//  keep this   , but set to 1.5 GB 
     942// since I'm now in 64-bit space 
    913943/// Abort if the files are too large 
    914 //      Open/R fileref as fileName 
    915 //              FStatus fileref 
    916 //      Close fileref 
    917 // 
    918 //      totBytes = V_logEOF/1e6         //in MB 
    919 //      if(totBytes > fileTooLarge) 
    920 //              sprintf abortStr,"File is %g MB, larger than the limit of %g MB. Split and Decimate.",totBytes,fileTooLarge 
    921 //              Abort abortStr 
    922 //      endif 
    923 //       
    924 //      Print "TotalBytes = ",totBytes 
     944        Open/R fileref as fileName 
     945                FStatus fileref 
     946        Close fileref 
     947// 
     948        totBytes = V_logEOF/1e6         //in MB 
     949        if(totBytes > fileTooLarge) 
     950                sprintf abortStr,"File is %g MB, larger than the limit of %g MB. Split and Decimate.",totBytes,fileTooLarge 
     951                Abort abortStr 
     952        endif 
     953//       
     954        Print "TotalBytes (MB) = ",totBytes 
    925955         
    926956 
     
    936966// assign to the proper panels 
    937967 
    938 // TODO: 
    939 // x- (YES - this is MUCH faster) what if I do the JointHistogram first, then break out the blocks of the  
    940 //  3D sliced data into the individual panels. Then the sort operation could be skipped, 
    941 //  since it would implicitly be done during the histogram operation 
     968//  
     969// x- (YES - this is MUCH faster) if I do the JointHistogram first, then break out the blocks of the  
     970//  3D sliced data into the individual panels. Then the sort operation can be skipped, 
     971//  since it is implicitly be done during the histogram operation 
    942972// x- go back and redimension as needed to get the 128 x 192 histogram to work 
    943973// x- MatrixOp or a wave assignemt should be able to break up the 3D 
     
    947977                Duplicate/O eventTime timePt 
    948978 
    949 // TODO: 
     979//  
    950980// x- for processing, initially treat all of the tubes along x, and 128 pixels along y 
    951981//   panels can be transposed later as needed to get the orientation correct 
     
    962992//s_toc() 
    963993 
    964  
    965994// 
    966995// switch the "active" panel to the selected group (1-4) (5 concatenates them all together) 
     
    969998// and redimension them to be sure that they are double precision 
    970999// 
    971  
     1000// 
    9721001//      V_SwitchTubeGroup(1) 
    973  
    974 //       
     1002// 
     1003//       
     1004 
    9751005//tic() 
    9761006        Wave timePt=timePt 
     
    9811011         
    9821012        NVAR gResol = root:Packages:NIST:VSANS:Event:gResol             //timeStep in clock frequency (Hz) 
     1013        Printf "Time Step = 1/Frequency (ns) = %g\r",(1/gResol)*1e9 
     1014         
    9831015///// 
    9841016// now do a little processing of the times based on the type of data 
     
    10041036// MODE_TISANE 
    10051037 
     1038 
    10061039// MODE_TOF 
    10071040        if(mode == MODE_TOF)            // TOF mode - don't adjust the times, we get periodic t0 to reset t=0 
     
    10281061// -- MUCH faster to count the number of lines to remove, then delete (N) 
    10291062// rather then delete them one-by-one in the do-loop 
     1063// 
    10301064Function V_CleanupTimes(xLoc,yLoc,timePt) 
    10311065        Wave xLoc,yLoc,timePt 
     
    10761110 
    10771111 
    1078 // TODO (DONE) 
     1112// (DONE) 
    10791113// this "fails" for data sets that have 3 or 4 slices, as the ModifyImage command 
    10801114// interprets the data as being RGB - and so does nothing. 
     
    11371171//  for 64-bit values: 
    11381172// http://calc.penjee.com 
     1173// 
     1174// 
    11391175// 
    11401176//              K0 = 536870912 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_HDF5_Read.ipf

    r1044 r1050  
    259259End 
    260260 
    261 // cut in JUNE 2017 
    262 //// TODO - should be the file name as saved on disk, currently it's not 
     261// **cut in JUNE 2017 
     262////  x- should be the file name as saved on disk, currently it's not 
    263263//Function/S V_getFile_name(fname) 
    264264//      String fname 
     
    269269//End 
    270270 
    271 // cut in JUNE 2017              
     271// **cut in JUNE 2017            
    272272//// 
    273273//Function/S V_getHDF_version(fname) 
     
    314314 
    315315// list of user names 
    316 // TODO -- currently not written out to data file?? 
     316//  x- currently not written out to data file?? 
    317317Function/S V_getUserNames(fname) 
    318318        String fname 
     
    330330// TODO -- for the control section, document each of the fields 
    331331 
    332 // cut in JUNE 2017 
     332// **cut in JUNE 2017 
    333333//Function/S V_getCount_end(fname) 
    334334//      String fname 
     
    339339//end 
    340340 
    341 // cut in JUNE 2017 
     341// **cut in JUNE 2017 
    342342// 
    343343//Function/S V_getCount_start(fname) 
     
    381381end 
    382382 
    383 // cut in JUNE 2017 
     383// **cut in JUNE 2017 
    384384// 
    385385//Function V_getIntegral(fname) 
     
    416416end 
    417417 
    418 // cut in JUNE 2017 
    419 // TODO - what are the enumerated types for this? 
     418// **cut in JUNE 2017 
     419// - what are the enumerated types for this? 
    420420//Function/S V_getPreset(fname) 
    421421//      String fname 
     
    434434//////// INSTRUMENT 
    435435 
    436 // TODO -- this does not appear to be written out 
     436// x- this does not appear to be written out 
    437437Function/S V_getLocalContact(fname) 
    438438        String fname 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Initialize.ipf

    r1044 r1050  
    2626// TODO -- need to set up a separate file of "constants" or "globals" where the actual numbers are 
    2727//stored. If there are not a lot, that place could be here. InitFacilityGlobals() is currently in NCNR_Utils.ipf 
    28  
    29  
    30  
    31 // 
    32 /// Search for TODO to clean up the missing pieces 
    33 // 
    34  
    3528 
    3629 
     
    8174//it leaves data in them untouched 
    8275// 
    83 // TODO -- make sure that I have all of the folders that I need 
     76// x-- make sure that I have all of the folders that I need 
    8477// 
    8578Function V_InitFolders() 
     
    272265 
    273266/////////////////////////////////////////////// 
    274 // 
     267// TODO 
    275268////////////// everything below needs to be re-written for VSANS 
    276269// 
     
    278271 
    279272 
    280 // TODO 
     273//  
    281274// do I need to make the protocols any longer for VSANS? (yes -- now 12 points) 
    282275// What other options for processing / averaging / saving are needed?? 
    283 // - TODO 
     276// TODO 
    284277// x- likely that I'll want to have #pts to cut from I(q) as input to NSORT within the protocol so that the  
    285278// entire reduction can be automatic 
    286279// 
    287280// 
    288 // -- creates the "base" protocols that should be available, after creating the data folder 
    289 // -- all protocols are kept in the root:Packages:NIST:VSANS:Globals:Protocols folder, created here 
     281// x- creates the "base" protocols that should be available, after creating the data folder 
     282// x- all protocols are kept in the root:Packages:NIST:VSANS:Globals:Protocols folder, created here 
    290283// 
    291284// 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MainPanel.ipf

    r1048 r1050  
    1414 
    1515 
    16 // TODO 
    17 // 
    18 // -- update this to be VSANS-specific, eliminating junk that is SANS only or VAX-specific 
    19 // 
    20  
    21  
    22 // TODO-- decide whether to automatically read in the mask, or not 
    23 // -- there could be a default mask, or look for the mask that is speficied in the 
     16//  
     17// 
     18// x- update this to be VSANS-specific, eliminating junk that is SANS only or VAX-specific 
     19// 
     20 
     21 
     22//  
     23// x- decide whether to automatically read in the mask, or not (NO) 
     24// x- there could be a default mask, or look for the mask that is speficied in the 
    2425// next file that is read in from the path 
    2526Proc PickPath_MainButtonProc(ctrlName) : ButtonControl 
     
    174175End 
    175176 
    176 // TODO -- fill in with a proper reader that will display the mask(s) 
     177//  
     178// - fill in with a proper reader that will display the mask(s) 
    177179Proc ReadMask_MainButtonProc(ctrlName) : ButtonControl 
    178180        String ctrlName 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MaskUtils.ipf

    r1043 r1050  
    2121///// LOADING 
    2222 
    23 // TODO - when mask is loaded, need to be sure to clean up the "extra" waves that may be present 
    24 //  - the overlay and the currentTube waves since these are not overwritten or killed when new mask  
     23// TODO  
     24// -- when mask is loaded, need to be sure to clean up the "extra" waves that may be present 
     25// 
     26// -- the overlay and the currentTube waves since these are not overwritten or killed when new mask  
    2527//  data is read in from HDF. need to manually? check for these and delete then, or the data and 
    2628//  mask overlay will be out of sync. 
     
    5052 
    5153 
    52 // TODO -- document the arrow keys moving the tube number and adding/deleting tubes from the mask 
     54// TODO 
     55// -- document the arrow keys moving the tube number and adding/deleting tubes from the mask 
    5356//  this is done through a window hook function (LR moves tube number, up/down = add/delete) 
    5457// 
    55 // TODO -- make the arrow keys Igor 6 compatible - search for specialKeyCode or Keyboard Events in the help file 
     58// TODO 
     59// -- make the arrow keys Igor 6 compatible - search for specialKeyCode or Keyboard Events in the help file 
    5660//     and what needs to be replaced for Igor 6 
    57 // TODO -- for L/R panels, the maksing of columns should be sufficient. Tubes are vertical. For the T/B panels 
     61// TODO 
     62// -- for L/R panels, the maksing of columns should be sufficient. Tubes are vertical. For the T/B panels 
    5863//         the L/R panels cast a vertical shadow (=vertical mask) AND the tubes are horizontal, so the individual 
    5964//         tubes will likely need to be masked in a horizontal line too, per tube. ADD this in... 
     
    106111 
    107112// 
    108 // TODO - may need to adjust the display for the different pixel dimensions 
     113// TODO 
     114// -- may need to adjust the display for the different pixel dimensions 
    109115//      ModifyGraph width={Plan,1,bottom,left} 
    110116// 
    111 // TODO -- need buttons for: 
    112 //              -- quit 
     117// TODO 
     118//  need buttons for: 
     119//              -- quit (to exit gracefully) 
    113120//    -- help (button is there, fill in the content) 
    114121// 
     
    240247//                      Textbox /C/N=Message/W=KeyboardEventsGraph/A=MT/X=0/Y=15 text 
    241248 
    242                 // TODO:  this is all Igor-7 ONLY 
     249                // NOTE:  these special keyCodes are all Igor-7 ONLY 
    243250 
    244251// Note that I need to keep track of the index value since I'm intercepting the  
     
    584591// overlay the mask 
    585592// 
    586 // TODO 
     593//  
    587594// x- remove the old mask first 
    588595// x- make the mask "toggle" to remove it 
     
    716723// 
    717724// 
    718 // TODO -- make the number of pixels GLOBAL 
    719 // TODO -- there will be lots of work to do to develop the procedures necessary to actually generate the  
     725// TODO 
     726// -- make the number of pixels GLOBAL 
     727//  x- there will be lots of work to do to develop the procedures necessary to actually generate the  
    720728//      9 data sets to become the MASK file contents. More complexity here than for the simple SANS case. 
    721729// 
    722 // TODO -- this is currently random 0|1 values, need to write an editor 
     730//  x- this is currently random 0|1 values, need to write an editor 
    723731// 
    724732// currently set up to use 1 = YES MASK == exclude the data 
     
    832840 
    833841// TODO 
    834 // currently, there are no dummy fill values or attributes for the fake MASK file 
     842// -- currently, there are no dummy fill values or attributes for the fake MASK file 
    835843// 
    836844Proc Setup_VSANS_MASK_Struct() 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MultipleReduce.ipf

    r1043 r1050  
    119119//and ensures that files in returned list are RAW data , and can be found on disk 
    120120// 
    121 Function/S  FullNameListFromFileList(list) 
     121Function/S  V_FullNameListFromFileList(list) 
    122122        String list 
    123123         
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Transmission.ipf

    r1041 r1050  
    55 
    66// TODO 
    7 //-- initialization 
     7// -- initialization 
    88// x- link to main panel 
    99// 
     
    5858EndMacro 
    5959 
    60 // TODO -- fill in the details 
     60// TODO 
     61// -- fill in the details 
    6162// -- currently, I pick these from the Catalog, for speed 
    6263// -- ? is the catalog current? 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_TubeAdjustments.ipf

    r1049 r1050  
    1212 
    1313// 
    14 // TODO 
    15 // -- need a way to generate the known, physical dimensions of the slots 
     14//  
     15// x- need a way to generate the known, physical dimensions of the slots 
    1616// Make/O/D/N=5 peak_spacing_mm_ctr 
    1717// peak_spacing_mm_ctr = {-350,-190,0,190,350} (to be filled in with the correct measurements,  
    1818//   possibly different for each panel) 
    1919// 
    20 // -- a 128 point wave "tube_pixel" (=p) is made in V_ArrayToTubes(), and is needed for the WM 
     20// x- a 128 point wave "tube_pixel" (=p) is made in V_ArrayToTubes(), and is needed for the WM 
    2121//   procedures to identify the peak positions. 
    2222// 
    23 // -- fit with either gauss or lor function to get non-integer pixel values for the peak locations 
    24 // 
    25 // -- do I fit each individually to "tweak" the located values, or fit all 5 at once with a  
     23// x- fit with either gauss or lor function to get non-integer pixel values for the peak locations 
     24// 
     25// x- do I fit each individually to "tweak" the located values, or fit all 5 at once with a  
    2626//    custom fit function and guess some good starting values for peak height, location, etc. 
    2727//  
    2828// 
    29 // -- find a way to display all of the results - in a way that can quickly identify any fits 
     29// x- find a way to display all of the results - in a way that can quickly identify any fits 
    3030//    that may be incorrect 
    3131// 
     
    9393// 
    9494 
    95 // TODO 
    96 // -- need a routine to set up the actual measurements of the slot positions 
    97 // 
    98 // 
    99 // TODO 
    100 // -- the slot positioning is different for the L/R and T/B detectors 
     95//  
     96// x- need a routine to set up the actual measurements of the slot positions 
     97// 
     98// 
     99//  
     100// x- the slot positioning is different for the L/R and T/B detectors 
    101101// 
    102102Proc V_SetupSlotDimensions() 
     
    281281        Variable ind 
    282282         
    283 // TODO 
    284 // -- hard-wired for 5 peaks 
     283//  
     284// x- hard-wired for 5 peaks 
    285285 
    286286        Variable ii,lo,hi 
     
    410410 
    411411 
    412  
    413412//¥Duplicate tube1 tube1_mm 
    414413//¥tube1_mm = V_TubePix_to_mm(fit_coef[0][0],fit_coef[1][0],fit_coef[2][0],p) 
    415  
    416  
    417414 
    418415 
     
    722719 
    723720//////////////////////////// 
    724  
     721// 
     722// Main entry - open the panel and go through 
     723// each of the steps for each of the detector panels 
     724// 
    725725Proc V_TubeCoefPanel() : Panel 
    726726        PauseUpdate; Silent 1           // building window... 
     
    763763 
    764764 
     765// a simple display of the refined results 
     766// 
    765767Function V_PeakPlotButton(ba) : ButtonControl 
    766768        STRUCT WMButtonAction &ba 
     
    778780End 
    779781 
    780  
     782// generate the waves and the table 
     783// 
    781784Function V_TableForPeaksButton(ba) : ButtonControl 
    782785        STRUCT WMButtonAction &ba 
     
    794797End 
    795798 
    796  
     799// use the WM procedures to quickly identify the peak position (and height) 
     800// to be used in the refining fits 
     801// 
    797802Function V_IdentifyPeaksButton(ba) : ButtonControl 
    798803        STRUCT WMButtonAction &ba 
     
    810815End 
    811816 
     817// generate the waves and the table 
     818// 
    812819Function V_RefineTableButton(ba) : ButtonControl 
    813820        STRUCT WMButtonAction &ba 
     
    825832End 
    826833 
     834// using the initial peak locations from WM, refine the values 
     835// by fitting each individual peak 
     836// 
    827837Function V_RefinePeaksButton(ba) : ButtonControl 
    828838        STRUCT WMButtonAction &ba 
     
    840850End 
    841851 
     852// finally, with the peak positions, make waves and a table for the  
     853// quadratic coefficients 
     854// 
    842855Function V_QuadFitTableButton(ba) : ButtonControl 
    843856        STRUCT WMButtonAction &ba 
     
    855868End 
    856869 
     870// fit all of the peak positions per tube vs. the actual mm locations to 
     871// obtain the quadratic coefficients 
     872// 
    857873Function V_QuadFitButton(ba) : ButtonControl 
    858874        STRUCT WMButtonAction &ba 
     
    871887 
    872888 
    873  
     889// fill the waves and table with the hard-wired slot positions (mm) 
     890// 
    874891Function V_Setup_MasksButton(ba) : ButtonControl 
    875892        STRUCT WMButtonAction &ba 
     
    888905 
    889906 
    890  
     907// convert the named detector array to 48 individual tube waves 
     908// 
    891909Function V_ArrayToTubesButton(ba) : ButtonControl 
    892910        STRUCT WMButtonAction &ba 
     
    906924 
    907925/////////////////////////// 
    908  
    909  
     926// 
     927// unused - a simple line graph for each tube is much simpler 
     928// 
    910929Window Gizmo_refinedPositions() : GizmoPlot 
    911930        PauseUpdate; Silent 1           // building window... 
     
    946965EndMacro 
    947966 
     967/////////////////////////// 
     968// 
     969// unused - a simple line graph for each tube is much simpler 
     970// 
    948971Window Gizmo_DetPanel() : GizmoPlot 
    949972        PauseUpdate; Silent 1           // building window... 
     
    10091032End 
    10101033 
     1034 
     1035/////////////// 
     1036// 
     1037// An easy way to see the fit results to check if the peak locations all make sense. 
     1038// 
    10111039Window V_PeakResultsGraph() : Graph 
    10121040        PauseUpdate; Silent 1           // building window... 
     
    10281056EndMacro 
    10291057 
    1030  
     1058// 
     1059// cycle through the tubes 
     1060// 
    10311061Function V_TubePeakSetVarProc(sva) : SetVariableControl 
    10321062        STRUCT WMSetVariableAction &sva 
     
    10671097// array is unchanged. Alternatively, the data could be pulled from the RawVSANS folder after a 
    10681098// file catalog operation 
    1069  
     1099// 
    10701100Macro V_CopyDetectorsToRoot() 
    10711101 
     
    10841114End 
    10851115 
     1116// 
     1117// 
    10861118Macro V_SaveDetectorsITX() 
    10871119// binary save makes each wave an individual file. Igor text groups them all into one file. 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Utilities_General.ipf

    r1044 r1050  
    6464End 
    6565 
    66 // TODO 
     66//  
    6767// 
    6868// very simple function to look for something in a work folder 
     
    222222 
    223223 
    224 // TODO: 
     224//  
    225225// x- this still does not quite work. If there are no sub folders present in the RawVSANS folder 
    226226//    it still thinks there is (1) item there. 
    227 // -- if I replace the semicolon with a comma, it thinks there are two folders present and appears 
     227// x- if I replace the semicolon with a comma, it thinks there are two folders present and appears 
    228228//    to delete the RawVSANS folder itself! seems very dangerous...this is because DataFolderDir returns 
    229229//    a comma delimited list, but with a semicolon and \r at the end. need to remove these... 
    230230// 
    231 // -- for use with progress bar, kills only one folder, returns the new number of folders left 
    232 // -- if n(in) = n(out), nothing was able to be killed, so return "done" code 
     231// x- for use with progress bar, kills only one folder, returns the new number of folders left 
     232// x- if n(in) = n(out), nothing was able to be killed, so return "done" code 
    233233Function V_CleanOutOneRawVSANS() 
    234234 
     
    494494        endif 
    495495 
    496         // TODO 
     496        //  
    497497        // x- update the 1D plotting as needed. these are SANS calls (OK for now, but will need to be better) 
    498498        //do the average and plot (either the default, or what is on the panel currently) 
     
    602602 
    603603// 
    604 // TODO x- for VSANS Nexus files, how do I quickly identify if a file is 
     604// x- for VSANS Nexus files, how do I quickly identify if a file is 
    605605//   RAW VSANS data? I don't want to generate any errors, but I want to quickly 
    606606//   weed out the reduced data sets, etc. from file catalogs. 
     
    644644End 
    645645 
    646 // TODO x- need to fill in correctly by determining this from the INTENT field 
     646// x- need to fill in correctly by determining this from the INTENT field 
    647647// 
    648648Function V_isTransFile(fname) 
     
    864864// - list is SEMICOLON-delimited 
    865865// 
    866 // TODO: decide how to do this... 
     866// decide how to do this... 
    867867// (1) 
    868868// checks each file in the directory to see if it is a RAW data file by 
     
    875875//  (was .saN), now key on ".nxs.ngv"? 
    876876// 
    877 // called by PatchFiles.ipf, Tile_2D.ipf 
     877// ** use method (2), reading each file is just way too slow 
     878// 
    878879// 
    879880Function/S V_GetRawDataFileList() 
     
    916917 
    917918// 
    918 // TODO: 
    919 // -- does this need to be more sophisticated? 
     919//  
     920// x- does this need to be more sophisticated? 
    920921// 
    921922// simple "not" of V_GetRawDataFileList() 
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_VSANS_Preferences.ipf

    r1031 r1050  
    22 
    33 
    4 /// TODO 
    5 // -- update all to be only VSANS-specific 
    6 // -- update all of the function names to be unique to VSANS so that there are no 
     4///  
     5// x- update all to be only VSANS-specific 
     6// x- update all of the function names to be unique to VSANS so that there are no 
    77//    name clashes with the "duplicate" version that is in PlotUtils.ipf 
    88// 
    9 // -- Make this a VSANS-only panel 
    10 // -- eliminate the USANS tab 
    11 // -- be sure the general tab is either unique, or eliminate it 
    12 // -- be sure the Analysis tab is unique, or eliminate it 
     9// x- Make this a VSANS-only panel 
     10// x- eliminate the USANS tab 
     11// x- be sure the general tab is either unique, or eliminate it 
     12// x- be sure the Analysis tab is unique, or eliminate it 
    1313// 
    1414// 
     
    3333 
    3434 
    35 // TODO -- there are more detector specific corrections here that need to be added 
     35//  x- there are more detector specific corrections here that need to be added 
    3636// 
    3737// create the globals here if they are not already present 
Note: See TracChangeset for help on using the changeset viewer.