Adapted pca function to be compatible with contrast curve function
@@ -149,7 +149,7 @@ def pca(cube, angle_list, cube_ref=None, scale_list=None, ncomp=1,
``spat-mean``: spatial mean is subtracted.
``temp-standard``: temporal mean centering plus scaling pixel values
- to unit variance.
+ to unit variance. HIGHLY RECOMMENDED FOR ASDI AND RDI CASES!
``spat-standard``: spatial mean centering plus scaling pixel values
to unit variance.
@@ -525,10 +525,10 @@ def _adimsdi_singlepca(cube, angle_list, scale_list, ncomp, fwhm, source_xy,
"""
z, n, y_in, x_in = cube.shape
- if not scaling == 'temp-standard':
- scaling = 'temp-standard'
- if verbose:
- print("Pixel-wise scaling set to `temp-standard`")
+# if not scaling == 'temp-standard':
+# scaling = 'temp-standard'
+# if verbose:
+# print("Pixel-wise scaling set to `temp-standard`")
angle_list = check_pa_vector(angle_list)
if not angle_list.shape[0] == n:
@@ -642,10 +642,10 @@ def _adimsdi_doublepca(cube, angle_list, scale_list, ncomp, scaling,
else:
ncomp_ifs, ncomp_adi = ncomp
- if not scaling == 'temp-standard':
- scaling = 'temp-standard'
- if verbose:
- print("Pixel-wise scaling set to `temp-standard`")
+# if not scaling == 'temp-standard':
+# scaling = 'temp-standard'
+# if verbose:
+# print("Pixel-wise scaling set to `temp-standard`")
angle_list = check_pa_vector(angle_list)
if not angle_list.shape[0] == n:
@@ -756,10 +756,10 @@ def _adi_rdi_pca(cube, cube_ref, angle_list, ncomp, scaling, mask_center_px,
n, y, x = cube.shape
# forcing the 'temp-standard' scaling
- if scaling != 'temp-standard':
- scaling = 'temp-standard'
- if verbose:
- print("Pixel-wise scaling set to `temp-standard`")
+# if scaling != 'temp-standard':
+# scaling = 'temp-standard'
+# if verbose:
+# print("Pixel-wise scaling set to `temp-standard`")
angle_list = check_pa_vector(angle_list)
if not isinstance(ncomp, int):
