Take into account parameter extent when writing header for PyLoT-input file.
This commit is contained in:
parent
5958e05f3b
commit
27597e6b4b
@ -1 +1 @@
|
||||
33d8-dirty
|
||||
5958-dirty
|
||||
|
@ -221,24 +221,23 @@ class PylotParameter(object):
|
||||
# for key, value in self.iteritems():
|
||||
# lines.append('{key}\t{value}\n'.format(key=key, value=value))
|
||||
# fid_out.writelines(lines)
|
||||
|
||||
header = ('%This is a parameter input file for PyLoT/autoPyLoT.\n'+
|
||||
'%All main and special settings regarding data handling\n'+
|
||||
'%and picking are to be set here!\n'+
|
||||
'%Parameters are optimized for local data sets!\n')
|
||||
seperator = '%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n'
|
||||
'%Parameters are optimized for %{} data sets!\n'.format(self.get_main_para_names()['pick'][0]))
|
||||
separator = '%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n'
|
||||
|
||||
fid_out.write(header)
|
||||
self.write_section(fid_out, self.get_main_para_names()['dirs'],
|
||||
'main settings', seperator)
|
||||
'main settings', separator)
|
||||
self.write_section(fid_out, self.get_main_para_names()['nlloc'],
|
||||
'NLLoc settings', seperator)
|
||||
'NLLoc settings', separator)
|
||||
self.write_section(fid_out, self.get_main_para_names()['smoment'],
|
||||
'parameters for seismic moment estimation', seperator)
|
||||
'parameters for seismic moment estimation', separator)
|
||||
self.write_section(fid_out, self.get_main_para_names()['localmag'],
|
||||
'settings local magnitude', seperator)
|
||||
'settings local magnitude', separator)
|
||||
self.write_section(fid_out, self.get_main_para_names()['pick'],
|
||||
'common settings picker', seperator)
|
||||
'common settings picker', separator)
|
||||
fid_out.write(('#special settings for calculating CF#\n'+
|
||||
'%!!Edit the following only if you know what you are doing!!%\n'))
|
||||
self.write_section(fid_out, self.get_special_para_names()['z'],
|
||||
@ -250,9 +249,9 @@ class PylotParameter(object):
|
||||
self.write_section(fid_out, self.get_special_para_names()['quality'],
|
||||
'quality assessment', None)
|
||||
|
||||
def write_section(self, fid, names, title, seperator):
|
||||
if seperator:
|
||||
fid.write(seperator)
|
||||
def write_section(self, fid, names, title, separator):
|
||||
if separator:
|
||||
fid.write(separator)
|
||||
fid.write('#{}#\n'.format(title))
|
||||
l_val = 50
|
||||
l_name = 15
|
||||
|
Loading…
Reference in New Issue
Block a user