Short transient search examples: Make data

An example to generate data with a short transient signal.

This can be run either stand-alone (will just generate SFT files and nothing else); or it is also being imported from PyFstat_example_short_transient_grid_search.py and PyFstat_example_short_transient_MCMC_search.py

14 import pyfstat
15 import os
16
17 outdir = os.path.join("PyFstat_example_data", "PyFstat_example_short_transient_search")
18
19 F0 = 30.0
20 F1 = -1e-10
21 F2 = 0
22 Alpha = 0.5
23 Delta = 1
24
25 tstart = 1000000000
26 duration = 2 * 86400
27
28 transient_tstart = tstart + 0.25 * duration
29 transient_duration = 0.5 * duration
30 transientWindowType = "rect"
31 tref = tstart
32
33 h0 = 1e-23
34 cosi = 0
35 psi = 0
36 phi = 0
37 sqrtSX = 1e-22
38 detectors = "H1,L1"
39
40 Tsft = 1800
41
42 if __name__ == "__main__":
43
44     transient = pyfstat.Writer(
45         label="simulated_transient_signal",
46         outdir=outdir,
47         tref=tref,
48         tstart=tstart,
49         duration=duration,
50         F0=F0,
51         F1=F1,
52         F2=F2,
53         Alpha=Alpha,
54         Delta=Delta,
55         h0=h0,
56         cosi=cosi,
57         detectors=detectors,
58         sqrtSX=sqrtSX,
59         transientStartTime=transient_tstart,
60         transientTau=transient_duration,
61         transientWindowType=transientWindowType,
62         Tsft=Tsft,
63         Band=0.1,
64     )
65     transient.make_data()
66     print("Predicted 2F from injection Writer:", transient.predict_fstat())

Total running time of the script: ( 0 minutes 0.000 seconds)

Gallery generated by Sphinx-Gallery