You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

353 lines
20 KiB
HTML

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html>
<html >
<head>
<meta charset="utf-8" />
<title>Play back archived waveforms &#8212; SeisComP Release documentation</title>
<link rel="stylesheet" href="../../_static/pygments.css" type="text/css" />
<link rel="stylesheet" href="../../_static/seiscomp.css" type="text/css" />
<link rel="stylesheet" type="text/css" href="../../_static/graphviz.css" />
<script type="text/javascript" src="../../_static/seiscomp.js"></script>
<script type="text/javascript" id="documentation_options" data-url_root="../../" src="../../_static/documentation_options.js"></script>
<script src="../../_static/jquery.js"></script>
<script src="../../_static/underscore.js"></script>
<script src="../../_static/doctools.js"></script>
<script src="../../_static/language_data.js"></script>
<link rel="shortcut icon" href="../../_static/favicon.ico"/>
<link rel="index" title="Index" href="../../genindex.html" />
<link rel="search" title="Search" href="../../search.html" />
<link rel="next" title="Help! Im stuck! Now what?" href="help.html" />
<link rel="prev" title="Enable local FDSNWS server" href="servefdsnws.html" />
</head>
<body>
<div class="header">
<div class="container">
<div class="brand">
<img class="logo" src="../../_static/brands/seiscomp/text/white.svg"/>
<!-- span class="title">SeisComP Release</span -->
<span class="version">5.3.0</span>
</div>
</div>
</div>
<div class="nav">
<div class="container">
<div class="content"><a class="pull-right" id="sidebar-toggle">TOC</a>
<div class="related" role="navigation" aria-label="related navigation">
<ul>
<li class="right">
<a href="../../genindex.html" title="General Index"
accesskey="I">
index
</a>
</li>
<li class="right">
<a href="help.html" title="Help! Im stuck! Now what?"
accesskey="N">
next
</a>
</li>
<li class="right">
<a href="servefdsnws.html" title="Enable local FDSNWS server"
accesskey="P">
previous
</a>
</li>
<li class="nav-item nav-item-0">
<a href="../../index.html">Home</a>
</li>
<li class="nav-item nav-item-1">
<a href="../tutorials.html" accesskey="U">Tutorials</a>
</li>
</ul>
</div>
</div>
</div>
</div>
<div class="container">
<div class="fitted content" id="anchors-container">
<div class="body" role="main">
<div class="section" id="play-back-archived-waveforms">
<span id="tutorials-waveformplayback"></span><h1>Play back archived waveforms<a class="headerlink" href="#play-back-archived-waveforms" title="Permalink to this headline"></a></h1>
<p>Aims:</p>
<ul class="simple">
<li><p>Use previously recorded waveform files to re-run the analysis
of an old event using SeisComP. This is known as a <em>waveform playback</em>.</p></li>
<li><p>Insert results into your current SeisComP database for later processing.</p></li>
<li><p>Review the results from playbacks.</p></li>
</ul>
<p>Pre-requisites for this tutorial:</p>
<ul class="simple">
<li><p>Have SeisComP installed and configured</p></li>
<li><p>Have access to <a class="reference internal" href="../glossary.html#term-miniseed"><span class="xref std std-term">miniSEED</span></a> waveforms</p></li>
</ul>
<p>Afterwards/Results/Outcomes:</p>
<ul class="simple">
<li><p>The results from the playback are in your SeisComP system, e.g. <a class="reference internal" href="../glossary.html#term-pick"><span class="xref std std-term">picks</span></a>,
<a class="reference internal" href="../glossary.html#term-origin"><span class="xref std std-term">origins</span></a>, <a class="reference internal" href="../glossary.html#term-amplitude"><span class="xref std std-term">amplitudes</span></a>, <a class="reference internal" href="../glossary.html#term-event"><span class="xref std std-term">events</span></a></p></li>
</ul>
<p>Time range estimate:</p>
<ul class="simple">
<li><p>60 minutes</p></li>
</ul>
<p>Related tutorial(s):</p>
<ul class="simple">
<li><p>Tutorial on <a class="reference internal" href="help.html#tutorials-help"><span class="std std-ref">getting help</span></a></p></li>
</ul>
<hr class="docutils" />
<p>Playbacks are an important way of testing module and whole-system configurations,
operator trainings, system demonstrations and validations and tuning of the SeisComP modules
used for detecting and locating events, e.g. involving</p>
<ul class="simple">
<li><p><a class="reference internal" href="../../apps/seedlink.html#seedlink"><span class="std std-ref">seedlink</span></a></p></li>
<li><p><a class="reference internal" href="../../apps/slarchive.html#slarchive"><span class="std std-ref">slarchive</span></a></p></li>
<li><p><a class="reference internal" href="../../apps/scautopick.html#scautopick"><span class="std std-ref">scautopick</span></a></p></li>
<li><p><a class="reference internal" href="../../apps/scautoloc.html#scautoloc"><span class="std std-ref">scautoloc</span></a></p></li>
<li><p><a class="reference internal" href="../../apps/scamp.html#scamp"><span class="std std-ref">scamp</span></a></p></li>
<li><p><a class="reference internal" href="../../apps/scmag.html#scmag"><span class="std std-ref">scmag</span></a></p></li>
<li><p><a class="reference internal" href="../../apps/scevent.html#scevent"><span class="std std-ref">scevent</span></a></p></li>
<li><p>others.</p></li>
</ul>
<p>Playbacks rely on miniSEED data which are obtained from the <a class="reference internal" href="../glossary.html#term-sds"><span class="xref std std-term">SDS</span></a> archive or
other sources. The miniSEED data records in the data files must be sorted by end time!</p>
<p>There are two types of playbacks:</p>
<ul class="simple">
<li><p><a class="reference internal" href="#tutorials-rtplayback"><span class="std std-ref">Real-time playbacks</span></a>.</p></li>
<li><p><a class="reference internal" href="#tutorials-nonrtplayback"><span class="std std-ref">Non-real-time playbacks</span></a>.</p></li>
</ul>
<div class="section" id="data-preparation">
<h2>Data preparation<a class="headerlink" href="#data-preparation" title="Permalink to this headline"></a></h2>
<p>First extract the data. Make sure the miniSEED records are sorted by end time.
The data extraction depends on the data source.</p>
<p>Examples:</p>
<ul>
<li><p><strong>SDS archive:</strong> Extract the data from your own SDS archive using <a class="reference internal" href="../../apps/scart.html#scart"><span class="std std-ref">scart</span></a>
and save it in a new miniSEED file <code class="file docutils literal notranslate"><span class="pre">[your</span> <span class="pre">miniSEED</span> <span class="pre">file]</span></code>, sorted by
end time of the records.</p>
<p>Examples:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scart -dsE -l <span class="o">[</span>list file<span class="o">]</span> <span class="nv">$SEISCOMP_ROOT</span>/var/lib/archive &gt; <span class="o">[</span>your miniSEED file<span class="o">]</span>
</pre></div>
</div>
</li>
<li><p><strong>FDSNWS:</strong> Get the miniSEED data from an external FDSNWS server. The obtained
data are initially sorted by station and must therefore be sorted by end time
using <a class="reference internal" href="../../apps/scmssort.html#scmssort"><span class="std std-ref">scmssort</span></a>. Use the resulting file <code class="file docutils literal notranslate"><span class="pre">[your</span> <span class="pre">miniSEED</span> <span class="pre">file]</span></code>
for your playback.</p>
<p>Example for one hour of data from the GE network from
<a class="reference external" href="https://geofon.gfz-potsdam.de/waveform/webservices/fdsnws.php">FDSNWS at GEOFON</a>:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>wget -O data.mseed <span class="s2">&quot;http://geofon.gfz-potsdam.de/fdsnws/dataselect/1/query?net=GE&amp;cha=BH*&amp;starttime=2021-04-01T06:00:00Z&amp;endtime=2021-04-01T07:00:00Z&quot;</span>
scmssort -u -E data.mseed &gt; <span class="o">[</span>your miniSEED file<span class="o">]</span>
</pre></div>
</div>
</li>
<li><p><strong>CAPS server:</strong> Extract the data from gempas CAPS server <span id="id1">[<a class="reference internal" href="../references.html#id82" title="CAPS. gempa module. URL: https://docs.gempa.de/caps/current/index.html.">3</a>]</span>
using <span id="id2"><em>capstool</em> [<a class="reference internal" href="../references.html#id85" title="capstool. gempa plugin. URL: https://docs.gempa.de/caps/current/apps/capstool.html.">25</a>]</span>:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>capstool -H <span class="o">[</span>host<span class="o">]</span>:<span class="o">[</span>port<span class="o">]</span> <span class="o">[</span>request file<span class="o">]</span> &gt; data.mseed
</pre></div>
</div>
<p>or <a class="reference internal" href="../../apps/scart.html#scart"><span class="std std-ref">scart</span></a> with the <em>caps</em> <a class="reference internal" href="../glossary.html#term-recordstream"><span class="xref std std-term">recordstream</span></a>:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scart -I caps://<span class="o">[</span>host<span class="o">]</span>:<span class="o">[</span>port<span class="o">]</span> -l <span class="o">[</span>list file<span class="o">]</span> --stdout &gt; data.mseed
</pre></div>
</div>
<p>Eventually, sort the downloaded data by end time with <a class="reference internal" href="../../apps/scmssort.html#scmssort"><span class="std std-ref">scmssort</span></a> creating
a new file, <code class="file docutils literal notranslate"><span class="pre">[your</span> <span class="pre">miniSEED</span> <span class="pre">file]</span></code>:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scmssort -u -E data.mseed &gt; <span class="o">[</span>your miniSEED file<span class="o">]</span>
</pre></div>
</div>
</li>
</ul>
<p>Use the resulting file <code class="file docutils literal notranslate"><span class="pre">[your</span> <span class="pre">miniSEED</span> <span class="pre">file]</span></code> for your playback.</p>
</div>
<div class="section" id="playbacks">
<h2>Playbacks<a class="headerlink" href="#playbacks" title="Permalink to this headline"></a></h2>
<div class="section" id="real-time-playbacks">
<span id="tutorials-rtplayback"></span><h3>Real-time playbacks<a class="headerlink" href="#real-time-playbacks" title="Permalink to this headline"></a></h3>
<p>In a real-time playback data are injected into the seedlink buffer from a file
using the command-line tool <a class="reference internal" href="../../apps/msrtsimul.html#msrtsimul"><span class="std std-ref">msrtsimul</span></a>. Therefore, seedlink requires a configuration.</p>
<ol class="arabic">
<li><p>Prepare <a class="reference internal" href="../../apps/seedlink.html#seedlink"><span class="std std-ref">seedlink</span></a> to except data from msrtsimul:</p>
<ul>
<li><p>In the <a class="reference internal" href="../concepts/configuration.html#concepts-configuration"><span class="std std-ref">module configuration</span></a>
of seedlink set</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span><span class="nv">msrtsimul</span> <span class="o">=</span> <span class="nb">true</span>
</pre></div>
</div>
</li>
<li><p>Save the configuration, update the configuration and restart seedlink:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>seiscomp update-config
seiscomp restart seedlink
</pre></div>
</div>
<p>Open :scrttv: to verify the success of this re-configuration. No new data must arrive.</p>
</li>
</ul>
</li>
<li><p>Restart all automatic data processing modules you wish to involve. Additionally start
<a class="reference internal" href="../../apps/slarchive.html#slarchive"><span class="std std-ref">slarchive</span></a> to archive the miniSEED data in the SDS archive for post-processing.</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>seiscomp restart scmaster scautopick scautoloc scamp scmag scevent slarchive
</pre></div>
</div>
</li>
<li><p>Start all desired <a class="reference internal" href="../glossary.html#term-gui"><span class="xref std std-term">GUI</span></a> modules to observe the data acquisition and processing
and the event results, e.g.:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scrttv <span class="p">&amp;</span> scmv <span class="p">&amp;</span> scesv <span class="p">&amp;</span> scolv
</pre></div>
</div>
</li>
<li><p>Start the playback using msrtsimul:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>msrtsimul -v <span class="o">[</span>your miniSEED file<span class="o">]</span>
</pre></div>
</div>
<p>This will play back the data as if they where perfectly recorded and received now.
To preserve the time of the records use <strong class="program">msrtsimul</strong> with the historic
mode:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>msrtsimul -v -m historic <span class="o">[</span>your miniSEED file<span class="o">]</span>
</pre></div>
</div>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Using <strong class="program">msrtsimul</strong> with the historic mode requires to reset the
seedlink buffer and the buffer of other processing modules by removing
the buffer files and restarting the modules. This mode may
therefore be exclusively used by experienced users.</p>
</div>
</li>
</ol>
<p>Revert the seedlink configuration after the playback to return to the original real-time
data acquisition.</p>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>Be careful with executing real-time playbacks on production SeisComP systems:</p>
<ul class="simple">
<li><p>You potentially disrupt the real-time data acquisition</p></li>
<li><p>You potentially add data at wrong times to seedlink and your SDS waveform archive</p></li>
<li><p>You modify the history of the created events</p></li>
<li><p>You potentially add events at wrong origin times to your database.</p></li>
</ul>
<p>Better use separate test systems for real-time playbacks.</p>
</div>
</div>
<div class="section" id="non-real-time-playbacks">
<span id="tutorials-nonrtplayback"></span><h3>Non-real-time playbacks<a class="headerlink" href="#non-real-time-playbacks" title="Permalink to this headline"></a></h3>
<p>In non-real-time playbacks, also referred to as offline playbacks, data are processed
by each module as fast as possible. The results can be communicated by</p>
<ul class="simple">
<li><p>Messages: message-based playback</p></li>
<li><p>XML files in <a class="reference internal" href="../glossary.html#term-scml"><span class="xref std std-term">SCML</span></a> format: XML playback. They require the processing
modules to provide the <em>- -ep</em> option.</p></li>
</ul>
<div class="admonition warning">
<p class="admonition-title">Warning</p>
<p>In non-real-time playbacks scheduling and the creation history are not representative of
real-time situations.</p>
</div>
</div>
</div>
<div class="section" id="reviewing-results">
<h2>Reviewing results<a class="headerlink" href="#reviewing-results" title="Permalink to this headline"></a></h2>
<p>Use <a class="reference internal" href="../../apps/scolv.html#scolv"><span class="std std-ref">scolv</span></a> or other <a class="reference internal" href="../glossary.html#term-gui"><span class="xref std std-term">GUIs</span></a> to review the results:</p>
<ul>
<li><p>Event parameters are in the default database. Configure <a class="reference internal" href="../concepts/recordstream.html#concepts-recordstream"><span class="std std-ref">RecordStream</span></a>
if the waveforms are in the seedlink or in the <a class="reference internal" href="../glossary.html#term-sds"><span class="xref std std-term">SDS</span></a> archive:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scolv -d mysql://sysop:sysop@localhost/seiscomp
</pre></div>
</div>
</li>
<li><p>Event parameters are in the default database but the waveforms are read from the miniSEED file:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scolv -d mysql://sysop:sysop@localhost/seiscomp -I file://<span class="o">[</span>your file<span class="o">]</span>
</pre></div>
</div>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Reading from the original file will only work if the actual times of the data
are preserved during the playback. This is <strong>not</strong> the case when starting
<strong class="program">msrtsimul</strong> without the historic mode.</p>
</div>
</li>
<li><p>Event parameters are available in one XML file and the waveforms are read from the miniSEED file:</p>
<div class="highlight-sh notranslate"><div class="highlight"><pre><span></span>scolv --offline -d mysql://sysop:sysop@localhost/seiscomp -I file://<span class="o">[</span>your miniSEED file<span class="o">]</span>
</pre></div>
</div>
<p>To open the XML file click on the <em>File</em> menu of scolv. When results are available in several
XML files, the files can be merged beforehand using <a class="reference internal" href="../../apps/scxmlmerge.html#scxmlmerge"><span class="std std-ref">scxmlmerge</span></a>.</p>
</li>
</ul>
<div class="admonition note">
<p class="admonition-title">Note</p>
<p>Adjust the arguments to match your configuration. Use your own values for arguments enclosed by
brackets, e.g. [your file]</p>
</div>
</div>
</div>
<div id="anchors-bottom"></div>
</div>
<div class="sidebar" role="navigation" aria-label="main navigation">
<div id="anchors-top"></div>
<div id="anchors" class="content">
<div id="searchbox" style="display: none" role="search">
<h3 id="searchlabel">Quick search</h3>
<div class="searchformwrapper">
<form class="search" action="../../search.html" method="get">
<input type="text" name="q" aria-labelledby="searchlabel" />
<input type="submit" value="Go" />
</form>
</div>
</div>
<script>$('#searchbox').show(0);</script>
<h3><a href="../../index.html">Table of Contents</a></h3>
<ul>
<li><a class="reference internal" href="#">Play back archived waveforms</a><ul>
<li><a class="reference internal" href="#data-preparation">Data preparation</a></li>
<li><a class="reference internal" href="#playbacks">Playbacks</a><ul>
<li><a class="reference internal" href="#real-time-playbacks">Real-time playbacks</a></li>
<li><a class="reference internal" href="#non-real-time-playbacks">Non-real-time playbacks</a></li>
</ul>
</li>
<li><a class="reference internal" href="#reviewing-results">Reviewing results</a></li>
</ul>
</li>
</ul>
<h4>Previous topic</h4>
<p class="topless"><a href="servefdsnws.html"
title="previous chapter">Enable local FDSNWS server</a></p>
<h4>Next topic</h4>
<p class="topless"><a href="help.html"
title="next chapter">Help! Im stuck! Now what?</a></p>
<div role="note" aria-label="source link">
<h3>This Page</h3>
<ul class="this-page-menu">
<li><a href="../../_sources/base/tutorials/waveformplayback.rst.txt"
rel="nofollow">Show Source</a></li>
</ul>
</div>
</div>
</div>
</div>
</div>
<div class="footer">
<div class="container">
<div class="horizontal layout content">
<a class="fade-in" href="https://www.gempa.de" target="_blank">
<img class="brand" src="../../_static/brands/gempa.svg"/>
</a>
<div class="stretched align-center fitted content">
<div>
Version <b>5.3.0</b> Release
</div>
<div class="copyright">
Copyright &copy; gempa GmbH, GFZ Potsdam.
</div>
</div>
<a class="fade-in" href="https://www.gfz-potsdam.de" target="_blank">
<img class="brand" src="../../_static/brands/gfz.svg"/>
</a>
</div>
</div>
</div>
</body>
</html>