Recent Releases of sourcespec
sourcespec - Release v1.8
This long overdue release brings many improvements, new features and bugfixes gradually introduced during the last year.
Release highlights:
- New file formats for events and spectra
- New configuration options to better specifify velocity and density models
- Better support for P-wave inversion and teleseismic events
- Support for radiation pattern correction from focal mechanism
- Option for travel time-based signal window length
- More options to control the calculation of source radius and stress drop
- Improved estimation of radiated energy
- New source parameter: apparent stress
- Fix for map tiles not plotted anymore
This release requires at least Python 3.7.
Warning: the SQLite database used by this version is not compatible with
previous versions. You will need to upgrade your old database manually or using
source_spec -u DATABASE_FILE_NAME.
Check out the full Changelog
- Python
Published by github-actions[bot] almost 2 years ago
sourcespec - Release v1.7
This release improves trace processing through the use of modern routines for instrument correction, optional baseline removal, a new clipping detection algorithm and a better definition of signal and noise time windows.
A new plot is introduced, "stacked spectra" which allows to compare all the
spectra at once (and easily detect problematic stations 😉).
Also, a new command line tool, plot_sourcepars, allows making aggregate
plots of source parameters for many events (starting from the SQLite database).
New config file parameters have been added, while some have been removed.
Please run source_spec -U CONFIG_FILE_NAME to update your old config file.
As always, many bugfixes and improvements have been made in this release. Thanks to all the users who took time to write and ask questions (by mail or using the official SourceSpec [Discussions]).
Big kudos to Kris Vanneste [@krisvanneste] who helped all along the development with code review and testing and submitted pull requests on noise windows and clipping detection.
Check out the full Changelog.
- Python
Published by github-actions[bot] almost 3 years ago
sourcespec - Release v1.6
This release introduces several modifications to the config file.
You will need to upgrade your old config files manually or using
source_spec -U CONFIG_FILE_NAME.
This release requires at least Python 3.6.
A lot of effort has been devoted to improve the documentation. Please check it out on https://sourcespec.readthedocs.io/
Input/output
- QuakeML output (when using QuakeML input)
- Command line option
--run-idto provide a string identifying the current run (see pull request [#6]) - Write SourceSpec version to parfile
- Write SourceSpec version and run complete time to SQLite file
- Write author and agency info (if specified) to output files, figures and HTML report
- HTML page for misfit plots (when using grid search or importance sampling)
- Station table in HTML report is now sortable (and its header remains fixed)!
- Reduce PNG figures file size, while improving their resolution 😃
- Removed option to read event information and traces from a pickle file (rarely used)
Processing
- Support for P-wave spectral inversion (see pull request [#9])
- It is now possible to provide different vp and vs velocities, close to the source and close to the stations (see the new config options above and issue [#5])
- Possibility to choose a geometrical spreading model between
(see issue [#8]):
- rⁿ (default: n=1 – body waves)
- Boatwright et al. (2002): "r" below a cutoff distance, frequency-dependent above the cutoff distance
- Use travel time to compute quality factor from t* (and viceversa) (see issue [#5])
- Compute travel time from pick and origin time, when possible (see issue [#10])
- Warn if noise window ends after P or S arrival
Post-Inversion
- Subtract the integral of noise spectrum from the integral of signal spectrum when computing radiated energy, under the hypothesis that energy is additive and noise is stationary
Config file
- Config parameter
pazhas been removed and merged intostation_metadata - Config parameters
vpandvshave been renamed tovp_sourceandvs_source(see issue [#5]) - New, optional, config parameter
vp_stationsandvs_stations - Config parameter
pre_p_timeandpre_s_timehave been renamed tonoise_pre_timeandsignal_pre_time, respectively (see pull request [#9]) - Config parameter
rps_from_focal_mechanismrenamed torp_from_focal_mechanism(see pull request [#9]) - New config parameter:
geom_spread_model(see issue [#8]) - Config parameters
PLOT_SHOW,PLOT_SAVEandPLOT_SAVE_FORMATare now lowercase (plot_show,plot_saveandplot_save_format) - New, optional, general config parameters for specyfing author and agency information. This information is written to output files and figures, if specified
- New config parameter,
event_url, to link the event page from the HTML report - Removed
DEBUGconfig parameter - Parameters from
GENERAL PARAMETERSsection reorganized into a new section calledTRACE AND METADATA PARAMETERS - Some parameters from
INVERSION PARAMETERSmoved into a new section calledSPECTRAL MODEL PARAMETERS
Bugfixes
- Fix for not working
weightingoptions:frequencyandno_weight - Fix for negative weights occasionally generated by interpolation
- Fix bug when event coordinates are written into sqlite as binary blobs
- Python
Published by github-actions[bot] over 3 years ago
sourcespec - Release v1.5
This is a pretty big release coming after several months of work on a large dataset of more than 5000 events in Mayotte.
Please read through the changelog to discover all the improvements and new features.
You will need to update your old config files via
source_spec -U CONFIG_FILE_NAME
Note that v1.5 is no more compatible with Python 2!
- Input/output:
- Write output files into a subdirectory of OUTDIR, whose name is the event id
- Support for HYPOINVERSE-2000 output files
- Removed autodetection of hypo71 file paths (specific to CRL case)
- SQLite output: added radiated energy, weighted averages, errors on parameters, number of observations, hypocentral location and origin time
- Removed
-Cargument to apply station correction to spectra. Now spectra are automatically corrected ifresiduals_filepathis specified in the configuration file - Save an additional event parameter to output files: average quality factor
- Save additional station parameters to output files: source radius, Brune stress drop, source radius, quality factor
- Mark outliers in
.outfile and in html report - Colored console output for log messages! (Not supported on Windows)
- Processing:
- New parameter for setting the width of the spectral smoothing window
in terms of frequency decades:
spectral_smooth_width_decades - Compute spectral weights after spectral correction (when a station
residuals file is specified via
residuals_filepath) - Removed configuration parameter
trace_format - New configuration parameter
sensitivityto provide a constant sensor sensitivity (flat response curve), which ovverides any response curve provided in metadata - New parameter for manually specifying trace units:
trace_units(defaults toauto) - New approach for trace clipping detection (requires just one configuration
parameter, named
clip_max_percent) - Check for trace clipping only in the processing window
- Use histogram of samples to detect clipping
- Fix for wrong component used for 'SV' spectra (#3)
- New parameter for setting the width of the spectral smoothing window
in terms of frequency decades:
- Inversion:
- New config option:
Mw_0_variability. Allowed variability aroundMw_0during the main inversion. Previously hardcoded to 0.1 - New inversion methods for grid sampling:
- grid search (very slow!)
- importance sampling of the misfit grid using k-d tree (faster, but less accurate)
- Fix for Basin-hopping algorithm not running
- New config option:
- Post-Inversion:
- New set of post-inversion parameters to reject certain inversion results,
per-station:
pi_fc_min_max,pi_t_star_min_max,pi_bsd_min_max,pi_misfit_max - Reject inversion results when inverted
fcis within 10% offc_minorfc_max - Fix: use logarithmic error width for weighted logarithmic averages
- previous way of computing weighted logarithmic averages was not correct!
- Option to reject outliers using the IQR (interquartile range) method:
parameter
nIQR - Support for non symmetric error on station spectral parameters
- Compute additional, per-station parameters: source radius, Brune stress drop and quality factor
- Compute errors for all station parameters
- Compute weighted averages for all event parameters (except radiated energy)
- Compute spectral residuals using weighted average spectral parameters
- New set of post-inversion parameters to reject certain inversion results,
per-station:
- Plotting:
- Source parameter box plots to evaluate parameter dispersion across stations and visually detect outliers
- Misfit plot (2D and 1D) when using grid sampling
cartopyremoved as installation dependency, since it is not easily installable viapip- Use GSHHS database to draw coastlines.
- New config option:
plot_coastline_resolution - Correctly show circles on maps with diagonal smaller than 1 km
- Fix plotting map colorbar on Matplotlib 3.5
- Make average and errorbar lines more visible on map colorbar
- Fix for error on plotting fc map, when only one station is available
- Fix trace plot scaling for traces with larger signal outside the plot window
- Do not plot 'H' spectrum if there is only one instrument component (since it will coincide with the only component)
- Plot uncorrected spectrum when station correction is used
- Python
Published by github-actions[bot] almost 4 years ago
sourcespec - Release v1.4
- New config option
rps_from_focal_mechanismto compute station-specific S-wave radiation pattern from focal mechanism, if a focal mechanism is available in the QuakeML file - Plot the focal mechanism on maps, if it is available
- Change default inversion algorithm to TNC (truncated Newton algorithm)
- Config option
datalessrenamed tostation_metadata - Config option
traceidsrenamed totraceid_mapping_file - Config options
ignore_stationsanduse_stationsrenamed toignore_traceidsanduse_traceids, respectively - Support for 2D NonLinLoc grids (via
nllgrid >= 1.4.1) - Possibility of using a generic
DEFAULTNonLinLoc time grid - Added
cartopyas an installation dependency - Fixed:
nllgridwas always requested at runtime - Fixed: gracefully handle the case when there is no internet connection and map tiles cannot be downloaded
- Fixed (Windows): suppress colored terminal output, which is not supported
- Fixed (Windows): it is now possible to relaunch the same run, without having to delete the output directory first
- Fixed (Windows): use same timezone names than Linux and macOS
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v1.3.1
- Fix for HTML report not showing trace and spectral plots
- HTML report: add Corner Frequency in Event Summary
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.2
Extended and generalized for the CRL application.
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.3
- Output is no more printed at screen, but to file
- The plots can be saved to a file as well
- We differentiate between short periods and broad bands
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.4
- Logging infrastructure
- Code reorganization
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.5
- Azimuth computation
- Construction of an overall database
- Local magnitude computation
- konnoOhmachiSmoothing
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.6
- Signal to noise weighting
- Improved local magnitude computation
- New options:
- time domain integration
- vertical component
- Largely improved plotting function
- More data formats supported (Antilles, IPOC)
source_model: a code for plotting theoretical spectra- Code refactoring
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.7
- Code reorganization:
- inversion code split to its own functions
- Option to use bounded inversion
- Station residuals, through
ssp_residuals.py source_modelcan now output tables of trade-off between parameters- Fix in the way noise trace is computed and processed
- Documentation!
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.8
- Trace plot showing S and noise time windows
- Improved handling of paz files
- Per-station Mo on output file
- Code cleaning and optimization
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v0.9
- Support for QuakeML input and StationXML
- Support for Python 3.5
- Only compatible with ObsPy >= 1.1.0
- Project reorganization:
- Project renamed to SourceSpec
ssp_residualsrenamed tosource_residuals- New installable package (e.g., via
pip)
- Spectra are smoothed in log-freq (no more Konno-Ohmachi)
- Inversion is performed in a log-freq space
- Option to invert for
t_star_0on the plateau level - Traces are filtered before computing S/N ratio
- Trace clipping detection
- Traces are always plotted, even if no inversion is performed
- Use by default a global model for theoretical travel time calculation
- Possibility of using NonLinLoc travel time grids (requires
nllgrid) - New options for P and S arrival time tolerance
- New option for maximum epicentral distance for trace processing
- Possibility of using a NonLinLoc model grid for obtaining vs at the source
and at the receiver (requires
nllgrid) - Use
log10of weighting function, since the inversion is done in magnitude units - Use
jsonformat fortraceidcorrection file - Save config file to output dir (only for
source_spec) - Save run completion time into output file
- Logarithmic average and logarithmic (asymmetric) error bars for Mo, fc and source radius
- Computation of radiated energy
- Station-specific filters
- New parameters:
gap_max,overlap_max - Add legend to spectral plots
- Add event information, code version and run completion time to plots
- Multifigure plotting for traces and spectra (for large number of stations)
- New option to plot a station map, color-coded by station magnitude (requires Cartopy)
- Refactoring of local magnitude computation code:
- Wood-Anderson amplitude is computed from the whole trace converted to W-A and not converting only the min and max peaks (which is the default in ObsPy)
- Trace windowing is computed on HF envelopes
- New option for custom Ml coefficients
- Remove unnecessary Ml options
- Code cleaning and optimization:
- Switch from
optparse(deprecated) toargparse - Code style fixes and refactoring
- Switch from
- New option to update a config file from previous versions
- BUGFIX: Fix a major bug in reading hypo pick file
- BUGFIX: Fix for pick file not read in
source_model
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v1.0
- Simplification of time window parameters:
- an unique window length,
win_length, is used for time-domain S/N ratio calculation and spectral analysis - the old parameters,
noise_win_lengthands_win_length, are no more supported and generate an error
- an unique window length,
- Reorganized config file and improved inline documentation within the file
- removed unused option:
fc_0 - removed
pre_filtoption - post-processing check on
fcbounds has been removed
- removed unused option:
- Option to specify non standard instrument codes (e.g.,
Lfor acceleration) - Option to specify filter frequencies for local magnitude computation
- Plotting improvements:
- Show S/N ratio on trace plots
- Show spectral S/N ratio on spectrum plots
- Option to show/hide ignored traces/spectra (low S/N)
- Bug fixes:
- Pay attention to location code when building average spectra
- Plotting: avoid overlapping traces with different location code
- Plotting: avoid overlapping spectra with different location code
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v1.1
- Bug fixes:
- Accept band code
Cfor broadband seismometers sampled at >=250 Hz - Require
cartopy>=0.18for compatibility withmatplotlib>=3.3
- Accept band code
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v1.2
- Use
python-versioneerto manage version numbers
- Python
Published by claudiodsf over 4 years ago
sourcespec - Release v1.3
- HTML reports
- Option to provide station-specific spectral windowing
- Python
Published by claudiodsf over 4 years ago