Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect return type for _pad_projections_to_second_power() function #154

Open
yousefmoazzam opened this issue Sep 19, 2024 · 0 comments
Open
Labels
minor Nice to do but not vital

Comments

@yousefmoazzam
Copy link
Contributor

The return type currently says that either a cp.ndarray or a tuple can be returned:

def _pad_projections_to_second_power(tomo: cp.ndarray) -> Union[cp.ndarray, tuple]:

But, the function actually returns a tuple containing two elements: a cp.ndarray and a tuple:

Returns
-------
ndarray: padded 3d projection data
tuple: a tuple with padding dimensions

return padded_tomo, pad_tup

where the second element in the "outer tuple" is a tuple containing two int values I think?

Therefore, I think the correct return type is Tuple[cp.ndarray, Tuple[int, int]].

@yousefmoazzam yousefmoazzam added the minor Nice to do but not vital label Sep 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
minor Nice to do but not vital
Projects
None yet
Development

No branches or pull requests

1 participant