diff --git a/smi_analysis/SMI_beamline.py b/smi_analysis/SMI_beamline.py index 576f68a..2875cdd 100644 --- a/smi_analysis/SMI_beamline.py +++ b/smi_analysis/SMI_beamline.py @@ -40,7 +40,7 @@ def __init__(self, self.masks = [] self.cake = [] self.inpaints, self.mask_inpaints = [], [] - self.img_st, self.mask_st = np.array([]), np.array([]) + self.img_st, self.mask_st = [], [] self.bs_kind = bs_kind self.scales = 1 @@ -247,7 +247,7 @@ def inpainting(self, **kwargs): ) def caking(self, radial_range=None, azimuth_range=None, npt_rad=500, npt_azim=500): - if not(self.img_st.size): + if np.array_equal(self.img_st, []): self.stitching_data() if radial_range is None and 'Pilatus' in self.detector: @@ -303,7 +303,7 @@ def radial_averaging(self, radial_range=None, azimuth_range=None, npt=2000): ) elif self.geometry == 'Reflection': - if not(self.img_st.size): + if np.array_equal(self.img_st, []): self.stitching_data() if radial_range is None and 'Pilatus' in self.detector: radial_range = (0, self.qp[1]) @@ -352,7 +352,7 @@ def azimuthal_averaging(self, radial_range=None, azimuth_range=None, npt_rad=500 ) def horizontal_integration(self, q_per_range=None, q_par_range=None): - if not(self.img_st.size): + if np.array_equal(self.img_st, []): self.stitching_data() self.q_hor, self.I_hor = integrate1D.integrate_qpar(self.img_st, @@ -363,7 +363,7 @@ def horizontal_integration(self, q_per_range=None, q_par_range=None): ) def vertical_integration(self, q_per_range=None, q_par_range=None): - if not(self.img_st.size): + if np.array_equal(self.img_st, []): self.stitching_data() self.q_ver, self.I_ver = integrate1D.integrate_qper(self.img_st,