Skip to content

Commit 380a735

Browse files
klapomtezzele
authored andcommitted
Allow non-uniform svd_rank across decomposition levels
- mrCOSTS now allows for non-uniform svd_rank across decomposition levels by handling the ragged array sizes.
1 parent 8732039 commit 380a735

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

pydmd/mrcosts.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -994,6 +994,10 @@ def global_scale_reconstruction(
994994
)
995995
omega_classes = omega_classes_list[n_mrd]
996996

997+
if mrd.svd_rank < np.max(self._svd_rank_array):
998+
truncate_slice = slice(None, mrd.svd_rank)
999+
omega_classes = omega_classes[:, truncate_slice]
1000+
9971001
# Iterate over each window slide performed.
9981002
for k in range(mrd.n_slides):
9991003
w = mrd.modes_array[k]

0 commit comments

Comments
 (0)