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

Add Twins to SMP #1047

Open
melikechan opened this issue Jan 25, 2025 · 3 comments
Open

Add Twins to SMP #1047

melikechan opened this issue Jan 25, 2025 · 3 comments

Comments

@melikechan
Copy link

melikechan commented Jan 25, 2025

Sorry for not being descriptive but it would be benefical to add this transformer-based model to SMP. I will add a more quality description ASAP

arXiv paper link: https://arxiv.org/pdf/2104.13840.pdf

timm model source code link: https://github.com/huggingface/pytorch-image-models/blob/main/timm/models/twins.py

@qubvel
Copy link
Collaborator

qubvel commented Jan 25, 2025

Hey @melikechan, twins encoder is supported, see https://smp.readthedocs.io/en/latest/encoders_timm.html (at the very bottom of the page)

@qubvel
Copy link
Collaborator

qubvel commented Jan 25, 2025

You can use it as follows

model = smp.Unet("tu-twins_pcpvt_base")

Please use tu- prefix for any encoder from timm library

@melikechan
Copy link
Author

melikechan commented Jan 25, 2025

I was actually asking about the model itself, instead of using its encoder in another model.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants