Skip to content

Commit

Permalink
CCT 1.0.18
Browse files Browse the repository at this point in the history
Comprehensive updates to how zooming is handled in all Waveform plots to support ‘sticky’ zoom levels
Additional toggle included to allow zooming an entire group of Waveform plots to match an index plot’s zoom
Additional updates to uncertainty quantification metrics based on continuing iteration with the user community
Include a coda start offset parameter in the frequency band table to allow measurement offsets for entire frequency bands; 'CS' picks
Implementation of user adjustable start times for coda measurements on an individual waveform basis; 'UCS' picks, overrides 'CS' values, if present
Include reference features in several plots to allow comparison against known terms and measurements.
Basic tutorial and notes for new users and basic API documentation for developers now included in the help menu
Changed the way coda start is calculated to make it a two-step where we find the max vel, then fit the model, then back-prop the expected velocity into the coda start time field.
Fix for zoom issues when you go straight to measurement/site and box select without displaying any single waveform first.
Bump to TLS 1.3 since support has been backported to Java 8
Changed the map screenshot button to put the icons back onto png
Moving picks on waveforms with site measurements will re-measure the measurement and replot it in site automatically.
Dynamically update synthetic when you move UCS pick.
New top axis option for the Moment vs Energy plot + other updates related.
Fixed log_x axis resizing not being taken into acount for the station correction sd plot.
New REST endpoint to directly generate a synthetic coda envelope based on the loaded calibration.
Fixed a bug where if you had ref/val events loaded not in data set the site tab could blow up a bit.
Updates to default table values to increase the default window lengths when no tables are loaded, based on user feedback.
  • Loading branch information
justinbarno committed Jul 20, 2022
1 parent bdd28f4 commit 86bf2b7
Show file tree
Hide file tree
Showing 2,705 changed files with 914,204 additions and 21,084 deletions.
90 changes: 56 additions & 34 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,28 @@
![Livermore logo](llnl-logo.gif)

The `Coda Calibration Tool` (CCT) is a Java based application for calibrating 1D shear wave coda measurement models to observed data using a much smaller set of reference MWs calculated from other means (waveform modeling, etc.).
**Additional documentation is available at the project [GitHub pages site](https://software.llnl.gov/coda-calibration-tool/).**

---

The `Coda Calibration Tool` (CCT) is a Java based application for calibrating 1D shear wave coda measurement models to observed data using a much smaller set of reference MWs calculated from other means (waveform modeling, etc.).
<br/>These calibrated measurement models can then be used in other tools to generate coda MW measurements, source spectra, estimated stress, and other useful measurements against the rest of the events and any new data collected in the calibrated region.

> ***<sub>note</sub>*** <br/>
> The `Coda Calibration Tool` currently only does calibration; it requires data to be pre-processed for loading using other tools.
> **_<sub>note</sub>_** <br/>
> The `Coda Calibration Tool` currently only does calibration; it requires data to be pre-processed for loading using other tools.
---

***
## [Demo](#demo)

https://user-images.githubusercontent.com/10851365/179833833-8bc0eadc-abf7-49b1-a831-9555675d3aa8.mp4

<sub>Data courtesy of [Northern California Earthquake Data Center](http://ncedc.org/)</sub>

***
---

## [Structure](#structure)

CCT is split into three basic components.
CCT is split into three basic components.

A REST service that consumes Waveform objects containing stacked coda envelope segments and information about the station and event locations. This service does all the actual calculations to calibrate the model.

Expand All @@ -26,48 +32,55 @@ And a wrapper project (Standalone) that combines both into a single runnable JAR

CCT is based on [Spring 5.0](https://spring.io/); primarily Boot and Data. By default, it uses a [H2](http://www.h2database.com/html/main.html) in-memory database for storing loaded Waveforms and the resulting calibration artifacts.

***
---

## [Building](#building)
CCT uses [Apache Maven](https://maven.apache.org/) for building and dependency management.

CCT uses [Apache Maven](https://maven.apache.org/) for building and dependency management.

From the top level `coda-calibration` directory you can build the entire project using the parent pom by running:

```shell
mvn clean package
mvn clean install
```

We don't presently deploy versioned artifacts into a public repository like the [Maven Central Repository](https://maven.apache.org/repository/index.html) but we may do so in the future.
***
---

## [Running](#running)

#### **As a single runnable JAR**

```shell
java -jar coda-calibration/calibration-standalone/target/calibration-standalone-1.0.17-runnable.jar
java -jar coda-calibration/calibration-standalone/target/calibration-standalone-1.0.18-runnable.jar
```

#### **GUI alone**

```shell
java -jar coda-calibration/calibration-gui/target/calibration-gui-1.0.17-runnable.jar
java -jar coda-calibration/calibration-gui/target/calibration-gui-1.0.18-runnable.jar
```

#### **Calibration REST service alone**

```shell
java -jar coda-calibration/calibration-service/application/target/application-1.0.17-runnable.jar
java -jar coda-calibration/calibration-service/application/target/application-1.0.18-runnable.jar
```

#### A note about HTTPS

If you look at the REST service and the GUI client packages you might have noticed 'selfsigned.crt' and 'coda-truststore.jks' in the resources directory. CCT uses HTTPS by default and these are the default certificates we include for the handshake between the client and the GUI.

You can use these as-is or use your own by changing these properties using any of the [Spring external configuration](https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html) mechanisms:

* On the client:
- On the client:

```text
webclient.trustStoreName
webclient.trustStorePass
```

* On the REST service:
- On the REST service:

```text
server.ssl.key-alias
server.ssl.key-password
Expand All @@ -78,14 +91,15 @@ server.ssl.key-store-type

This additional step is recommended for deployments where the REST service is bound to a non-loopback adapter.

***
---

## [Data Formats](#data)

As of 1.0, CCT is capable of loading four basic file types

1. Stacked coda envelopes

These stacked envelopes are filtered into the same frequency ranges as those defined in the coda model parameters (3). Presently, the CCT GUI only has converters for [SAC](http://ds.iris.edu/ds/nodes/dmc/software/downloads/sac/) files and, as a result, requires the file names to follow a specific format to capture the frequency band information.
These stacked envelopes are filtered into the same frequency ranges as those defined in the coda model parameters (3). Presently, the CCT GUI only has converters for [SAC](http://ds.iris.edu/ds/nodes/dmc/software/downloads/sac/) files and, as a result, requires the file names to follow a specific format to capture the frequency band information.

```text
STATION_CHANNEL_EVENTID_LOWFREQ_HIGHFREQ_UNITS_.*.env
Expand All @@ -100,7 +114,8 @@ As of 1.0, CCT is capable of loading four basic file types
EVID MW [APPARENT_STRESS_IN_MPA|0.0]
(e.g. 999999 5.1 0.0)
```
> ***<sub>note</sub>*** <br/>

> **_<sub>note</sub>_** <br/>
> The EVID here should match the one defined in either the KEVNM or NEVID (tested in that order) fields of the SAC files being loaded so the envelope waveforms can be associated correctly during calibration.
3. Coda model parameters
Expand All @@ -110,40 +125,46 @@ As of 1.0, CCT is capable of loading four basic file types

4. Phase and frequency model parameters for distance amplitude correction curves

> ***<sub>note</sub>*** <br/>
> **_<sub>note</sub>_** <br/>
>
> While CCT supports loading MDAC2 model descriptor files, it presently only uses it for predicted source spectra.
> As a result, the two parameters of most interest for calibration purposes are Psi and Sigma. These correspond to apparent or actual stress drop of the spectra depending on their values.
> While CCT supports loading MDAC2 model descriptor files, it presently only uses it for predicted source spectra.
> As a result, the two parameters of most interest for calibration purposes are Psi and Sigma. These correspond to apparent or actual stress drop of the spectra depending on their values.
> See the [additional reading](#references) for more information.
***
---

## [Contributing](#contributing)

Contributing to CCT is easy: just send us a [pull request](https://help.github.com/articles/using-pull-requests/).
Contributing to CCT is easy: just send us a [pull request](https://help.github.com/articles/using-pull-requests/).

When you send your request, make ``develop`` the destination branch.
When you send your request, make `develop` the destination branch.

The ``develop`` branch contains the latest contributions, and ``master`` always points to the latest stable.
The `develop` branch contains the latest contributions, and `master` always points to the latest stable.

Issues, suggestions, discussion, documentation, general code cleanup, and automated tests are also all valuable ways to contribute and are more than welcome!

***
Any contributions are assumed to also be licensed for release as Apache V2.

---

## [Additional Reading](#references)

[Mayeda, K.M., A. Hofstetter, J.L. O Boyle, W.R. Walter (2003). Stable and transportable regional magnitudes based on coda-derived moment-rate spectra, Bull. Seism. Soc. Am., 93, 224-239.](http://bssa.geoscienceworld.org/content/93/1/224)

***
---

## [Versioning](#versioning)

We use [Semantic Versioning](http://semver.org/) for versioning. For the versions available, see the tags on this repository.
We use [Semantic Versioning](http://semver.org/) for versioning. For the versions available, see the tags on this repository.

---

***
## [License](#license)

The `Coda Calibration Tool` is provided under the [Apache License](LICENSE.txt).

```text
Copyright 2017 Lawrence Livermore National Laboratory
Copyright 2022 Lawrence Livermore National Laboratory
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
Expand All @@ -158,12 +179,13 @@ The `Coda Calibration Tool` is provided under the [Apache License](LICENSE.txt).
limitations under the License.
```

***
---

## [Disclaimer](#disclaimer)

```text
This work was performed under the auspices of the U.S. Department of Energy
This work was performed under the auspices of the U.S. Department of Energy
by Lawrence Livermore National Laboratory under Contract DE-AC52-07NA27344.
```

``LLNL-CODE-743439``
`LLNL-CODE-743439`
63 changes: 5 additions & 58 deletions calibration-gui/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<groupId>gov.llnl.gnem.apps.coda.calibration</groupId>
<artifactId>coda-calibration</artifactId>
<version>1.0.17</version>
<version>1.0.18</version>
</parent>

<artifactId>calibration-gui</artifactId>
Expand Down Expand Up @@ -227,69 +227,16 @@
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>${spring.boot.version}</version>
</dependency>
</dependencies>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
<goal>repackage</goal>
</goals>
<configuration>
<transformers>
<transformer implementation="org.springframework.boot.maven.PropertiesMergingResourceTransformer">
<resource>META-INF/spring.handlers</resource>
</transformer>
<transformer implementation="org.springframework.boot.maven.PropertiesMergingResourceTransformer">
<resource>META-INF/spring.factories</resource>
</transformer>
<transformer implementation="org.springframework.boot.maven.PropertiesMergingResourceTransformer">
<resource>META-INF/spring.schemas</resource>
</transformer>
<transformer implementation="org.springframework.boot.maven.PropertiesMergingResourceTransformer">
<resource>META-INF/spring.tooling</resource>
</transformer>
<transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
<manifestEntries>
<Main-Class>org.springframework.boot.loader.JarLauncher</Main-Class>
<Start-Class>gov.llnl.gnem.apps.coda.calibration.gui.GuiApplication</Start-Class>
</manifestEntries>
</transformer>
</transformers>
</configuration>
</execution>
</executions>
<configuration>
<filters>
<filter>
<artifact>*:*</artifact>
<excludes>
<exclude>**/module-info.*</exclude>
</excludes>
</filter>
<filter>
<!-- filter out signature files from signed dependencies, else repackaging fails with security ex -->
<artifact>*:*</artifact>
<excludes>
<exclude>META-INF/*.SF</exclude>
<exclude>META-INF/*.DSA</exclude>
<exclude>META-INF/*.RSA</exclude>
</excludes>
</filter>
</filters>
<shadedArtifactAttached>true</shadedArtifactAttached>
<shadedClassifierName>runnable</shadedClassifierName>
<createDependencyReducedPom>false</createDependencyReducedPom>
</configuration>
</plugin>
</plugins>
</build>
</project>
</project>
Loading

0 comments on commit 86bf2b7

Please sign in to comment.