trxrdpy 3.3.0__tar.gz → 3.3.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/PKG-INFO +3 -3
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/README.md +1 -1
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/docs/manual/XRDpy_manual.pdf +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/pyproject.toml +2 -2
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/calibration.py +5 -4
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/azimint_utils.py +4 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/plot_utils.py +11 -2
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/main_window.py +3 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/calibration_tab.py +5 -1
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy.egg-info/PKG-INFO +3 -3
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/tests/test_calibration_2d_cake.py +37 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/setup.cfg +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/ESRF_ID09/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/ESRF_ID09/azimint.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/ESRF_ID09/datared.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/MaxIV_FemtoMAX/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/MaxIV_FemtoMAX/azimint.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/MaxIV_FemtoMAX/datared.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/MaxIV_FemtoMAX/datared_utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/MaxIV_FemtoMAX/ping_references_default.csv +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/Spring8_SACLA/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/Spring8_SACLA/azimint.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/Spring8_SACLA/datared.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/Spring8_SACLA/pbs/parallel_job_sender.sh +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/_shared_2d/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/_shared_2d/azimint.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/calibration_utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/differential_analysis_utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/fitting_utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/general_utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/common/paths.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/differential_analysis.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/fitting.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/defaults.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/runtime_guard.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/calibration_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/differential_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/facility_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/fitting_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/integration_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/path_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/services/preparation_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/state.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/style.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/differential_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/fitting_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/pattern_creation_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/preparation_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/session_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/tabs/viewer_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/experiment_widgets.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/facility_widgets.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/log_widget.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/multi_experiment_widgets.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/parameter_widgets.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/path_widgets.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/polarization_widget.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/task_output_dialog.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/cif.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/detector.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/diffractometers.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/experiment.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/geometry.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/main_window.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/services/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/services/path_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/services/simulation_service.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/state.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/style.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/tabs/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/tabs/polycrystalline_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/tabs/single_crystal_tab.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/widgets/__init__.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/widgets/geometry_panel.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/widgets/matrix_rotation_window.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/plot.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/polycrystalline.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/poni.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/sample.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/single_crystal.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/utils.py +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy.egg-info/SOURCES.txt +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy.egg-info/dependency_links.txt +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy.egg-info/entry_points.txt +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy.egg-info/requires.txt +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy.egg-info/top_level.txt +0 -0
- {trxrdpy-3.3.0 → trxrdpy-3.3.2}/tests/test_id09_datared_io.py +0 -0
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: trxrdpy
|
|
3
|
-
Version: 3.3.
|
|
3
|
+
Version: 3.3.2
|
|
4
4
|
Summary: Python toolkit for time-resolved X-ray diffraction simulation and beamline-dependent analysis workflows.
|
|
5
5
|
Author: Julio Guzman-Brambila
|
|
6
6
|
License-Expression: CC-BY-4.0
|
|
7
7
|
Project-URL: Homepage, https://github.com/julioguzmanb/XRDpy
|
|
8
8
|
Project-URL: Repository, https://github.com/julioguzmanb/XRDpy
|
|
9
|
-
Project-URL: Documentation, https://github.com/julioguzmanb/XRDpy
|
|
9
|
+
Project-URL: Documentation, https://github.com/julioguzmanb/XRDpy/raw/main/docs/manual/XRDpy_manual.pdf
|
|
10
10
|
Project-URL: DOI, https://doi.org/10.5281/zenodo.18634909
|
|
11
11
|
Project-URL: Issues, https://github.com/julioguzmanb/XRDpy/issues
|
|
12
12
|
Keywords: xrd,time-resolved xrd,pump-probe,x-ray diffraction,diffraction,materials science,simulation,beamline analysis,pyFAI
|
|
@@ -60,7 +60,7 @@ Source code: https://github.com/julioguzmanb/XRDpy
|
|
|
60
60
|
|
|
61
61
|
## Manual
|
|
62
62
|
|
|
63
|
-
- **User manual PDF:** [
|
|
63
|
+
- **User manual PDF:** [download the PDF](https://github.com/julioguzmanb/XRDpy/raw/main/docs/manual/XRDpy_manual.pdf)
|
|
64
64
|
|
|
65
65
|
---
|
|
66
66
|
|
|
@@ -17,7 +17,7 @@ Source code: https://github.com/julioguzmanb/XRDpy
|
|
|
17
17
|
|
|
18
18
|
## Manual
|
|
19
19
|
|
|
20
|
-
- **User manual PDF:** [
|
|
20
|
+
- **User manual PDF:** [download the PDF](https://github.com/julioguzmanb/XRDpy/raw/main/docs/manual/XRDpy_manual.pdf)
|
|
21
21
|
|
|
22
22
|
---
|
|
23
23
|
|
|
Binary file
|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "trxrdpy"
|
|
7
|
-
version = "3.3.
|
|
7
|
+
version = "3.3.2"
|
|
8
8
|
description = "Python toolkit for time-resolved X-ray diffraction simulation and beamline-dependent analysis workflows."
|
|
9
9
|
readme = { file = "README.md", content-type = "text/markdown" }
|
|
10
10
|
requires-python = ">=3.10"
|
|
@@ -69,7 +69,7 @@ trxrdpy-sim-gui = "trxrdpy.simulation.gui:main"
|
|
|
69
69
|
[project.urls]
|
|
70
70
|
Homepage = "https://github.com/julioguzmanb/XRDpy"
|
|
71
71
|
Repository = "https://github.com/julioguzmanb/XRDpy"
|
|
72
|
-
Documentation = "https://github.com/julioguzmanb/XRDpy"
|
|
72
|
+
Documentation = "https://github.com/julioguzmanb/XRDpy/raw/main/docs/manual/XRDpy_manual.pdf"
|
|
73
73
|
DOI = "https://doi.org/10.5281/zenodo.18634909"
|
|
74
74
|
Issues = "https://github.com/julioguzmanb/XRDpy/issues"
|
|
75
75
|
|
|
@@ -509,7 +509,7 @@ def plot_detector_and_cake(
|
|
|
509
509
|
npt_azim: int = 360,
|
|
510
510
|
radial_range: Optional[Tuple[float, float]] = None,
|
|
511
511
|
azimuthal_range: Tuple[float, float] = (-90.0, 90.0),
|
|
512
|
-
normalize: bool =
|
|
512
|
+
normalize: bool = False,
|
|
513
513
|
q_norm_range: Tuple[float, float] = (2.65, 2.75),
|
|
514
514
|
use_mask: bool = True,
|
|
515
515
|
poni_path: Optional[Union[str, Path]] = None,
|
|
@@ -534,8 +534,9 @@ def plot_detector_and_cake(
|
|
|
534
534
|
"""Plot a bare calibration detector image beside its pyFAI 2D cake.
|
|
535
535
|
|
|
536
536
|
The detector panel uses pixel coordinates. The cake panel uses q in Å⁻¹
|
|
537
|
-
and the package's display-coordinate azimuth convention.
|
|
538
|
-
|
|
537
|
+
and the package's display-coordinate azimuth convention. ``normalize`` is
|
|
538
|
+
false by default so the diagnostic cake matches pyFAI's raw display. When
|
|
539
|
+
true, each azimuthal row is normalized independently over
|
|
539
540
|
``q_norm_range``. ``use_mask`` controls whether the resolved EDF mask is
|
|
540
541
|
passed to pyFAI. Detector x and y directions can be flipped independently.
|
|
541
542
|
|
|
@@ -550,7 +551,7 @@ def plot_detector_and_cake(
|
|
|
550
551
|
azimuthal_range : tuple of float
|
|
551
552
|
Package-coordinate azimuthal limits in degrees.
|
|
552
553
|
normalize : bool
|
|
553
|
-
Normalize each cake row over ``q_norm_range
|
|
554
|
+
Normalize each cake row over ``q_norm_range`` when enabled.
|
|
554
555
|
q_norm_range : tuple of float
|
|
555
556
|
q interval used for row-wise normalization.
|
|
556
557
|
use_mask : bool
|
|
@@ -845,6 +845,10 @@ class AzimIntegrator:
|
|
|
845
845
|
part_intensity = np.asarray(result.intensity, dtype=float)
|
|
846
846
|
part_q = np.asarray(result.radial, dtype=float)
|
|
847
847
|
part_azimuth = np.asarray(result.azimuthal, dtype=float)
|
|
848
|
+
if hasattr(result, "count"):
|
|
849
|
+
count = np.asarray(result.count, dtype=float)
|
|
850
|
+
if count.shape == part_intensity.shape:
|
|
851
|
+
part_intensity = np.where(count > 0.0, part_intensity, np.nan)
|
|
848
852
|
else:
|
|
849
853
|
part_intensity = np.asarray(result[0], dtype=float)
|
|
850
854
|
part_q = np.asarray(result[1], dtype=float)
|
|
@@ -515,6 +515,13 @@ class DetectorCakePlotter:
|
|
|
515
515
|
"""Initialize the plotter with the shared analysis style."""
|
|
516
516
|
self.style = style
|
|
517
517
|
|
|
518
|
+
@staticmethod
|
|
519
|
+
def _cmap_with_bad_color(cmap_name: str, bad_color: str = "#b3b3b3"):
|
|
520
|
+
"""Return a colormap copy with masked values shown as detector-void gray."""
|
|
521
|
+
cmap = plt.get_cmap(str(cmap_name)).copy()
|
|
522
|
+
cmap.set_bad(bad_color)
|
|
523
|
+
return cmap
|
|
524
|
+
|
|
518
525
|
@staticmethod
|
|
519
526
|
def _display_options(
|
|
520
527
|
data: np.ndarray,
|
|
@@ -630,7 +637,7 @@ class DetectorCakePlotter:
|
|
|
630
637
|
detector_data,
|
|
631
638
|
origin="lower",
|
|
632
639
|
aspect="equal",
|
|
633
|
-
cmap=str(detector_cmap),
|
|
640
|
+
cmap=self._cmap_with_bad_color(str(detector_cmap)),
|
|
634
641
|
**detector_options,
|
|
635
642
|
)
|
|
636
643
|
axes[0].set_title("Detector image", fontsize=self.style.title_fontsize)
|
|
@@ -642,12 +649,14 @@ class DetectorCakePlotter:
|
|
|
642
649
|
axes[0].invert_yaxis()
|
|
643
650
|
fig.colorbar(detector_artist, ax=axes[0], label="Intensity [a.u.]")
|
|
644
651
|
|
|
652
|
+
cake_bad_color = "#b3b3b3"
|
|
653
|
+
axes[1].set_facecolor(cake_bad_color)
|
|
645
654
|
cake_artist = axes[1].pcolormesh(
|
|
646
655
|
radial,
|
|
647
656
|
angles,
|
|
648
657
|
cake_data,
|
|
649
658
|
shading="auto",
|
|
650
|
-
cmap=str(cake_cmap),
|
|
659
|
+
cmap=self._cmap_with_bad_color(str(cake_cmap), cake_bad_color),
|
|
651
660
|
**cake_options,
|
|
652
661
|
)
|
|
653
662
|
axes[1].set_title("2D cake", fontsize=self.style.title_fontsize)
|
|
@@ -1533,6 +1533,9 @@ class AnalysisMainWindow(QMainWindow):
|
|
|
1533
1533
|
"calib_caked_ylim": self._line_state(calibration.get("caked_ylim", "")),
|
|
1534
1534
|
"calib_caked_figure_title": self._line_state(calibration.get("caked_figure_title", "")),
|
|
1535
1535
|
"calib_caked_save": self._check_state(calibration.get("caked_save", True)),
|
|
1536
|
+
"calib_detector_cake_normalize": self._check_state(
|
|
1537
|
+
calibration.get("detector_cake_normalize", False)
|
|
1538
|
+
),
|
|
1536
1539
|
"calib_property_name": self._line_state(calibration.get("property_name", "pv_center")),
|
|
1537
1540
|
"calib_property_only_success": self._check_state(calibration.get("property_only_success", True)),
|
|
1538
1541
|
"calib_property_ylim": self._line_state(calibration.get("property_ylim", "")),
|
|
@@ -336,6 +336,10 @@ class CalibrationTab(QWidget):
|
|
|
336
336
|
self.calib_detector_cake_use_mask.setChecked(True)
|
|
337
337
|
cg.addWidget(self.calib_detector_cake_use_mask, 4, 0, 1, 2)
|
|
338
338
|
|
|
339
|
+
self.calib_detector_cake_normalize = QCheckBox("Normalize cake rows")
|
|
340
|
+
self.calib_detector_cake_normalize.setChecked(False)
|
|
341
|
+
cg.addWidget(self.calib_detector_cake_normalize, 4, 2, 1, 2)
|
|
342
|
+
|
|
339
343
|
self.calib_detector_cake_invert_x = QCheckBox("Flip detector X axis")
|
|
340
344
|
self.calib_detector_cake_invert_x.setChecked(False)
|
|
341
345
|
cg.addWidget(self.calib_detector_cake_invert_x, 5, 0)
|
|
@@ -708,7 +712,7 @@ class CalibrationTab(QWidget):
|
|
|
708
712
|
name="azimuthal_range",
|
|
709
713
|
cast=float,
|
|
710
714
|
),
|
|
711
|
-
normalize=self.
|
|
715
|
+
normalize=self.calib_detector_cake_normalize.isChecked(),
|
|
712
716
|
q_norm_range=parse_tuple2(
|
|
713
717
|
self.calib_q_norm_range.text(),
|
|
714
718
|
name="q_norm_range",
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: trxrdpy
|
|
3
|
-
Version: 3.3.
|
|
3
|
+
Version: 3.3.2
|
|
4
4
|
Summary: Python toolkit for time-resolved X-ray diffraction simulation and beamline-dependent analysis workflows.
|
|
5
5
|
Author: Julio Guzman-Brambila
|
|
6
6
|
License-Expression: CC-BY-4.0
|
|
7
7
|
Project-URL: Homepage, https://github.com/julioguzmanb/XRDpy
|
|
8
8
|
Project-URL: Repository, https://github.com/julioguzmanb/XRDpy
|
|
9
|
-
Project-URL: Documentation, https://github.com/julioguzmanb/XRDpy
|
|
9
|
+
Project-URL: Documentation, https://github.com/julioguzmanb/XRDpy/raw/main/docs/manual/XRDpy_manual.pdf
|
|
10
10
|
Project-URL: DOI, https://doi.org/10.5281/zenodo.18634909
|
|
11
11
|
Project-URL: Issues, https://github.com/julioguzmanb/XRDpy/issues
|
|
12
12
|
Keywords: xrd,time-resolved xrd,pump-probe,x-ray diffraction,diffraction,materials science,simulation,beamline analysis,pyFAI
|
|
@@ -60,7 +60,7 @@ Source code: https://github.com/julioguzmanb/XRDpy
|
|
|
60
60
|
|
|
61
61
|
## Manual
|
|
62
62
|
|
|
63
|
-
- **User manual PDF:** [
|
|
63
|
+
- **User manual PDF:** [download the PDF](https://github.com/julioguzmanb/XRDpy/raw/main/docs/manual/XRDpy_manual.pdf)
|
|
64
64
|
|
|
65
65
|
---
|
|
66
66
|
|
|
@@ -23,6 +23,7 @@ class _FakeIntegrate2dResult:
|
|
|
23
23
|
)
|
|
24
24
|
self.radial = np.array([1.0, 2.0, 3.0])
|
|
25
25
|
self.azimuthal = np.array([-75.0, -25.0])
|
|
26
|
+
self.count = np.ones_like(self.intensity)
|
|
26
27
|
|
|
27
28
|
|
|
28
29
|
class _FakeAzimuthalIntegrator:
|
|
@@ -131,6 +132,41 @@ def test_integrate2d_accepts_no_mask_and_passes_none_to_pyfai():
|
|
|
131
132
|
assert fake_ai.kwargs["mask"] is None
|
|
132
133
|
|
|
133
134
|
|
|
135
|
+
def test_integrate2d_masks_pyfai_bins_without_contributing_pixels():
|
|
136
|
+
class CountAwareFakeAzimuthalIntegrator:
|
|
137
|
+
def integrate2d(self, image, **kwargs):
|
|
138
|
+
result = _FakeIntegrate2dResult()
|
|
139
|
+
result.intensity = np.array(
|
|
140
|
+
[
|
|
141
|
+
[1.0, 999.0, 3.0],
|
|
142
|
+
[4.0, 5.0, 6.0],
|
|
143
|
+
],
|
|
144
|
+
dtype=float,
|
|
145
|
+
)
|
|
146
|
+
result.count = np.array(
|
|
147
|
+
[
|
|
148
|
+
[1.0, 0.0, 1.0],
|
|
149
|
+
[1.0, 1.0, 1.0],
|
|
150
|
+
],
|
|
151
|
+
dtype=float,
|
|
152
|
+
)
|
|
153
|
+
return result
|
|
154
|
+
|
|
155
|
+
integrator = AzimIntegrator(npt=3, normalize=False, azim_offset_deg=-90.0)
|
|
156
|
+
integrator._ai = CountAwareFakeAzimuthalIntegrator()
|
|
157
|
+
integrator._mask = np.zeros((2, 2), dtype=np.uint8)
|
|
158
|
+
|
|
159
|
+
cake, _q, _azimuth = integrator.integrate2d(
|
|
160
|
+
np.ones((2, 2)),
|
|
161
|
+
npt_rad=3,
|
|
162
|
+
npt_azim=2,
|
|
163
|
+
azimuthal_range=(0.0, 90.0),
|
|
164
|
+
)
|
|
165
|
+
|
|
166
|
+
assert np.isnan(cake[0, 1])
|
|
167
|
+
np.testing.assert_allclose(cake[0, [0, 2]], [1.0, 3.0])
|
|
168
|
+
|
|
169
|
+
|
|
134
170
|
def test_mask_file_is_converted_to_pyfai_boolean_mask(monkeypatch):
|
|
135
171
|
class FakeFabioImage:
|
|
136
172
|
data = np.array([[0, 2], [-1, 0]], dtype=np.int16)
|
|
@@ -285,6 +321,7 @@ def test_public_calibration_api_connects_context_data_to_plotter(monkeypatch, tm
|
|
|
285
321
|
assert context.scan == 7
|
|
286
322
|
assert context.kwargs["npt_rad"] == 5
|
|
287
323
|
assert context.kwargs["npt_azim"] == 4
|
|
324
|
+
assert context.kwargs["normalize"] is False
|
|
288
325
|
assert context.kwargs["use_mask"] is False
|
|
289
326
|
assert plotter.args[0] is detector
|
|
290
327
|
assert plotter.args[1] is cake
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/MaxIV_FemtoMAX/ping_references_default.csv
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/Spring8_SACLA/pbs/parallel_job_sender.sh
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/analysis/gui/widgets/multi_experiment_widgets.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{trxrdpy-3.3.0 → trxrdpy-3.3.2}/src/trxrdpy/simulation/gui/widgets/matrix_rotation_window.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|