diff --git a/dap/algos/streakfind.py b/dap/algos/streakfind.py index 5f9aa73..5676dd9 100644 --- a/dap/algos/streakfind.py +++ b/dap/algos/streakfind.py @@ -157,6 +157,11 @@ def _calc_streakfinder_analysis(results, cryst_data: CrystData): detected_streaks = np.asarray(detected.streaks) streak_lines = streaks.lines + # Adjust to crop region + if crop_roi is not None: + shift = [crop_roi[0], crop_roi[2], crop_roi[0], crop_roi[2]] + streak_lines = streak_lines + shift + if x_center is not None and y_center is not None: streaks_mask = streaks.concentric_only(x_center, y_center) streak_lines = streak_lines[streaks_mask]