Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Print stack traces on SIGUSR2 #1277

Merged
merged 2 commits into from
Jun 3, 2020
Merged

Print stack traces on SIGUSR2 #1277

merged 2 commits into from
Jun 3, 2020

Conversation

Anthchirp
Copy link
Member

This feels like a useful addition? (Inspired by "Python debugging tools")

Terminal 1:

dials.find_spots nproc=2 imported.expt

Terminal 2:

kill -SIGUSR2 $PARENT_PROCESS_PID

Terminal 1:

(...)
Found 550 strong pixels on image 37
Found 546 strong pixels on image 38
Found 527 strong pixels on image 39
Found 536 strong pixels on image 40
Current thread 0x00007f74af203740 (most recent call first):
  File "/scratch/wra62962/files/dials/conda_base/lib/python3.6/selectors.py", line 376 in select
  File "/scratch/wra62962/files/dials/conda_base/lib/python3.6/multiprocessing/connection.py", line 911 in wait
  File "/scratch/wra62962/files/dials/conda_base/lib/python3.6/multiprocessing/connection.py", line 414 in _poll
  File "/scratch/wra62962/files/dials/conda_base/lib/python3.6/multiprocessing/connection.py", line 257 in poll
  File "/scratch/wra62962/files/dials/conda_base/lib/python3.6/multiprocessing/queues.py", line 104 in get
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/job_scheduler.py", line 200 in poll
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/job_scheduler.py", line 134 in results
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/parallel_for.py", line 271 in process_next_one
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/parallel_for.py", line 246 in __next__
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/easy_mp.py", line 633 in parallel_map
  File "/scratch/wra62962/files/dials/modules/dials/util/mp.py", line 84 in __call__
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/mainthread.py", line 100 in poll
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/mainthread.py", line 50 in results
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/parallel_for.py", line 271 in process_next_one
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/scheduling/parallel_for.py", line 246 in __next__
  File "/scratch/wra62962/files/dials/modules/cctbx_project/libtbx/easy_mp.py", line 633 in parallel_map
  File "/scratch/wra62962/files/dials/modules/dials/util/mp.py", line 46 in parallel_map
  File "/scratch/wra62962/files/dials/modules/dials/util/mp.py", line 154 in multi_node_parallel_map
  File "/scratch/wra62962/files/dials/modules/dials/util/mp.py", line 182 in batch_multi_node_parallel_map
  File "/scratch/wra62962/files/dials/modules/dials/algorithms/spot_finding/finder.py", line 567 in _find_spots
  File "/scratch/wra62962/files/dials/modules/dials/algorithms/spot_finding/finder.py", line 463 in __call__
  File "/scratch/wra62962/files/dials/modules/dials/algorithms/spot_finding/finder.py", line 868 in _find_spots_in_imageset
  File "/scratch/wra62962/files/dials/modules/dials/algorithms/spot_finding/finder.py", line 758 in __call__
  File "/scratch/wra62962/files/dials/modules/dials/array_family/flex_ext.py", line 173 in from_observations
  File "/scratch/wra62962/files/dials/build/../modules/dials/command_line/find_spots.py", line 154 in run
  File "/scratch/wra62962/files/dials/build/../modules/dials/command_line/find_spots.py", line 232 in <module>
Found 600 strong pixels on image 41
Found 677 strong pixels on image 42
(...)

@Anthchirp Anthchirp merged commit 37891be into master Jun 3, 2020
@Anthchirp Anthchirp deleted the faulthandler branch June 3, 2020 11:10
Anthchirp added a commit that referenced this pull request Jul 6, 2020
On posix systems you can print a stack trace from DIALS
commands by sending a SIGUSR2 signal to the process
@ndevenish ndevenish mentioned this pull request Jul 6, 2020
ndevenish added a commit that referenced this pull request Jul 6, 2020
Features
--------

- Developer tool: On posix systems, sending SIGUSR2 to DIALS commands will now print a stack trace (#1277)

Bugfixes
--------
- HTML reports: Plot bin centres instead bin minimum for d_min line plots vs. resolution (#1323)
- `dials.export`: Fix inconsistency in mtz export when given a non-reference (e.g. I2 or primitive) setting (#1279)
- `dials.refine_bravais_settings`: Fix crash with large (>2gb) reflection tables and reduce memory use (#1274)
- `dials.scale`: Fix bug in outlier rejection code causing misidentification of outliers (with outlier_rejection=standard).
- `dials.scale`: Fix outlier rejection formula to avoid overconfidence in spuriously low values
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant