Skip to content

请问关于模型的"img_size"这个参数是什么呀?不需要和输入一样吗? #2

@GusRoth

Description

@GusRoth

我看到使用的实例中:
`from SETR.transformer_seg import SETRModel
import torch

if name == "main":
net = SETRModel(img_size=(32, 32),
in_channels=3,
out_channels=1,
hidden_size=1024,
num_hidden_layers=8,
num_attention_heads=16,
decode_features=[512, 256, 128, 64])
t1 = torch.rand(1, 3, 256, 256)
print("input: " + str(t1.shape))

# print(net)
print("output: " + str(net(t1).shape))`

SETRModel(img_size=(32, 32), 有这个,但是下面的输入使用的img_size是(256,256)。所以这个模型的img_size参数对应的是什么呀

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions