[cig-commits] r13452 - in seismo/3D/ADJOINT_TOMO/measure_adj: PLOTS scripts_tomo
carltape at geodynamics.org
carltape at geodynamics.org
Wed Dec 3 11:49:55 PST 2008
Author: carltape
Date: 2008-12-03 11:49:55 -0800 (Wed, 03 Dec 2008)
New Revision: 13452
Modified:
seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_adj.pl
seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_stats_all.pl
seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/combine_3_adj_src_all.pl
seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/prepare_mt_measure_adj.pl
seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl
Log:
Updated run scripts.
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_adj.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_adj.pl 2008-12-03 19:48:00 UTC (rev 13451)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_adj.pl 2008-12-03 19:49:55 UTC (rev 13452)
@@ -223,6 +223,7 @@
# if the time cut is not specified, then use the whole record
if (!$opt_l) {$tmin = $tmin0; $tmax = $tmax0;}
+$trange = $tmax - $tmin;
# plot labels next to the map
@mapstrings = ($edate,$eid,$stMw,$stedep,$strec,$stdist,$staz,"--",${Ttag_plot},$stmodel);
@@ -255,10 +256,10 @@
$Smax = 2;
$Srange = $Smax - $Smin;
-$xtextpos1 = -0.07*$tmax; # ymax label
-$xtextpos2 = 0.05*$tmax; # first window measurement label
-$xtextpos3 = 0.50*$tmax; # title position
-$xtextpos4 = 0.95*$tmax; # final window measurement label
+$xtextpos1 = $tmin - 0.03*$trange; # xmax label
+$xtextpos2 = $tmin + 0.05*$trange; # first window measurement label
+$xtextpos3 = $tmin + 0.50*$trange; # title position
+$xtextpos4 = $tmin + 0.95*$trange; # final window measurement label
$ytextpos5 = 1.35*$Srange; # titles
$ytextpos4 = 1.03*$Srange; # dT label
@@ -277,7 +278,7 @@
$tick = "-Ba50f10:\"Time (s)\":/a1f1S";
$tick2 = "-Ba50f10/a1f1S";
-$pen = "0.7p";
+$pen = "0.7p"; # line thickness for seismograms
$red_pen = "-W${pen},250/0/0";
$black_pen = "-W${pen},0/0/0";
$recon_pen = "-W${pen},0/255/255";
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_stats_all.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_stats_all.pl 2008-12-03 19:48:00 UTC (rev 13451)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_stats_all.pl 2008-12-03 19:49:55 UTC (rev 13452)
@@ -28,9 +28,9 @@
$Ttag = "${sTmin}_${sTmax}";
$sTper = sprintf("T = %i - %i s",$Tmin,$Tmax);
-$dir_source = "/home/carltape/results/SOURCES/socal_11";
-$dir_source_text = "${dir_source}/v11_files_text";
-$file_eids = "${dir_source}/SOCAL_FINAL_CMT_v11_eid";
+$dir_source = "/home/carltape/results/SOURCES/socal_12";
+$dir_source_text = "${dir_source}/v12_files_text";
+$file_eids = "${dir_source}/SOCAL_FINAL_CMT_v12_eid";
#$file_eids = "/net/sierra/raid1/carltape/results/EID_LISTS/syn_run_m12";
if (not -f $file_eids) {die("\n check if $file_eids exists\n")}
open(IN,$file_eids); @eids = <IN>; $nevent = @eids;
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/combine_3_adj_src_all.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/combine_3_adj_src_all.pl 2008-12-03 19:48:00 UTC (rev 13451)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/combine_3_adj_src_all.pl 2008-12-03 19:49:55 UTC (rev 13452)
@@ -54,8 +54,8 @@
# loop over all events
$k = 0;
$imin = 1; $imax = $nevent; # default
-#$imin = 1; $imax = 17;
-#$imin = 92; $imax = $imin;
+#$imin = 1; $imax = 45;
+#$imin = 54; $imax = $imin;
for ($i = $imin; $i <= $imax; $i = $i+1) {
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/prepare_mt_measure_adj.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/prepare_mt_measure_adj.pl 2008-12-03 19:48:00 UTC (rev 13451)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/prepare_mt_measure_adj.pl 2008-12-03 19:49:55 UTC (rev 13452)
@@ -90,12 +90,16 @@
# remove folders in the measurement directory
print CSH "\\rm -rf ${dir_meas_syn} ${dir_meas_data} \n";
-print CSH "mkdir ${dir_meas_syn} ${dir_meas_data} \n";
+#print CSH "mkdir ${dir_meas_syn} ${dir_meas_data} \n";
# copy ALL data and synthetics into measurement directory (BHZ,BHR,BHT)
+# NOTE: copy the whole directory, because the list might be too long for using cp
+# It might be simpler to LINK the data and syn directories to the local run directory.
print CSH "echo copying files into the measurement directory...\n";
-print CSH "cp ${dir_win_run_syn}/* ${dir_meas_syn}\n";
-print CSH "cp ${dir_win_run_data}/* ${dir_meas_data}\n";
+print CSH "cp -r ${dir_win_run_syn} ${dir_meas_syn}\n sleep 2s\n";
+print CSH "cp -r ${dir_win_run_data} ${dir_meas_data}\n sleep 2s\n";
+#print CSH "cp ${dir_win_run_syn}/* ${dir_meas_syn}\n";
+#print CSH "cp ${dir_win_run_data}/* ${dir_meas_data}\n";
# CMTSOLUTION file
#$dir_cmt = "/net/sierra/raid1/carltape/results/SOURCES/socal_6/CMT_files_post_inverted";
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl 2008-12-03 19:48:00 UTC (rev 13451)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl 2008-12-03 19:49:55 UTC (rev 13452)
@@ -10,20 +10,25 @@
# events for which the windowing code has been run.
#
# EXAMPLE (from working measure_adj directory) :
-# run_tomo.pl m13 0 6/30 0.011 1/1/1 2.0/2.5/3.5/3.0 0.7/0.7/5.0/1.0 1.0/0.5 1.0
-# run_tomo.pl m13 0 3/30 0.011 1/1/1 0.25/0.5/3.5/3.0 0.7/0.7/3.0/1.0 1.0/0.5 1.0
-# run_tomo.pl m13 0 2/30 0.011 1/1/1 0.25/0.5/3.5/3.0 0.7/0.7/2.0/1.0 1.0/0.5 1.0
+# run_tomo.pl m14 0 6/30 0.011 1/1/1 2.0/2.5/3.5/3.0 0.7/0.7/5.0/1.0 1.0/0.5 1.0
+# run_tomo.pl m14 0 3/30 0.011 1/1/1 0.25/0.5/3.5/3.0 0.7/0.7/3.0/1.0 1.0/0.5 1.0
+# run_tomo.pl m14 0 2/30 0.011 1/1/1 0.25/0.5/3.5/3.0 0.7/0.7/2.0/1.0 1.0/0.5 1.0
#
# socal m00 - m04
# run_tomo.pl m04 0 6/40 0.011 1/1/1 2.0/2.5/3.5/3.0 0.7/0.7/8.0/1.0 0.2/0.2 0.8
# run_tomo.pl m04 0 2/40 0.011 1/1/1 0.25/0.5/3.5/3.0 0.7/0.7/8.0/1.0 0.2/0.2 0.5
#
+# New m00 run:
+# run_tomo.pl m00 0 6/30 0.011 1/1/1 2.0/2.5/3.5/3.0 0.7/0.7/12.0/1.0 1.0/0.5 1.0
+# run_tomo.pl m00 0 3/30 0.011 1/1/1 2.0/2.5/3.5/3.0 0.7/0.7/6.0/1.0 1.0/0.5 1.0
+# run_tomo.pl m00 0 2/30 0.011 1/1/1 0.25/0.5/3.5/3.0 0.7/0.7/4.0/1.0 1.0/0.5 1.0
+#
# socal m00 - m04, 0.2/0.2
# socal m05 - m08, 0.4/0.4
# socal m09, MAX: 4.0 pm 0.6 (2-30s), 4.0 pm 0.8 (3-30s), 5.0 pm 0.8 (6-30s)
# socal m10, MAX: 2.0 pm 0.6 (2-30s), 3.0 pm 0.8 (3-30s), 5.0 pm 0.8 (6-30s)
# socal m12, MAX: 2.0 pm 0.6 (2-30s), 3.0 pm 0.8 (3-30s), 5.0 pm 1.0 (6-30s)
-# socal m13, MAX: 2.0 pm 1.0 (2-30s), 3.0 pm 1.0 (3-30s), 5.0 pm 1.0 (6-30s)
+# socal m13 --> , MAX: 2.0 pm 1.0 (2-30s), 3.0 pm 1.0 (3-30s), 5.0 pm 1.0 (6-30s)
#
#==========================================================
@@ -50,7 +55,7 @@
if (not -e $dir_pdf_all) {die("check if dir_pdf_all $dir_pdf_all exist or not\n")}
# file containing event IDs, half-durations for source, and number of time-steps for simulations
-$file_eid = "$dir0/results/SOURCES/socal_11/EIDs_simulation_duration";
+$file_eid = "$dir0/results/SOURCES/socal_12/EIDs_simulation_duration";
if (not -f ${file_eid}) {die("check if ${file_eid} exist or not\n")}
open(IN,"${file_eid}"); @elines = <IN>; close(IN);
$nevent = @elines;
@@ -96,9 +101,6 @@
# get sorted stations file for ordering the plots
$file_stations_sort = "$dir0/results/SOURCES/EID_STATION_LISTS/STATIONS_by_${sortlab}_from_${eid}";
if (not -f ${file_stations_sort}) {die("check if file_stations_sort ${file_stations_sort} exist or not\n")}
- print CSH "cp ${file_stations_sort} PLOTS/STATIONS_sort\n";
- open(IN,${file_stations_sort}); @stalines = <IN>; $nrec = @stalines;
- print "Total number of stations sorted by $sortlab is $nrec\n";
print "$ievent -- $imin to $imax : $eid\n";
print CSH "echo $ievent -- $imin to $imax : $eid\n";
@@ -115,7 +117,7 @@
$tstart = -1.5*$hdur;
$tvec = "$tstart/$dt/$nstep";
- $ftag = "${eid}_${Ttag}";
+ $ftag = "${eid}_${Ttag}_${smodel}";
# check if window file exists
$dir_eid = "${dir_out}/$eid/$smodel";
@@ -124,7 +126,7 @@
$dir_meas = "${dir_eid}/MEASURE_${Ttag}";
$dir_adj = "${dir_meas}/ADJOINT_${Ttag}";
- $window_file = "${dir_win}/MEASUREMENT_WINDOWS_${ftag}_${smodel}";
+ $window_file = "${dir_win}/MEASUREMENT_WINDOWS_${ftag}";
#if (-e $dir_adj) {
if (-e $dir_meas) {
@@ -138,6 +140,11 @@
} else {
+ # copy sorted STATIONS file
+ print CSH "cp ${file_stations_sort} PLOTS/STATIONS_sort\n";
+ open(IN,${file_stations_sort}); @stalines = <IN>; $nrec = @stalines; close(IN);
+ print "Total number of stations sorted by $sortlab is $nrec\n";
+
print "--> delete individual PDF files in ${dir_pdf_all}\n";
print CSH "rm -rf ${dir_pdf_all}*/${eid}*\n";
print CSH "sleep 3s\n";
@@ -171,7 +178,7 @@
# make a single PDF, with pages sorted by azimuth or distance
print CSH "cd PLOTS\n";
print CSH "make_pdf_by_event.pl\n";
- $infile5 = "${ftag}_${smodel}_ALL.pdf";
+ $infile5 = "${ftag}_ALL.pdf";
$outfile5 = "${dir_meas}/${infile5}";
print CSH "cp $infile5 $outfile5\n"; # composite PDF into RUN
print CSH "mv $infile5 ${dir_pdf_eid}\n"; # composite PDF into single directory
More information about the CIG-COMMITS
mailing list