Skip to content

Commit

Permalink
demo RF PT benchmark more
Browse files Browse the repository at this point in the history
  • Loading branch information
albertz committed Oct 6, 2023
1 parent 17eaa5c commit c1b2619
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions demos/demo-rf-pt-benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -493,8 +493,12 @@ def main():
arg_parser.add_argument("--bench-action", choices=("run", "multi-run", "profile"), default="run")
args, remaining_args = arg_parser.parse_known_args()

# https://youtrack.jetbrains.com/issue/PY-63226/PyCharm-debugger-hangs-when-process-is-forking
multiprocessing.set_start_method("spawn")
try:
# https://youtrack.jetbrains.com/issue/PY-63226/PyCharm-debugger-hangs-when-process-is-forking
multiprocessing.set_start_method("spawn")
except Exception as exc:
print("multiprocessing.set_start_method 'spawn' exception:", exc)
print("Ignoring this...")

if args.bench_action == "run":
__main__.main(sys.argv[:1] + [_my_file] + remaining_args)
Expand Down

0 comments on commit c1b2619

Please sign in to comment.