Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
daq:decomp_calibrations [2017/02/27 12:26]
peter_bender
daq:decomp_calibrations [2017/02/27 13:49] (current)
weisshaa
Line 4: Line 4:
 == detmap files == == detmap files ==
  
-The calibration procedure starts with a detmap file.  Such a file exists for each quad.  Each file is a plain text list of the offset and gain of each channel of the quad respectively. ​ The channels are seperated ​by new lines. The order of the channels is in the the daq order (i.e the order they arrive at the digitizer, remember Q1 is different). ​  The naming scheme of the files is important for the rest of the scripts to work; current convention is **detmap_Q1.txt**,​ where the 1 could be replaced by any quad number.+The calibration procedure starts with a detmap file.  Such a file exists for each quad.  Each file is a plain text list of the offset and gain of each channel of the quad respectively. ​ The channels are separated ​by new lines. The order of the channels is in the the daq order (i.e the order they arrive at the digitizer, remember Q1 is different). ​  The naming scheme of the files is important for the rest of the scripts to work; current convention is **detmap_Q1.txt**,​ where the 1 could be replaced by any quad number.
  
 A truncated example of a detmap file:  A truncated example of a detmap file: 
Line 22: Line 22:
  
 Above are the first ten channels of the one detmap file.  The first column is the offset, the second column is the gain. The channel is indicted by the row number. Above are the first ten channels of the one detmap file.  The first column is the offset, the second column is the gain. The channel is indicted by the row number.
 +
 +detmap files live in gretina account as ~/​DecompParam/​detmap_YYMMDD
  
 == Splitting the detmap files == == Splitting the detmap files ==
  
-After the creation of the detmap files, they must be split into the corresponding cores and segments. ​ Assuming the above formatted file and standard file convention; this can be done with the script+After the creation of the detmap files, they must be split into the corresponding cores and segments. ​ Assuming the above formatted file and standard file convention; this can be done with the script ​run in same directory where the detmap files live.
- +
-<​code>​  +
-~analysis/​packages/​Calibrations/​split_cal.py +
-</​code>​ +
 This is script is run by passing it the detmap file to be split: This is script is run by passing it the detmap file to be split:
  
Line 206: Line 203:
       0.88523686       0.88523686
 </​code>​ </​code>​
 +
 +Notice the change in line 25, which is the bad segment, to the a large number. ​ This effectively turns of the segment when computing the decomp position. ​
 +
 +== Loading the Decomp File == 
 +
 +Once all the above files have been created, we can load them into the GRETINA DAQ. To do this, we must be logged into the **gretina** account preferably on the computer currently hosting the gretina daq (currently this is **a2.gam**)
 +
 +On gretina:
 +
 +<​code>​
 +cd ~/​DecompParam
 +mkdir detmaps_yymmdd
 +</​code> ​
 +
 +where yymmdd in the above is replaced with the year, month and date respectively. ​ After this directory is created copy all the above created files into the newly created directory.  ​
 +
 +Now we must copy/edit the setfile. The setfiles are located in **~gretina/​DecompParam/​** Copy the last setfile to the current date:
 +
 +<​code>​
 +cp setFile.2017-02-09 setFile.YYYY-MM-DD
 +</​code>​
 +
 +Now the newly created setfile must be edited. Assuming we keep the standard naming convention mentioned here; all one needs to do is a mass search and replace for the old date with the new date.  Using 2017-02-09 as the old example and YYYY-MM-DD as the new example ​
 +
 +<​code>​
 +170209 ​ ->  YYMMDD
 +</​code>​
 +
 +Once the new setfile is edited to point to the newly created Decomp files, we must tell the gretina daq to load use this new setfile. ​ This is done by editing the file **~gretina/​grdecomp.sh** ​  In the file, the parameter FILECONF should be edited to point to the newly created setfile. ​ This parameter is at the top of the file in the first uncommented line.  The convention is to copy the line, comment out the old definition, and change the setfile name in the new line. 
 +
 +
 +== Loading new Decomp Parameters ==
 +
 +Once all the above is done, we must tell the daq to load the new decomp values. This can be done either using the buttons, **GRETINA Stand Alone** of **GRETINA + S800**, or by running the script **~gretina/​grdecomp.sh** directly.
 +
 +After the above load - the daq should be started and left to run for a few minutes. ​ If there is some mistake in the loading of the above files, this will cause the buffers for the bad channels to fill up and the daq will stall. ​
  
  

QR Code
QR Code daq:decomp_calibrations (generated for current page)