[cig-commits] r15475 - in seismo/3D/ADJOINT_TOMO/measure_adj: . PLOTS scripts_tomo
carltape at geodynamics.org
carltape at geodynamics.org
Fri Jul 24 05:47:50 PDT 2009
Author: carltape
Date: 2009-07-24 05:47:49 -0700 (Fri, 24 Jul 2009)
New Revision: 15475
Modified:
seismo/3D/ADJOINT_TOMO/measure_adj/Makefile
seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/make_pdf_by_station.pl
seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_stats_all.pl
seismo/3D/ADJOINT_TOMO/measure_adj/mt_sub.f90
seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/prepare_mt_measure_adj.pl
seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl
seismo/3D/ADJOINT_TOMO/measure_adj/write_par_file.pl
Log:
In the process of transitioning to gfortran compiler and using standard sac libraries.
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/Makefile
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/Makefile 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/Makefile 2009-07-24 12:47:49 UTC (rev 15475)
@@ -1,8 +1,11 @@
F90 = gfortran
-
-#F90_FLAGS = -O2 -ffixed-line-length-132
F90_FLAGS = -O2
+# NEW VERSION WITH DEFAULT SAC LIBRARIES
+#SACLIBDIR=${SACHOME}/lib
+#LIB = -lsacio -lsac -ltau -lm -L/opt/seismo/lib -lDRWFiles -lf90recipes
+
+# ORIGINAL VERSION
LIB = -L/opt/seismo/lib -lDRWFiles -lf90recipes -lDSacio -lDSacLib -lSacTools -lm
MOD = mt_constants mt_variables mt_sub2 mt_sub
@@ -29,6 +32,7 @@
$(MOD_OBJ): $(OBJ_DIR)/%.o : $(SRC_DIR)/%.f90
$(F90) -o $@ $(F90_FLAGS) -c $(SRC_DIR)/$*.f90 -I$(MOD_DIR) -J$(MOD_DIR)
+# Note call to libraries
rotate_adj_src: rotate_adj_src.f90
$(F90) -o rotate_adj_src rotate_adj_src.f90 -L/opt/seismo/lib -lDRWFiles
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/make_pdf_by_station.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/make_pdf_by_station.pl 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/make_pdf_by_station.pl 2009-07-24 12:47:49 UTC (rev 15475)
@@ -10,7 +10,7 @@
# 1 distance
# 2 azimuth
#
-# EXAMPLE (from /net/sierra/raid1/carltape/results/MEASUREMENTS/m16/PDF_ALL_T006_T030):
+# EXAMPLE (from /home/carltape/results/MEASUREMENTS/m16/PDF_ALL_T006_T030):
# make_pdf_by_station.pl
#
#==========================================================
@@ -27,21 +27,21 @@
$isort = 2; # sorted stations by distance (1) or azimuth (2)
# full stations file
-$file_stations = "/net/denali/home1/carltape/gmt/stations/seismic/Matlab_output/STATIONS_CALIFORNIA_TOMO_INNER_gmt";
+$file_stations = "/home/carltape/gmt/stations/seismic/Matlab_output/STATIONS_CALIFORNIA_TOMO_INNER_gmt";
if (not -f ${file_stations}) {die("check if file_stations ${file_stations} exist or not\n")}
open(IN,"${file_stations}"); @stalines = <IN>; close(IN); $nrec = @stalines;
# directory containing sorted stations lists
# (See /ADJOINT_TOMO/iterate_adj/UTILS/station_lists/ )
-$edir = "/net/sierra/raid1/carltape/results/SOURCES/EID_STATION_LISTS";
+$edir = "/home/carltape/results/SOURCES/EID_STATION_LISTS";
# subset list of events that you want to use
-#$file_eid_sub = "/net/sierra/raid1/carltape/results/SOURCES/socal_16/EIDs_only_loc";
-$file_eid_sub = "/net/sierra/raid1/carltape/results/EID_LISTS/eids_simulation";
+#$file_eid_sub = "/home/carltape/results/SOURCES/socal_16/EIDs_only_loc";
+$file_eid_sub = "/home/carltape/results/EID_LISTS/eids_simulation";
if (not -f ${file_eid_sub}) {die("check if ${file_eid_sub} exist or not\n")}
# list of all possible event IDs
-#$file_eid = "/net/sierra/raid1/carltape/results/EID_LISTS/syn_run_${smodel}";
+#$file_eid = "/home/carltape/results/EID_LISTS/syn_run_${smodel}";
#if (not -f ${file_eid}) {die("check if ${file_eid} exist or not\n")}
#open(IN,"${file_eid}"); @elines = <IN>; close(IN);
#$nevent = @elines;
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 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/PLOTS/plot_win_stats_all.pl 2009-07-24 12:47:49 UTC (rev 15475)
@@ -32,16 +32,16 @@
$dir_source_text = "${dir_source}/v${mid}_files_text";
#$file_eids = "${dir_source}/SOCAL_FINAL_CMT_v${mid}_eid";
-#$file_eids = "/net/sierra/raid1/carltape/results/EID_LISTS/eids_simulation";
-$file_eids = "/net/sierra/raid1/carltape/results/EID_LISTS/eids_tomo";
-#$file_eids = "/net/sierra/raid1/carltape/results/EID_LISTS/eids_extra";
+#$file_eids = "/home/carltape/results/EID_LISTS/eids_simulation";
+$file_eids = "/home/carltape/results/EID_LISTS/eids_tomo";
+#$file_eids = "/home/carltape/results/EID_LISTS/eids_extra";
if (not -f $file_eids) {die("\n check if $file_eids exists\n")}
open(IN,$file_eids); @eids = <IN>; $nevent = @eids;
# directories
-$odir = "/net/sierra/raid1/carltape/results/MEASUREMENTS";
+$odir = "/home/carltape/results/MEASUREMENTS";
$dir_all = "$odir/$smodel/PDF_EID_${Ttag}";
-$dir_run = "/net/sierra/raid1/carltape/socal/socal_3D/RUNS";
+$dir_run = "/home/carltape/socal/socal_3D/RUNS";
if (not -e $dir_all) {die("check if $dir_all exist or not\n")}
if (not -e $dir_run) {die("check if $dir_run exist or not\n")}
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/mt_sub.f90
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/mt_sub.f90 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/mt_sub.f90 2009-07-24 12:47:49 UTC (rev 15475)
@@ -202,8 +202,10 @@
wseis_syn(1:nlen) = dzr0(1:nlen)
wseis_dat(1:nlen) = dzr20(1:nlen)
+ print *, 'computing each time window in the frequency domain, calling fft'
call fft(LNPT,wseis_syn,FORWARD_FFT,dt)
call fft(LNPT,wseis_dat,FORWARD_FFT,dt)
+ print *, 'fft successful'
! index of the freq of the max power in the windowed data
ampmax_unw = 0.
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 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/prepare_mt_measure_adj.pl 2009-07-24 12:47:49 UTC (rev 15475)
@@ -53,7 +53,7 @@
# directories for data, synthetics, and window files : MUST BE CHANGED FOR EACH USER
if ($iwindow==1) {
# windowing code run directory
- $dir_win_run = "/net/denali/raid1/carltape/svn/cig/seismo/3D/flexwin_run";
+ $dir_win_run = "/data1/cig/seismo/3D/flexwin_run";
$dir_win_run_syn = "${dir_win_run}/${dir_syn}";
$dir_win_run_data = "${dir_win_run}/${dir_data}";
$win_in = "${dir_win_run}/${dir_meas}/MEASUREMENT_WINDOWS";
@@ -61,7 +61,7 @@
#$dir_win_run_meas = "${dir_win_run}/${dir_meas}";
} else {
- $dir0 = "/net/sierra/raid1/carltape/socal/socal_3D/RUNS/$eid/$smodel";
+ $dir0 = "/home/carltape/RUNS/$eid/$smodel";
$dir1 = "$dir0/WINDOW_${Ttag}";
$dir_win_run_syn = "$dir1/SYN";
@@ -105,7 +105,7 @@
#print CSH "cp ${dir_win_run_data}/* ${dir_meas_data}\n";
# CMTSOLUTION file
-$dir_cmt = "/net/sierra/raid1/carltape/results/SOURCES/socal_16/v16_files";
+$dir_cmt = "/home/carltape/results/SOURCES/socal_16/v16_files";
$cmtfile = "${dir_cmt}/CMTSOLUTION_${eid}";
if (not -f $cmtfile) {die("check if cmtfile $cmtfile exist or not\n")}
print CSH "\\rm CMTSOLUTION*\n";
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/scripts_tomo/run_tomo.pl 2009-07-24 12:47:49 UTC (rev 15475)
@@ -9,6 +9,8 @@
# This is the master program for running the measurement code on all the
# events for which the windowing code has been run.
#
+# NOTE: The command run_mt_measure_adj.pl below contains additional input parameters.
+#
# EXAMPLE (from working measure_adj directory) :
# run_tomo.pl m16 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 m16 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
@@ -46,8 +48,8 @@
#================================================================
# USER INPUT
-$dir0 = "/net/sierra/raid1/carltape";
-$dir_out = "$dir0/socal/socal_3D/RUNS";
+$dir0 = "/home/carltape";
+$dir_out = "$dir0/RUNS";
$dir_pdf_eid = "$dir0/results/MEASUREMENTS/${smodel}/PDF_EID_${Ttag}";
$dir_pdf_all = "$dir0/results/MEASUREMENTS/${smodel}/PDF_ALL_${Ttag}";
if (not -e $dir_out) {die("check if dir_out $dir_out exist or not\n")}
@@ -147,7 +149,7 @@
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 "rm -rf ${dir_pdf_all}/*${eid}*\n";
print CSH "sleep 3s\n";
print "--> run the measurement code and make adjoint sources\n";
@@ -166,10 +168,10 @@
# SOCAL: CC only
- #print CSH "run_mt_measure_adj.pl $smodel 2 3 $ibp $Ts $lcut $tvec 0 1 0 $iparbools $par1 $par2 $par3\n";
+ print CSH "run_mt_measure_adj.pl $smodel 2 3 $ibp $Ts $lcut $tvec 0 1 0 $iparbools $par1 $par2 $par3\n";
# SOCAL: multitaper
- print CSH "run_mt_measure_adj.pl $smodel 1 1 $ibp $Ts $lcut $tvec 0 1 0 $iparbools $par1 $par2 $par3\n";
+ #print CSH "run_mt_measure_adj.pl $smodel 1 1 $ibp $Ts $lcut $tvec 0 1 0 $iparbools $par1 $par2 $par3\n";
# SOCAL: coverage kernels for m16 (CC banana-doughnut adjoint sources)
#print CSH "run_mt_measure_adj.pl $smodel 3 3 $ibp $Ts $lcut $tvec 0 1 0 $iparbools $par1 $par2 $par3\n";
Modified: seismo/3D/ADJOINT_TOMO/measure_adj/write_par_file.pl
===================================================================
--- seismo/3D/ADJOINT_TOMO/measure_adj/write_par_file.pl 2009-07-24 01:03:47 UTC (rev 15474)
+++ seismo/3D/ADJOINT_TOMO/measure_adj/write_par_file.pl 2009-07-24 12:47:49 UTC (rev 15475)
@@ -4,7 +4,7 @@
#
# write_par_file.pl
# Carl Tape
-# 07-June-2008
+# 24-July-2009
#
# This script writes a parameters file to be used in the measurement code.
# See the reading-in of this file in mt_measure_adj.f90.
@@ -23,7 +23,7 @@
# DT_SIGMA_MIN/DLNA_SIGMA_MIN
#
# EXAMPLE:
-# write_par_file.pl OUTPUT_FILES 0 6/40 -3.00/0.011/16400 3 2 0.02/2.5 1/1/1 2.5/2.5/3.0/3.0 0.7/0.7/8.0/1.0 0.2/0.2
+# write_par_file.pl OUTPUT_FILES 0 6/30 -0.585/0.011/18200 3 2 0.02/2.5 1/1/1 2.0/2.5/3.5/3.0 0.69/0.69/4.5/1.0 1.0/0.5
#
#
#==========================================================
More information about the CIG-COMMITS
mailing list