output dimension
if self.dim is None or (isinstance(self.dim, float) and self.dim == 1.0):
if hasattr(self, "_rank0"):
return min(self._rank0, self._rankt)
else:
raise RuntimeError("Requested dimension, but the dimension depends on the singular values of C00 and C11"
" and the transformer has not yet been estimated. Call estimate() before.")
if isinstance(self.dim, float):
After Change
if isinstance(self.dim, int): // return user choice
warnings.warn("Returning user-input for dimension, since this model has not yet been estimated.")
return self.dim
raise RuntimeError("Please call set_model_params prior using this method.")
if not self._svd_performed:
self._diagonalize()
return self._dimension(self._rank0, self._rankt, self.dim, self.singular_values)