Skip to content

unet3d is not access? #694

Open
Open
@8899012

Description

@8899012

this is a small code to catch the problem:
`import torch
import torch_directml
import torch.nn as nn
device = torch_directml.device()

创建3D卷积层和五维输入

conv3d = nn.Conv3d(1, 1, kernel_size=3, padding=1).to(device)
x = torch.randn(1, 1, 16, 256, 256).to(device) # (B, C, D, H, W)

try:
output = conv3d(x)
print("3D卷积在DirectML下运行成功,输出维度:", output.shape)
except Exception as e:
print("错误信息:", e)`

python == 3.10
requirement.txt
what can i do to run the code successfully?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions