Skip to content
Merged

V021 #48

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
c592a27
initializing v0.2.1
paudetseis May 13, 2025
9b9d7f7
toward SDS client
paudetseis May 13, 2025
dc1e99d
local SDS client and station XML to remove responses
paudetseis May 14, 2025
e1cd009
better handling of inventory in scripts and code cleanup
paudetseis May 14, 2025
ad6e3e5
updated helper page for atacr_download_*
paudetseis May 14, 2025
437fe9e
updated scripts to handle missing component exceptions
paudetseis May 14, 2025
2178e75
add SDS documentation in html docs
paudetseis May 15, 2025
0b62b7f
add ascii art and cleanup
paudetseis May 15, 2025
4f7c5ce
again - ascii art and cleanup
paudetseis May 15, 2025
ffc36e5
major refactoring of download_* - removed -C option
paudetseis May 15, 2025
ce3f422
fixed typos in script description
paudetseis May 15, 2025
83a39f8
updated docs for atacr
paudetseis May 15, 2025
686a335
updated docs for comply
paudetseis May 15, 2025
7598a77
fixed headings in local data docs
paudetseis May 15, 2025
44b86b4
do not deploy documentation yet
paudetseis May 15, 2025
923209f
remove test and coverage badges
paudetseis May 15, 2025
0b53a18
typo indownload script description for --local-data
paudetseis May 15, 2025
f400828
added options for tilt frequencies and cleaned up tilt calculation
paudetseis May 20, 2025
8737bd1
fixed script docs for atacr
paudetseis May 20, 2025
a4bbba4
added ascii art to scripts
paudetseis May 20, 2025
3f70d4b
view code source in docs API
paudetseis May 20, 2025
83a54dc
build docs for v0.2.1 during deployment
paudetseis May 20, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ can be used through command-line scripts.

[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.4281480.svg)](https://doi.org/10.5281/zenodo.4281480)
[![build](https://github.com/nfsi-canada/OBStools/workflows/Build/badge.svg)](https://github.com/nfsi-canada/OBStools/actions)
[![codecov](https://codecov.io/gh/nfsi-canada/OBStools/branch/master/graph/badge.svg)](https://codecov.io/gh/nfsi-canada/OBStools)
<!-- [![codecov](https://codecov.io/gh/nfsi-canada/OBStools/branch/master/graph/badge.svg)](https://codecov.io/gh/nfsi-canada/OBStools) -->

Installation, API documentation, scripts and tutorials are described at https://nfsi-canada.github.io/OBStools/

Expand Down
524 changes: 326 additions & 198 deletions docs/atacr.rst

Large diffs are not rendered by default.

22 changes: 22 additions & 0 deletions docs/comply.rst
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,17 @@ Usage
.. code-block::

$ comply_calculate -h

#################################################################################
# _ _ _ _ #
# ___ ___ _ __ ___ _ __ | |_ _ ___ __ _| | ___ _ _| | __ _| |_ ___ #
# / __/ _ \| '_ ` _ \| '_ \| | | | | / __/ _` | |/ __| | | | |/ _` | __/ _ \ #
# | (_| (_) | | | | | | |_) | | |_| | | (_| (_| | | (__| |_| | | (_| | || __/ #
# \___\___/|_| |_| |_| .__/|_|\__, |___\___\__,_|_|\___|\__,_|_|\__,_|\__\___| #
# |_| |___/_____| #
# #
#################################################################################

usage: comply_calculate [options] <Station Database>

Script used to calculate compliance functions between various components. The noise data can be those obtained
Expand Down Expand Up @@ -189,6 +200,17 @@ In this case we do not need to specify any option and type in a terminal:

$ comply_calculate M08A.pkl

#################################################################################
# _ _ _ _ #
# ___ ___ _ __ ___ _ __ | |_ _ ___ __ _| | ___ _ _| | __ _| |_ ___ #
# / __/ _ \| '_ ` _ \| '_ \| | | | | / __/ _` | |/ __| | | | |/ _` | __/ _ \ #
# | (_| (_) | | | | | | |_) | | |_| | | (_| (_| | | (__| |_| | | (_| | || __/ #
# \___\___/|_| |_| |_| .__/|_|\__, |___\___\__,_|_|\___|\__,_|_|\__,_|\__\___| #
# |_| |___/_____| #
# #
#################################################################################


Path to COMPL_STA/7D.M08A doesn't exist - creating it


Expand Down
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
# Add any Sphinx extension module names here, as strings. They can be
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.napoleon']
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.napoleon', 'sphinx.ext.viewcode']

autodoc_member_order = 'bysource'

Expand Down
2 changes: 0 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ can be used through command-line scripts.
:target: https://doi.org/10.5281/zenodo.4281480
.. image:: https://github.com/nfsi-canada/OBStools/workflows/Build/badge.svg
:target: https://github.com/nfsi-canada/OBStools/actions
.. image:: https://codecov.io/gh/nfsi-canada/OBStools/branch/master/graph/badge.svg
:target: https://codecov.io/gh/nfsi-canada/OBStools

.. toctree::
:maxdepth: 1
Expand Down
2 changes: 1 addition & 1 deletion meson.build
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
project('rfpy', 'c',
version : '0.2.0',
version : '0.2.1',
license: 'MIT',
meson_version: '>=0.64.0',
)
Expand Down
85 changes: 72 additions & 13 deletions obstools/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
Licence
-------

Copyright 2019 Pascal Audet & Helen Janiszewski
Copyright 2019 Pascal Audet

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand All @@ -50,19 +50,14 @@
Dependencies
++++++++++++

The current version has been tested using **Python 3.10** \
The following package is required before install ``obstools``:

- `stdb <https://github.com/paudetseis/StDb>`_

Other required packages (e.g., ``obspy``)
will be automatically installed by ``stdb``.
- `stdb <https://github.com/schaefferaj/StDb>`_
- `obspy <https://github.com/obspy/obspy>`_

Conda environment
+++++++++++++++++

We recommend creating a custom ``conda`` environment
where ``OBStools`` can be installed along with some of its dependencies.
where ``OBStools`` can be installed along with its dependencies.

.. sourcecode:: bash

Expand All @@ -78,14 +73,14 @@

.. sourcecode:: bash

pip install stdb
pip install git+https://github.com/schaefferaj/stdb

Installing development branch on GitHub
+++++++++++++++++++++++++++++++++++++++

.. sourcecode:: bash

pip install obstools@git+https://github.com/nfsi-canada/obstools
pip install git+https://github.com/nfsi-canada/obstools

Installing from source
++++++++++++++++++++++
Expand All @@ -103,11 +98,75 @@

pip install .

Using local data
----------------

The various scripts packaged with ``OrientPy`` use FDSN web services
through and ``ObsPy`` `Client` to load waveform data. For waveform
data locally stored on your hard drive, the scripts can use a `Client`
that reads a `SeisComP Data Structure
<https://docs.obspy.org/packages/autogen/obspy.clients.filesystem.sds.html>`_
archive containing SAC or miniSEED waveform data. Check out the scripts
``bng_calc`` and ``dl_calc`` below and the argument ``--local-data`` and
``--dtype`` for more details.

Station Metadata
++++++++++++++++

If you have data stored locally on your drive, it is likely you also
have a station `XML <https://www.fdsn.org/xml/station/>`_ file
containing the metadata. The corresponding ObsPy documentation is
`here <https://docs.obspy.org/packages/obspy.core.inventory.html>`_.

To convert the station `XML` file to an input that can be read by
``OrientPy``, you run the command ``gen_stdb station.xml`` (only
available on StDb version 0.2.7), which will create the file
``station.pkl``. If you don't have a station `XML` file but you have
a dataless SEED file, you can convert it first to `XML` using `this
tools <https://seiscode.iris.washington.edu/projects/stationxml-converter>`_.

Waveform Data
+++++++++++++

The SDS folder containing the waveform data has the structure:

.. code-block:: python

archive
+ year
+ network code
+ station code
+ channel code + type
+ one file per day and location, e.g. NET.STA.LOC.CHAN.TYPE.YEAR.DOY


For example:

.. code-block:: python

SDS/
2014/
YH/
LOBS3/
HH1.D/
YH.LOBS3..CH1.D.2014.332
...


Note, the filename does not include the extension (`.MSEED` or `.SAC`),
and the characters `.D` (for type Data) that appear in both the
channel code and the filename. Note also the two dots (`..`). If
there is a location code, it should appear between those dots (e.g.,
for a location code `10`, the corresponding filename should be
`YH.LOBS3.10.HH1.D.2014.332`). There is no location code for the
YH.LOBS3 data, and this field is simply absent from the filenames.
Finally, the day-of-year (DOY) field must be zero-padded to be exactly
3 characters.
"""

__version__ = '0.2.0'
__version__ = '0.2.1'

__author__ = 'Pascal Audet & Helen Janiszewski'
__author__ = 'Pascal Audet'

from . import atacr
from . import comply
Loading
Loading