windygoo / promptnucseg Goto Github PK
View Code? Open in Web Editor NEW[ECCV 2024] Code for "Unleashing the Power of Prompt-driven Nucleus Instance Segmentation"
[ECCV 2024] Code for "Unleashing the Power of Prompt-driven Nucleus Instance Segmentation"
作者您好,我在训练prompter的时候遇到这个问题
return torch.stack(images), torch.stack(masks), points, labels
RuntimeError: stack expects each tensor to be equal size, but got [3, 512, 512] at entry 0 and [3, 608, 608] at entry 1
是两张图片的大小不一样导致的
我使用的是cpm17数据集,配置文件是prompter/config/cpm17.py。
cpm17的图片大小不一致,数据增强部分有pad,但是并没有pad到同一大小
train=dict(
transform=[
dict(type="RandomGridShuffle", grid=(4, 4), p=0.5),
dict(
type="ColorJitter",
brightness=0.25,
contrast=0.25,
saturation=0.1,
hue=0.05,
p=0.2,
),
dict(type="RandomRotate90", p=0.5),
dict(type="Downscale", scale_max=0.5, scale_min=0.5, p=0.15),
dict(type="Blur", blur_limit=10, p=0.2),
dict(type="GaussNoise", var_limit=50, p=0.25),
dict(type="ZoomBlur", p=0.1, max_factor=1.05),
dict(type="HorizontalFlip", p=0.5),
dict(type="VerticalFlip", p=0.5),
dict(
type="ShiftScaleRotate",
shift_limit=0.3,
scale_limit=0.1,
rotate_limit=0,
border_mode=0,
value=0,
p=0.5,
),
dict(
type="PadIfNeeded",
min_height=None,
min_width=None,
pad_height_divisor=prompter["space"],
pad_width_divisor=prompter["space"],
position="top_left",
p=1,
),
dict(type="Normalize"),
]
),
sam的backbone是vit,会对图片做16倍下采样,256x256的输入会不会太小了。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.