Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
bilby
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
lscsoft
bilby
Commits
60e8f77f
Commit
60e8f77f
authored
3 years ago
by
Josh Willis
Committed by
Gregory Ashton
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Add pool.join after pool.close in bilby.gw.conversion
parent
e04d1190
No related branches found
Branches containing commit
No related tags found
Tags containing commit
1 merge request
!1084
Add pool.join after pool.close in bilby.gw.conversion
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
AUTHORS.md
+1
-0
1 addition, 0 deletions
AUTHORS.md
bilby/gw/conversion.py
+2
-0
2 additions, 0 deletions
bilby/gw/conversion.py
with
3 additions
and
0 deletions
AUTHORS.md
+
1
−
0
View file @
60e8f77f
...
@@ -33,6 +33,7 @@ James A Clark
...
@@ -33,6 +33,7 @@ James A Clark
Jeremy G Baier
Jeremy G Baier
John Veitch
John Veitch
Joshua Brandt
Joshua Brandt
Josh Willis
Katerina Chatziioannou
Katerina Chatziioannou
Kaylee de Soto
Kaylee de Soto
Khun Sang Phukon
Khun Sang Phukon
...
...
This diff is collapsed.
Click to expand it.
bilby/gw/conversion.py
+
2
−
0
View file @
60e8f77f
...
@@ -1167,6 +1167,7 @@ def compute_snrs(sample, likelihood, npool=1):
...
@@ -1167,6 +1167,7 @@ def compute_snrs(sample, likelihood, npool=1):
)
)
new_samples
=
pool
.
map
(
_compute_snrs
,
tqdm
(
fill_args
,
file
=
sys
.
stdout
))
new_samples
=
pool
.
map
(
_compute_snrs
,
tqdm
(
fill_args
,
file
=
sys
.
stdout
))
pool
.
close
()
pool
.
close
()
pool
.
join
()
else
:
else
:
new_samples
=
[
_compute_snrs
(
xx
)
for
xx
in
tqdm
(
fill_args
,
file
=
sys
.
stdout
)]
new_samples
=
[
_compute_snrs
(
xx
)
for
xx
in
tqdm
(
fill_args
,
file
=
sys
.
stdout
)]
...
@@ -1307,6 +1308,7 @@ def generate_posterior_samples_from_marginalized_likelihood(
...
@@ -1307,6 +1308,7 @@ def generate_posterior_samples_from_marginalized_likelihood(
if
pool
is
not
None
:
if
pool
is
not
None
:
pool
.
close
()
pool
.
close
()
pool
.
join
()
new_samples
=
np
.
concatenate
(
new_samples
=
np
.
concatenate
(
[
np
.
array
(
val
)
for
key
,
val
in
cached_samples_dict
.
items
()
if
key
!=
"
_samples
"
]
[
np
.
array
(
val
)
for
key
,
val
in
cached_samples_dict
.
items
()
if
key
!=
"
_samples
"
]
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment