Create new tool map_header to create a map between file paths and their array, station from list file or directory of files
Modify pforma to read this map file to add file into ph5 in the correct order
Using file_das_type dictionary to get das and data type for current processed file instead of recalling guess_instrument_type() again. This improve the performance of processing SmartSolo because guess_instrument_type() read SmartSolo's header for array and station information. (For this solution and the previous solution of SmartSolo as well.
Notice: to run map_header, users need to run the following command in ph5 conda environment: pip install -e .
To add SmartSolo to PH5 using SmartSolo you can do the following methods:
Using pforma with the SmartSolo list file which is the existing solution from #513
Using map_header to create smartsolo_map. Then use pforma with this smartsolo_map file. This way the tasks of reading file headers won't be included in pforma
There are two option to run map_header:
map_header -f smartsolo_list_file
Or
map_header -d smartsolo_directory
The latter can reduce the step of creating smartsolo_list_file but won't work if SmartSolo files are located in more than one folder.
Relevant Issues?
502
Checklist
[ ] This PR is not directly related to an existing issue (which has no PR yet).
[ ] All tests pass.
[ ] Any new or changed features have are documented.
[ ] Changes have been added to CHANGELOG.txt .
[ ] First time contributors have added your name to CONTRIBUTORS.txt .
map_header -f list_file works when SmartSolo files are in more than one directory. Is this expected behavior? (It is only the -d flag that doesn't work when files are in more than one directory?)
What does this PR do?
map_header
to create a map between file paths and their array, station from list file or directory of filesNotice: to run
map_header
, users need to run the following command in ph5 conda environment:pip install -e .
To add SmartSolo to PH5 using SmartSolo you can do the following methods:
pforma
with the SmartSolo list file which is the existing solution from #513map_header
to createsmartsolo_map
. Then usepforma
with thissmartsolo_map
file. This way the tasks of reading file headers won't be included inpforma
There are two option to run
map_header
:Or
The latter can reduce the step of creating smartsolo_list_file but won't work if SmartSolo files are located in more than one folder.
Relevant Issues?
502
Checklist
CHANGELOG.txt
.CONTRIBUTORS.txt
.