Difference between revisions of "WAC"

From PREX Wiki
Jump to navigationJump to search
 
(70 intermediate revisions by 8 users not shown)
Line 1: Line 1:
The Weekly Analysis Coordinator (WAC) is a rotating position of 1 week each.  The wac is required to perform their functions every morning.  THIS INCLUDES WEEKENDS!  The plots need to be up by NOON so that people can think about the results for the meeting.
+
[[Weekly Analysis Coordinator]]
  
 +
See old Prex 1 WAC page [[WAC_PREX_1|here]]
  
===Jobs of the WAC===
+
The Weekly Analysis Coordinator (WAC) is a rotating position of 1 week each.  The wac is required to perform their functions every morningTHIS INCLUDES WEEKENDS! The plots need to be up by 11 AM and hold a general meeting with Bluejeans so that people can think about the results.
 
 
====A) Check the new runs====
 
 
 
<blockquote>
 
'''Check''' all the runs taken since the last wac summary.
 
<pre>
 
[apar@adaql4 ~/prex/pan]$ view [runnumber]
 
</pre>
 
 
 
Do a reprompt if there is any doubt about the initial offline analysis.  This is not necessary for every run.
 
<pre>
 
[apar@adaql4 ~/prex/pan]$ reprompt [runnumber]
 
</pre>
 
 
 
'''Look carefully through the output and try to spot problems.'''  For example, Ahmed noticed large outliers in the bcm double differences and this helped us to learn that the dac glitch on the 18 bit ADCs was causing problems.
 
</blockquote>
 
 
 
====B) Update the run database====
 
 
 
<blockquote>
 
For every run the database of runs must be updated.  The database structure is as follows.
 
<pre>
 
+-------------------+------------+------+-----+-------------------+----------------+
 
| Field            | Type      | Null | Key | Default          | Extra          |
 
+-------------------+------------+------+-----+-------------------+----------------+
 
| WACentriesID      | int(11)    |      | PRI | NULL              | auto_increment |
 
| RunInfo_RunNumber | int(11)    | YES  | MUL | NULL              |                |
 
| WACname          | tinytext  | YES  |    | NULL              |                |
 
| WACEntryTime      | timestamp  | YES  |    | CURRENT_TIMESTAMP |                |
 
| WACcomment        | longtext  | YES  |    | NULL              |                |
 
| LeftDETeventLo    | int(11)    | YES  |    | NULL              |                |
 
| LeftDETeventHi    | int(11)    | YES  |    | NULL              |                |
 
| RightDETeventLo  | int(11)    | YES  |    | NULL              |                |
 
| RightDETeventHi  | int(11)    | YES  |    | NULL              |                |
 
| Slug              | int(11)    | YES  |    | NULL              |                |
 
| SlowSign          | tinyint(2) | YES  |    | NULL              |                |
 
| Production        | tinyint(4) | YES  |    | NULL              |                |
 
+-------------------+------------+------+-----+-------------------+----------------+
 
</pre>
 
 
 
The database can be interacted with using the addWACentry.pl script in the wac directory:
 
 
 
<pre>
 
addWACentry.pl -n [username] -r [runnumber]
 
</pre>
 
</blockquote>
 
 
 
====C) Produce the slug summary====
 
 
 
<blockquote>
 
Once the database is up to date, the slug summary is produced using the summary.pl script in the wac directoryThis will produce the summary root (~/prex/ROOTfiles/parity10_000X_slug.root) file and the summary text file (http://www.jlab.org/~adaq/prex/prompt_output/).
 
 
 
<pre>
 
summary.pl -t slug -s [slugnumber]
 
</pre>
 
</blockquote>
 
 
 
====D) Produce the slug plots====
 
 
 
<blockquote>
 
Once the slug summary has been produced, the slug plots are produced using the makePlots.pl script in the wac directory.  This will produce plots at http://www.jlab.org/~adaq/prex/slug_output/
 
 
 
<pre>
 
[apar@adaql4 ~]$ gowac
 
 
 
****** This directory for WAC analysis (WACs only, please) ******
 
 
 
[apar@adaql4 ~/prex/wac]$
 
[apar@adaql4 ~/prex/wac]$ makePlots.pl --type slug --slug 6
 
</pre>
 
 
 
Beware of clobbering, don't run two instances of makePlots.pl at the same time.  They WILL clobber each other.
 
</blockquote>
 
 
 
====E) Update the slug list====
 
 
 
 
 
<blockquote>
 
Update the details in the [[ WAC#Slugs | slugs table. ]]
 
</blockquote>
 
 
 
 
 
====F) Make the cumulative slug plots====
 
 
 
<blockquote>
 
In order to make the cumulative slug plots, you must go to the WAC directory:
 
 
 
<pre>
 
[apar@adaql4 ~]$ gowac
 
 
 
  ****** This directory for WAC analysis (WACs only, please) ******
 
 
 
[apar@adaql4 ~/prex/wac]$
 
</pre>
 
 
 
Run the following command with the parameter (in this case 9) being the latest slug number.
 
 
 
<pre>
 
[apar@adaql4 ~/prex/wac]$ slugSummary 9
 
</pre>
 
 
 
A set of plots will be located here: http://www.jlab.org/~adaq/prex/slug_output/slug_cumulative/
 
 
 
 
 
</blockquote>
 
 
 
===Special Cases===
 
 
 
====Dithering and Regression ====
 
Before you start, make sure that the runlist.txt is up to date. If you are not sure then log onto any apar adaq(6-10) machines and do the following
 
<blockquote>
 
<pre>
 
[apar@adaql6 ~/prex/wac]$ gowac
 
[apar@adaql6 ~/prex/wac]$ getrunlist.pl
 
 
 
Connection successful: handle: DBI::db=HASH(0x8af5628)
 
Obtained 247 run entries.
 
Coping runlist to web location.
 
Thank you for using getrunlist.pl.
 
 
 
[apar@adaql6 ~/prex/wac]$
 
</pre>
 
</blockquote>
 
This will update the runlist.txt.
 
 
 
====Generating dither/regress slope rootfiles ====
 
 
 
parity10_####_regress_M.root is required to generate regress slope root files.
 
 
 
parity10_####_dither.root is required to generate dither slope root files.
 
 
 
So make sure all the necessary runs are prompted properly, and necessary .root files generated. Then in the wac directory:
 
<blockquote>
 
<pre>
 
[apar@adaql6 ~/prex/wac]$ root
 
root [0] .x multirun/obtainBMslopes.C("dither")
 
root [1] .x multirun/obtainBMslopes.C("regress","runlist.txt","lead","M")
 
</pre>
 
</blockquote>
 
This will generate dither_lead.root for dithering and regress_leadM.root in the wac directory. octainBMslopes.C looks at all the runs listed in the runlist for which the respective dither/regress root files exist. So as a wac, you need to ensure that the runlist has been properly updated for necessary cuts, and only include production runs. If the runlist is bad, then the slope root files will have some runs with big outlier slopes that cannot be cut out the the cuts defined in the slope root file.
 
 
 
====Generating dither/regress slope plots ====
 
 
 
The may be complaints for runs if the dithering was off for that run or they were replayed without regression enabled.  Once this is done, the plots are produced as follows.
 
 
 
<blockquote>
 
<pre>
 
[apar@adaql6 ~/prex/wac]$ ./utils/makeRegDitPlots.pl
 
</pre>
 
</blockquote>
 
 
 
====Generating dither slope text files====
 
Before making any slug rootfiles, we need to generate appropriate dither slope text files from the runs in that particular slope. The slopes from this text file are used to dither correct the data for that particular slug. If the text files are not generated before generating the slug rootfiles, then the slug data will not be dither corrected. We need dither slopes rootfile to generate slope text files. So make sure the dither slope rootfile is generated as outlined above. To generate the slope text file
 
<blockquote>
 
<pre>
 
[apar@adaql6 ~/prex/wac]$root
 
root [0] .x multirun/avgSlopes.C(##)
 
</pre>
 
</blockquote>
 
This will generate avgSlopes_lead_dither_slug##.res file where ## is the slug number.
 
 
 
We can also generate slope text files for specified range of runs as
 
<blockquote>
 
<pre>
 
[apar@adaql6 ~/prex/wac]$root
 
root [0] .x multirun/avgSlopes.C(##,**)
 
</pre>
 
</blockquote>
 
where ## is the initial run number, and ** is the final run number. This will generate avgSlopes_lead_dither_runs##_**.res.
 
 
 
All the slope text files are in ~/prex/wac/dither_5x5_slopes.
 
 
 
====Reprompting a lot of runs====
 
 
 
<blockquote>
 
On rare occasions it may be necessary to reprompt a whole bunch of runs.  This can be accomplished in two steps.
 
 
 
1. First get a list of the runs to be reprompted.  So, for example, all the runs in slug 5 can be obtained as follows.
 
 
 
<pre>
 
[apar@adaql5 ~/prex/pan]$ gowac
 
 
 
****** This directory for WAC analysis (WACs only, please) ******
 
 
 
[apar@adaql5 ~/prex/wac]$ grep -P '\t5\t' runlist.txt | cut -f1 | xargs echo
 
2867 2868 2869 2870 2871 2872 2873 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888
 
2903 2904 2905 2906 2907
 
</pre>
 
 
 
2. Next use the following command.
 
 
 
<pre>
 
[apar@adaql5 ~/prex/wac]$ gopan
 
 
 
****** This directory for ONLINE analysis (Shift-Workers only, please) ******
 
 
 
[apar@adaql5 ~/prex/pan]$
 
[apar@adaql5 ~/prex/pan]$
 
[apar@adaql5 ~/prex/pan]$ ./utils/prompt.pl  --forcepan --forcereg --forcedit --conf '' --batch
 
2867 2868 2869 2870 2871 2872 2873 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888
 
2903 2904 2905 2906 2907
 
</pre>
 
 
 
</blockquote>
 
 
 
===Raw Data Files===
 
 
 
====from the adaq machines====
 
 
 
The raw data files for runs were stored at  <pre>/adaql1/data2/parity/ </pre>
 
but at 04:42:27 on September25,2009 Bob changed it so that new data goes to <pre>/adaql1/data4/parity/ </pre> from run 12660 onwards.
 
 
 
====from the silo====
 
 
 
After some time these files are automatically removed.  Once that happens, in order to view them you will have to retrieve them from the silo.  This can be done as follows, from any ifarml machine.
 
<pre>ifarml5> jcache /mss/halla/parity/raw/parity09_12227.dat
 
[2009-10-06 10:29:36] Submitting request [11848406]
 
[2009-10-06 10:29:36] Request [11848406] is queued.
 
</pre>
 
 
 
Some time after requesting the file, it will be available at
 
<pre> /cache/mss/halla/parity/raw/parity09_12227.dat </pre>
 
 
 
===Backend Information===
 
 
 
====Software flowchart====
 
 
 
[[Image:Happex_DAQ.gif]]
 
 
 
====Choosing the data that goes into slug summaries====
 
 
 
The data that goes into the root file output for the slug summary is controlled with the following file:
 
<blockquote>
 
<pre>
 
~/prex/wac/multirun/chooser.txt
 
</pre>
 
</blockquote>
 
 
 
The data that goes into the text file output is set with:
 
<blockquote>
 
<pre>
 
~/prex/wac/multirun/slug.C
 
</pre>
 
</blockquote>
 
 
 
Now, the text file output is generated from the root file, so, anything that appears in slug.C must also appear in chooser.txt for it to work.
 
 
 
====Choosing what is plotted in the slug summary plots====
 
 
 
Two files are used to control what is plot in the slug summaries.  Pair tree variables are set up using the <pre>~/prex/pan/panguin/wac_slug.cfg</pre> file.  The epics variables are set up using the <pre>~/prex/wac/epicsplot/doepicsplot.C</pre> file.  The latter is messy, but it should be reasonably clear how to change things.  Make sure that any epics variable that are need appear in all of the following files.
 
<pre>
 
/adaqfs/home/apar/scripts/fastEpicsLogger (Don't mess around with this file if you are not an expert. You can hang up the DAQ if you are not careful!!)
 
/adaqfs/home/apar/db/misc/Prex.misc
 
</pre>
 
After changes to either of these files, the <pre>~/prex/wac/recent_slug_plots/index.html</pre> file needs to be updated to reflect the correct number of pages that are produced as output.  This is the file that eventually displays the plots as a web page.
 
 
 
== Slugs ==
 
 
 
View the [http://www.jlab.org/~adaq/prex/runlist.txt Runlist].
 
 
 
HWP OUT is 0 in epics and 1 in the WAC database.
 
 
 
HWP IN is 1 in epics and -1 in the WAC database.
 
 
 
{| border="1"
 
|+ Slug Numbers
 
! Slug !! Description !! HWP !! Runs !! Dates !! Plots !! Text summary !! Good Multiplets !! Total Charge
 
|-
 
| 100
 
| Lead-Diamond Target (production?)
 
| IN
 
| 2383 - 2386
 
|-
 
| 1
 
| Empty Target
 
| IN
 
|
 
|-
 
| 3
 
| Lead-Diamond Target (production)  Bad BCMs
 
| IN
 
| 2805 - 2813
 
| 2010-04-16
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug3_plots slug 3 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0003_standard_slug.txt text output]
 
|-
 
| 4
 
| Lead-Diamond Target (production)
 
| OUT
 
| 2815 - 2866
 
| 2010-04-16
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug4_plots slug 4 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0004_standard_slug.txt text output]
 
|-
 
| 5
 
| Lead-Diamond Target (production)
 
| IN
 
| 2867 - 2888, 2902 - 2907
 
| 2010-04-17
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug5_plots slug 5 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0005_standard_slug.txt text output]
 
|-
 
| 6
 
| Lead-Diamond Target (production)
 
| OUT
 
| 2908 - 2927
 
| 2010-04-18
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug6_plots slug 6 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0006_standard_slug.txt text output]
 
|-
 
| 7
 
| Lead-Diamond Target (production)
 
| IN
 
| 2928 - 2941
 
| 2010-04-19 to 2010-04-20
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug7_plots slug 7 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0007_standard_slug.txt text output]
 
|-
 
| 8
 
| Lead-Diamond Target (production)
 
| OUT
 
| 2950 - 2992
 
| 2010-04-20
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug8_plots slug 8 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0008_standard_slug.txt text output]
 
|-
 
| 9
 
| Lead-Diamond Target (production)
 
| IN
 
| 2993 - 3008
 
| 2010-04-20 to 2010-04-21
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug9_plots slug 9 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0009_standard_slug.txt text output]
 
|-
 
| 10
 
| Lead-Diamond Target (production)
 
| OUT
 
| 3009 - 3025
 
| 2010-04-21 to 2010-04-22
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug10_plots slug 10 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0010_standard_slug.txt text output]
 
|1074.9K
 
|1953.2mC
 
|-
 
| 11
 
| Lead-Diamond Target (production)
 
| IN
 
| 3026 - 3061
 
| 2010-04-22 to 2010-04-23
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug11_plots slug 11 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0011_standard_slug.txt text output]
 
|1270.2K
 
|2330.9mC
 
|-
 
| 12
 
| Lead-Diamond Target (production)
 
| OUT
 
| 3062 - 3073, 3077 - 3083
 
| 2010-04-22 to 2010-04-23
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug12_plots slug 12 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0012_standard_slug.txt text output]
 
|1270.2K
 
|2330.9mC
 
|-
 
| 91
 
| Thick Carbon (production)
 
| OUT
 
| 3075,3076, 3084-3098
 
| 2010-04-23 to 2010-04-24
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug91_plots slug 91 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0091_standard_slug.txt text output]
 
|
 
|
 
|-
 
| 92
 
| Thick Carbon (production)
 
| IN
 
| 3099 -
 
| 2010-04-24
 
| [http://www.jlab.org/~adaq/prex/slug_output/slug92_plots slug 92 plots]
 
| [http://www.jlab.org/~adaq/prex/prompt_output/parity10_0092_standard_slug.txt text output]
 
|
 
|
 
|-
 
| 100
 
| Carbon Optics
 
| IN
 
| 2642-2644
 
| 2010-04-06
 
|-
 
| 101
 
| Thick Carbon
 
| IN
 
| 2581-2601
 
| 2010-04-04
 
|-
 
| 102
 
| Lead-Diamond target
 
| IN
 
| 2649-2652,2663
 
| 2010-04-06
 
|-
 
| 103
 
| Lead-Diamond Target
 
| OUT
 
| 2656-2660
 
| 2010-04-06
 
|-
 
| 104
 
| Lead-Diamond Target large A_Q
 
| OUT
 
| 2661
 
| 2010-04-06
 
|-
 
| 105
 
| Thick Carbon
 
| IN
 
| 2664-2665
 
| 2010-04-06
 
|-
 
|}
 

Latest revision as of 22:28, 22 July 2019

Weekly Analysis Coordinator

See old Prex 1 WAC page here

The Weekly Analysis Coordinator (WAC) is a rotating position of 1 week each. The wac is required to perform their functions every morning. THIS INCLUDES WEEKENDS! The plots need to be up by 11 AM and hold a general meeting with Bluejeans so that people can think about the results.