-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 139dbb2
Showing
2,352 changed files
with
603,678 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Sphinx build info version 1 | ||
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. | ||
config: ea3c5563822b8d85146d5c7dfe238e3b | ||
tags: 645f666f9bcd5a90fca523b33c5a78b7 |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
# Sphinx build info version 1 | ||
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. | ||
config: c32805b6176e45d1c7507ad5bcb063f7 | ||
tags: 645f666f9bcd5a90fca523b33c5a78b7 |
Empty file.
290 changes: 290 additions & 0 deletions
290
1.3.5/_downloads/3dc6b21e7317f0adfc489d8e356fa07b/PRF_Process.ipynb
Large diffs are not rendered by default.
Oops, something went wrong.
Binary file not shown.
285 changes: 285 additions & 0 deletions
285
1.3.5/_downloads/90954f79a659494de3c55def811f9550/ps-depth.ipynb
Large diffs are not rendered by default.
Oops, something went wrong.
214 changes: 214 additions & 0 deletions
214
1.3.5/_downloads/c91ad42c82dba65d2f3b80bd36a4e041/rf-from-ws.ipynb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,214 @@ | ||
{ | ||
"cells": [ | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"# Fetch seismic data from web-service and calculate RF automatically" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"After Seispy v1.3.0, user can calculate RFs with specified network and station which can be fetched from [FDSN web service](https://www.fdsn.org/webservices/). This section shows a example to calculate PRFs with fetching station and event information from web service.\n", | ||
"\n", | ||
"```{note}\n", | ||
"This notebook can be downloaded as **{nb-download}`rf-from-ws.ipynb`**\n", | ||
"```" | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": 1, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"import os\n", | ||
"from seispy.rf import RF\n", | ||
"from seispy.io import Query\n", | ||
"from obspy import UTCDateTime\n", | ||
"#import pytest\n", | ||
"import glob" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"## Get information of stations\n", | ||
"Before running this script, we can visually search stations from portal of web-service, such as [GFZ webdc3](http://eida.gfz-potsdam.de/webdc3/) or [IRIS GMap](https://ds.iris.edu/gmap/). The URL of FDSN web service or shortcut names can be found in [obspy.client.fdsn](https://docs.obspy.org/packages/obspy.clients.fdsn.html). The network name, station name, positions, date range, etc. can be found at these services. Now let's fetch station information using these conditions. \n", | ||
" \n", | ||
"The following example illustrates how to request the station information from the Global Seismograph Network(\"`IU`\")." | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"query = Query(server='IRIS') ## Server is the URL of FDSN web service or a shortcut name in the obspy.client.fdsn.\n", | ||
"query.get_stations(network='IU', station='U*', level='channel')\n", | ||
"#print(query.stations)" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"## Fetch data and calculate RF with different gauss factors\n", | ||
" \n", | ||
" The following example illustrates how to request the `'BH?'` channels, `'00'` location of station Ulaanbaatar (`'ULN'`) of the Global Seismograph Network(`'IU'`) for events between \"2013-08-01\" and \"2013-10-31\" (UTC), calculate the RF with 4 gauss factors simultaneously, and save the raw seismic data and RFs. \n", | ||
" \n", | ||
"\n", | ||
"<h3 id=\"rfpara\">Set the parameters for matching catalog and estimating RF</h3> \n", | ||
" \n", | ||
" All parameters for matching catalog and estimating RF are in the [`RF.para`](#rfpara). These parameters can be set according to user needs. \n", | ||
" Online catalog (`'cata_server'`) is fetched from the FDSN web service client for ObsPy ([obspy.client.fdsn](https://docs.obspy.org/packages/obspy.clients.fdsn.html)). " | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"rf = RF()\n", | ||
"rf.para.data_server = 'IRIS'\n", | ||
"rf.para.cata_server = 'IRIS'\n", | ||
"rf.para.stainfo.network = 'IU'\n", | ||
"rf.para.stainfo.station = 'ULN'\n", | ||
"rf.para.stainfo.channel = 'BH?'\n", | ||
"rf.para.stainfo.location = '00'\n", | ||
"rf.para.datapath = './Data/{}.{}'.format(rf.para.stainfo.network, rf.para.stainfo.station)\n", | ||
"rf.para.use_remote_data = True\n", | ||
"rf.para.ref_comp ='BHZ'\n", | ||
"rf.para.phase = 'P'\n", | ||
"rf.para.noisegate = 1\n", | ||
"rf.para.magmin = 5.8\n", | ||
"rf.para.gauss = [0.5, 1.0, 1.5, 2.0] ##RF with different Gauss factor will be calculated simultaneously.\n", | ||
"rf.para.rmsgate = 0.4\n", | ||
"rf.para.freqmin = 0.05\n", | ||
"rf.para.freqmax = 2.0\n", | ||
"rf.para.comp = 'RTZ'\n", | ||
"rf.para.date_begin = UTCDateTime('20130801')\n", | ||
"rf.para.date_end = UTCDateTime('20131031')\n" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"### load station information and search events \n", | ||
" - Fetch the station information from the data server ([`data_server`](#rfpara)) \n", | ||
" - Search the event information from the catalog server ([`cata_server`](#rfpara)). \n", | ||
" Here, we use the `'IRIS'` client. Available catalogs in the IRIS are listed in [IRIS DMC FDSNMS event Web Server](https://service.iris.edu/fdsnws/event/1/catalogs), such as `'ISC'`, `'NEIC PDE'` and `'GCMT'`." | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"rf.load_stainfo()\n", | ||
"rf.search_eq(catalog='NEIC PDE')\n", | ||
"#print(rf.eq_lst) ##The matched event lists are listed." | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"### Match catalog and fetch seismic data \n", | ||
" Match events and fetch seismic data with the parameters such as the data type (`'SAC'`) and dateformat `'%Y.%j.%H.%M.%S'` set in the [`RF.para`](#rfpara).\n", | ||
" " | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"rf.match_eq() " | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"### Calculate RF \n", | ||
" - Remove the linear trend (`detrend`) and apply a bandpass filter (`filter`) to the data. The frequencies for the bandpass filter are set in the [`RF.para`](#rfpara) ([`'para.freqmin'`](#rfpara) and [`'para.freqmin'`](#rfpara)); \n", | ||
" - Mark phase arrivals with the server of Taup and the velocity mode ([`'para.velmod'`](#rfpara)) can be set in the [`RF.para`](#rfpara); \n", | ||
" - Rotate the seismic data to `'RTZ'` or`'LQT'` and delete the events with the SNR lower than the [`'para.noisegate'`](#rfpara); \n", | ||
" - Save the raw SAC data download from the web server; \n", | ||
" Trim the RF bewteen the times of [`para.time_before`](#rfpara) and [`para.time_after`](#rfpara); \n", | ||
" - Do deconvolution to obtain the RFs with different gauss factors. Deconvolution methods (`para.decon_method`) of Time-domain iterative deconvolution (`'iter'`) and frequency-domian water-level deconvolution (`'water'`) are available. " | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"rf.detrend()\n", | ||
"rf.filter()\n", | ||
"rf.cal_phase()\n", | ||
"rf.rotate()\n", | ||
"rf.drop_eq_snr()\n", | ||
"rf.save_raw_data()\n", | ||
"rf.trim()\n", | ||
"rf.deconv()" | ||
] | ||
}, | ||
{ | ||
"cell_type": "markdown", | ||
"metadata": {}, | ||
"source": [ | ||
"### Save the RFs \n", | ||
" Save the RFs calculating with different Gauss factors. " | ||
] | ||
}, | ||
{ | ||
"cell_type": "code", | ||
"execution_count": null, | ||
"metadata": {}, | ||
"outputs": [], | ||
"source": [ | ||
"for ff in rf.para.gauss:\n", | ||
" rf.para.rfpath = './RFresult/F{:.1f}/{}.{}'.format(\n", | ||
" ff, rf.para.stainfo.network, rf.para.stainfo.station)\n", | ||
" rf.saverf(ff)" | ||
] | ||
} | ||
], | ||
"metadata": { | ||
"kernelspec": { | ||
"display_name": "Python 3 (ipykernel)", | ||
"language": "python", | ||
"name": "python3" | ||
}, | ||
"language_info": { | ||
"codemirror_mode": { | ||
"name": "ipython", | ||
"version": 3 | ||
}, | ||
"file_extension": ".py", | ||
"mimetype": "text/x-python", | ||
"name": "python", | ||
"nbconvert_exporter": "python", | ||
"pygments_lexer": "ipython3", | ||
"version": "3.9.15" | ||
}, | ||
"vscode": { | ||
"interpreter": { | ||
"hash": "4e14d21dea86c260d88be34273f4e9100dbd1919caf172718af2426599760403" | ||
} | ||
} | ||
}, | ||
"nbformat": 4, | ||
"nbformat_minor": 2 | ||
} |
Binary file added
BIN
+21.8 KB
1.3.5/_images/2367344778e6232e5fb134a0e0612ab548a7b15b90ce0fed164881135a286811.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+35.5 KB
1.3.5/_images/7fe4c389d1573cc0b49296a2f6b505b53200da695375b4b52ba8625c6bee187b.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+19 KB
1.3.5/_images/94e12d0edc9486438d66a1981c9772640e42337b6f19f8e5977394974252fac3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+31 KB
1.3.5/_images/9a0b8afe271c74f8e4cff3617970799d23008399e18712e6b0d2621c675b8c07.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+103 KB
1.3.5/_images/a161a4e1278cc8724b9f0bcb4f215f4273e83535e7b9ff7e46333bee5739f62e.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+95.6 KB
1.3.5/_images/a43e0db67279271054f2bc293040bad96a4847b4ab54b619215b154791d5eefc.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added
BIN
+13.5 KB
1.3.5/_images/c73a9b1b0ae6bc31bb558fb1ac6da9db430c47afbe5f12117b6fac88b6d607dc.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.