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
7597931b
Commit
7597931b
authored
Nov 29, 2016
by
Gregory Ashton
Browse files
Minor fix to the setup checking proc
parent
dec965e4
Changes
1
Hide whitespace changes
Inline
Side-by-side
pyfstat.py
View file @
7597931b
...
...
@@ -663,6 +663,7 @@ class ComputeFstat(object):
if
title
:
ax
.
set_title
(
title
)
if
savefig
:
plt
.
tight_layout
()
plt
.
savefig
(
'{}/{}_twoFcumulative.png'
.
format
(
outdir
,
label
))
return
taus
,
twoFs
else
:
...
...
@@ -2210,14 +2211,16 @@ class MCMCFollowUpSearch(MCMCSemiCoherentSearch):
return
d
def
write_setup_input_file
(
self
,
run_setup_input_file
,
R0
,
Vmin
,
nsegs_vals
,
V_vals
):
d
=
dict
(
R0
=
R0
,
Vmin
=
Vmin
,
nsegs_vals
=
nsegs_vals
,
V_vals
=
V_vals
)
nsegs_vals
,
V_vals
,
DeltaOmega
,
DeltaFs
):
d
=
dict
(
R0
=
R0
,
Vmin
=
Vmin
,
nsegs_vals
=
nsegs_vals
,
V_vals
=
V_vals
,
DeltaOmega
=
DeltaOmega
,
DeltaFs
=
DeltaFs
)
with
open
(
run_setup_input_file
,
'w+'
)
as
f
:
pickle
.
dump
(
d
,
f
)
def
check_old_run_setup
(
self
,
old_setup
,
**
kwargs
):
try
:
return
all
([
val
==
old_setup
[
key
]
for
key
,
val
in
kwargs
.
iteritems
()])
truths
=
[
val
==
old_setup
[
key
]
for
key
,
val
in
kwargs
.
iteritems
()]
return
all
(
truths
)
except
KeyError
:
return
False
...
...
@@ -2255,7 +2258,8 @@ class MCMCFollowUpSearch(MCMCSemiCoherentSearch):
self
.
search
.
detector_names
,
self
.
earth_ephem
,
self
.
sun_ephem
)
self
.
write_setup_input_file
(
run_setup_input_file
,
R0
,
Vmin
,
nsegs_vals
,
V_vals
)
nsegs_vals
,
V_vals
,
DeltaOmega
,
DeltaFs
)
run_setup
=
[((
self
.
nsteps
[
0
],
0
),
nsegs
,
False
)
for
nsegs
in
nsegs_vals
[:
-
1
]]
...
...
Write
Preview
Supports
Markdown
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