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

Support more dtypes in pad_nd #7842

Open
function2-llx opened this issue Jun 12, 2024 · 0 comments
Open

Support more dtypes in pad_nd #7842

function2-llx opened this issue Jun 12, 2024 · 0 comments

Comments

@function2-llx
Copy link
Contributor

function2-llx commented Jun 12, 2024

To be brief, I just have no idea why torch.bool (and other integer dtypes except for torch.int32) is considered to be not supported by PyTorch (it seems to work for me with PyTorch 2.3). I will be glad to add a PR.

if mode in {"constant", "reflect", "edge", "replicate", "wrap", "circular"} and img.dtype not in {
torch.int16,
torch.int64,
torch.bool,
torch.uint8,
}:

@function2-llx function2-llx changed the title Support torch.float32 in pad_nd Support more dtypes in pad_nd Jun 12, 2024
@function2-llx function2-llx reopened this Jun 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants