Skip to content

Commit

Permalink
Fix: set local context to avoid errors resetting global start method (#…
Browse files Browse the repository at this point in the history
…92)

* Fix: set local context to avoid errors resetting global start method

* Fixing trailing whitespace for code checks
  • Loading branch information
DreRnc authored Dec 31, 2024
1 parent 7bcb4cc commit 5c1b90c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
workflow_dispatch:

permissions:
id-token: write
contents: read
Expand Down
4 changes: 2 additions & 2 deletions src/plinder/eval/docking/write_scores.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,8 +212,8 @@ def score_test_set(
)
predictions = predictions[~predictions["exists"]]
LOG.info(f"Running evaluation on {predictions.shape[0]} cases")
multiprocessing.set_start_method("spawn")
with multiprocessing.Pool(num_processes) as p:
ctx = multiprocessing.get_context("spawn")
with ctx.Pool(num_processes) as p:
p.starmap(
write_scores_as_json,
[
Expand Down

0 comments on commit 5c1b90c

Please sign in to comment.