Burst waveform
This package hosts the python version of the burst waveform used in coherentWaveBurst(cWB) search.
Installation
Using pip
pip install burst-waveform
from source
make install
Usage
The Burst-Waveform package provides four burst waveform models: SineGaussian, SineGaussianQ, WhiteNoiseBurst,
and Ringdown.
The waveforms can be generated by calling the instance of the waveform model after initializing it with the desired parameters.
For example, to generate a SineGaussianQ waveform,
from burst_waveform.models import SineGaussianQ
from matplotlib import pyplot as plt
params = {
"amplitude": 1.0,
"frequency": 300.0,
"Q": 9
}
model = SineGaussianQ(params)
strain = model()
plt.plot(strain)
plt.show()
For WhiteNoiseBurst waveform,
from burst_waveform.models import WhiteNoiseBurst
import matplotlib.pyplot as plt
params = {
'frequency': 300,
'bandwidth': 50,
'duration': 0.005,
'inj_length': 1,
'mode': 1
}
WNB = WhiteNoiseBurst(params)
wnb_strain = WNB()
plt.plot(wnb_strain)
plt.xlim(0.5 - 10 * params['duration'], 0.5 + 10 * params['duration'])
plt.show()
For Ringdown waveform,
import numpy as np
from burst_waveform.models import Ringdown
from matplotlib import pyplot as plt
params = {
"tau": 0.3,
"frequency": 10.0,
"iota": np.pi / 2, # inclination angle in radians (90 deg)
}
model = Ringdown(params)
hp, hc = model()
plt.plot(hp)
plt.plot(hc)
plt.show()
cWB analytic burst conventions
burst_waveform.interface.generate_waveform_pycwb.get_td_waveform owns the
cWB-compatible SG, SGE, GA, and WNB implementations. PycWB no longer
provides a separate burst_population generator. The public interface returns
GWpy hp and hc series and accepts delta_t or sample_rate (16384 Hz by
default); supplying inconsistent values raises an error. The default buffer is
one second centered at epoch -0.5, configurable with inj_length.
- SGE uses sine for
hp, cosine forhc, and cWB's positive-half component normalization. Sourcehrssis applied before inclination factors(1 + cos(iota)**2)/2andcos(iota).iotais in radians;ellipticityremains an alias. This corrects the previous swapped phases and post-inclination normalization. SG has only the sine polarization. - WNB has two independent, equally normalized polarizations, without inclination
weighting (cWB
MDC_WNB).frequencyis the lower band edge;durationis the Gaussian amplitude standard deviation, correcting the former envelope's missing factor of 1/2.mode=0(the cWB default) selects a noise band;mode=1constructs the symmetric heterodyned band, including the corrected conjugation and cWB packed-FFT DC/Nyquist handling. To migrate the removed PycWB generator's WNBs, specifymode=1explicitly. - GA uses cWB's
exp(-(t/duration)**2)convention and has zero cross component. - The interface defaults source
hrssto5e-23; specify it explicitly for scientific runs. SG/CG direct classes share the same numerical kernels and now return the full padded buffer. The explicitly elliptical WNB class remains available as a separate model, but is not used for cWBWNB.
NumPy's RNG differs from ROOT's: equal integer seeds do not produce identical
WNB realizations. Tests against saved original cWB samples use the same Gaussian
inputs and require relative L2 error below 1e-12. Reference fixtures and their
provenance live in test/data/.
Metadata
Release files for burst-waveform 0.5.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| burst_waveform-0.5.0.tar.gz | 2.6 MB | Details |
Release files / burst_waveform-0.5.0.tar.gz
| Download URL | burst_waveform-0.5.0.tar.gz |
|---|---|
| Size | 2.6 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f99f63779ffafe53100118103ae597e090c8217859e3e2465d4cd0fe07d67688
|
|
BLAKE2b-256 checksum How to use checksums |
deed308a6c1223b274cd4fa682acc788ed6ec4edf48adc1eb834f41ea12db26c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.10.21
|