Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Gregory Ashton
PyFstat
Commits
6d385885
Commit
6d385885
authored
Dec 20, 2017
by
Gregory Ashton
Browse files
Fix up SemiCoherentGlitchSearch
- Default to 1 glitch - Only try to calculate segment 2F if length > 1800s
parent
a9d243c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
pyfstat/core.py
View file @
6d385885
...
...
@@ -1033,7 +1033,7 @@ class SemiCoherentGlitchSearch(ComputeFstat):
@
helper_functions
.
initializer
def
__init__
(
self
,
label
,
outdir
,
tref
,
minStartTime
,
maxStartTime
,
nglitch
=
0
,
sftfilepattern
=
None
,
theta0_idx
=
0
,
BSGL
=
False
,
nglitch
=
1
,
sftfilepattern
=
None
,
theta0_idx
=
0
,
BSGL
=
False
,
minCoverFreq
=
None
,
maxCoverFreq
=
None
,
assumeSqrtSX
=
None
,
detectors
=
None
,
SSBprec
=
None
,
injectSources
=
None
):
"""
...
...
@@ -1085,11 +1085,11 @@ class SemiCoherentGlitchSearch(ComputeFstat):
twoFSum
=
0
for
i
,
theta_i_at_tref
in
enumerate
(
thetas
):
ts
,
te
=
tboundaries
[
i
],
tboundaries
[
i
+
1
]
twoFVal
=
self
.
get_fullycoherent_twoF
(
ts
,
te
,
theta_i_at_tref
[
1
],
theta_i_at_tref
[
2
],
theta_i_at_tref
[
3
],
Alpha
,
Delta
)
twoFSum
+=
twoFVal
if
te
-
te
>
1800
:
twoFVal
=
self
.
get_fullycoherent_twoF
(
ts
,
te
,
theta_i_at_tref
[
1
],
theta_i_at_tref
[
2
],
theta_i_at_tref
[
3
],
Alpha
,
Delta
)
twoFSum
+=
twoFVal
if
np
.
isfinite
(
twoFSum
):
return
twoFSum
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment