Peaking finding and PsanaInterface parallelization overhaul #37
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
A
PeakFinderclass has been added that leveragespsana's adaptive peak-finding algorithm and writes the results to CrystFEL-compatible CXI files that can then be indexed usingindexamajig. In addition, the class writes a summary file (peakfinding.summary) and a .lst file as input forindexamajig. As an example, peak finding can be performed as follows:To enable MPI parallelization during peak finding, the
PsanaInterfaceclass has been revised so that the event IDs are retrieved at the beginning and can be distributed across ranks using thedistribute_eventsclass function. Note that despite these changesPsanaInterfacehas no knowledge of MPI so that it can be used withoutmpirun;mpi4pyshould be imported by the upstream class. It may be useful to look into whetherMPIDataSourcewould be an efficient alternative at a later date.To-do's:
amax_thr,atot_thr, andson_minvariables correspond to, and look into whether the newpsanainterface for peak finding is avalable.generate_maskfunction in thePeakFinderclass to detect type of mask (e.g. cctbx, crystfel, psana unassembled) and load accordingly.